【NanoPi Neo2】Install Google Chrome on NanoPi Neo2

System on NanoPi Neo2

At the beginning, I installed the official Armbian system (Debian) on the π, but when installing chrome, I got an error:

dpkg: error processing archive google-chromestable_current_amd64.deb (--install):
 package architecture (amd64) does not match system (arm64)

The structure of the package does not match the system.
When installing, I directly copied the address of the software package that I used for testing in the Debian environment on the cloud server (there is a content about this in the previous article), and that software package is for the CPU architecture of amd64 , and the CPU architecture of most embedded devices is arm, so the above error will be prompted. After reviewing most of the information, I found that few people run the Debian system. On the contrary, the information of Ubuntu is easier to find and complete, so I gave up Debian and modified the Ubuntu system. This change is still very clever.
The download network disk of the official system provided by NanoPi Neo2: network disk download

Is it Chrome or Chromium?

The children's shoes who have checked the relevant information should all understand that chrome does not support arm, but chromium can! Chromium is a web browser developed by Google. Chromium is a plan opened by Google to develop its own browser, Google Chrome, so Chromium is equivalent to the engineering version or experimental version of Chrome (although Chrome itself also has a beta version stage), The new features will be implemented on Chromium first, and will be applied to Chrome after verification, so Chrome's features will be relatively backward but more stable.
So in order to use Google Chrome on NanoPi, we can only install Chromium.
After many twists and turns and hardships, I finally found the chromium software package (at that time I went out to find it, but I couldn't find it in Baidu!!! But this website can be accessed without going over the wall!!) The
chromium software package Download: Chromium download
write picture description here
Choose the first one.

Install Chromium

After clicking the first one, a bunch of content will appear below. In Builds, we can see that it supports arm64, arm64, armhf, i386 and other architectures.
Scroll to the following Package files, we only need to download the following three: (Choose your own hardware type, like NanoPi Neo2 is arm64, NanoPi3/Raspberry Pi is armhf)

chromium-browser
chromium-chromedriver
chromium-codecs-ffmpeg-extra

You can choose the local computer to download and upload the software package to the π through winscp, or you can type the wget command on the π to download it through the network.
After I selected the local computer to download, I uploaded the software package to the π through winscp.
Use the dpkg command to install the package:
dpkg -i chromium-browser_61.0.3163.79-0ubuntu0.16.04.1300_arm64.deb
but if you only install this, it will prompt an error that the relevant dependency package is missing:
write picture description here
this is, just execute the following command repeatedly:

apt-get upgrade  //升级
apt-get update   //更新
apt-get -f install  //安装

Until the prompt:
write picture description here
write picture description here
you can stop, and then execute again, you
dpkg -i chromium-browser_61.0.3163.79-0ubuntu0.16.04.1300_arm64.deb
will find another error:
write picture description here
the version of the software package is not correct, at this time, the chromium-codecs-ffmpeg-extra downloaded from the official website will come in handy. implement:

dpkg -i chromium-codecs-ffmpeg-extra_65.0.3325.181-0ubuntu0.17.10.1_arm64.deb
dpkg -i chromium-browser_61.0.3163.79-0ubuntu0.16.04.1300_arm64.deb

The following figure shows that the installation is successful:
write picture description here
You can find the installation path of chromium through the whereis command:
whereis chromium-browser

About chromedriver

Since I installed chromium to automatically log in to the website with selenium, I also need chromedriver. I wrote a few articles earlier about this content and tried many methods.

dpkg -i chromium-chromedriver_65.0.3325.181-0ubuntu0.17.10.1_arm64.deb
dpkg -L chromium-chromedriver

The installation path of the chromedriver can be found as: /usr/lib/chromium-browser/chromedriver The reason why the ChromeDriver Mirror
provided by the official website is not directly used is because there is still a mismatch, so it is safe to use the paired chromedriver. . (Remember to open the chromedriver permission when using it! Otherwise, an error will be reported: )The driver is not executable

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325875040&siteId=291194637