Initial Setup of hardware with Armbian - monkeymia/orangepizero GitHub Wiki
- Hardware (Orange Pi Zero)
- Power Supply (5V DC, 2 Ampere) with USB Type B (micro) Note: Supply via USB works for the Getting Started, but is no long term solution.
- Ethernet cable
- Dynamic Host Configuration Protocol (DHCP) Server
- micro SD-Card (4+ GByte) (and SD-card adapter)
- PC with software to flash a image to a SD-card
- Armbian image. Currently Armbian provides pre-build images:
- Armbian Bionic (based on Ubuntu 18.04 code name "Bionic Beaver")
- Armbian Stretch (based on Debian 9 code name "Stretch"/ Ubuntu 16.04 code name "Xenial Xerus")
- Software to uncompress 7-zip archive; Armbian recommends: http://www.7-zip.org/
- PC with software to login on target with secure shell (ssh)
- Download Armbian Bionic Armbian_5.59_Orangepizero_Ubuntu_bionic_next_4.14.65.7z
- Put image on SD-Card
- Armbian recommends: https://www.etcher.io/
- Other software for Windows: Win32 Disk Imager https://sourceforge.net/projects/win32diskimager/
- Insert SD-Card
- connect Ethernet to DHCP server
- connect PC with ssh to DHCP server
- Power on target. The green onboard LED should be on. Both LED of Ethernet Port should be on.
- Wait 1 minute
- lockup assigned IP-address
- login via ssh on target.
- change settings (see below)
- If the red LED starts blinking then indicates heartbeat i.e. the target has booted and the kernel is running. = The SD-card was detected.
- If no Ethernet link then double check if you have downloaded the correct image. If it does not match the hardware then the Ethernet is not initialized.
- Check sha256sum of the image and flash the image again to the SD-Card. Please do not forget to do a safe eject/remove of the SD-Card.
In short the steps are:
-
Check Connection i.e. ping <ip-address>
-
ssh <ip-address>
username name: root
password: 1234
-
change password (US-Keyboard setting)
Assuming the DHCP server has assigned IP-Address 192.168.2.11 then you can connect with command :
ssh [email protected]
The target executes the configuration wizard. The user has to specify :
- A new root password
- name of the user (for example "demonstrator")
- password of the user
The terminal output looks like :
[email protected]'s password: You are required to change your password immediately (root enforced) ___ ____ _ _____ / _ \ _ __ __ _ _ __ __ _ ___ | _ \(_) |__ /___ _ __ ___ | | | | '__/ _` | '_ \ / _` |/ _ \ | |_) | | / // _ \ '__/ _ \ | |_| | | | (_| | | | | (_| | __/ | __/| | / /| __/ | | (_) | \___/|_| \__,_|_| |_|\__, |\___| |_| |_| /____\___|_| \___/ |___/ Welcome to ARMBIAN 5.59 stable Ubuntu 18.04.1 LTS 4.14.65-sunxi System load: 0.08 0.02 0.01 Up time: 29 min Memory usage: 10 % of 493MB IP: 192.168.2.11 CPU temp: 44°C Usage of /: 5% of 15G [ General system configuration (beta): armbian-config ] New to Armbian? Check the documentation first: https://docs.armbian.com Changing password for root. (current) UNIX password: Enter new UNIX password: Retype new UNIX password: Thank you for choosing Armbian! Support: www.armbian.com Creating a new user account. Press <Ctrl-C> to abort Please provide a username (eg. your forename): Please provide a username (eg. your forename): demonstrator Trying to add user demonstrator perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = "en_US.UTF-8", LC_ALL = (unset), LC_MEASUREMENT = "de_AT.UTF-8", LC_PAPER = "de_AT.UTF-8", LC_MONETARY = "de_AT.UTF-8", LC_NAME = "de_AT.UTF-8", LC_ADDRESS = "de_AT.UTF-8", LC_NUMERIC = "de_AT.UTF-8", LC_MESSAGES = "en_US.UTF-8", LC_TELEPHONE = "de_AT.UTF-8", LC_IDENTIFICATION = "de_AT.UTF-8", LC_TIME = "de_AT.UTF-8", LANG = "en_US.UTF-8" are supported and installed on your system. perl: warning: Falling back to a fallback locale ("en_US.UTF-8"). Adding user `demonstrator' ... Adding new group `demonstrator' (1000) ... Adding new user `demonstrator' (1000) with group `demonstrator' ... Creating home directory `/home/demonstrator' ... Copying files from `/etc/skel' ... Enter new UNIX password: perl: warning: Falling back to a fallback locale ("en_US.UTF-8"). Adding user `demonstrator' ... Adding new group `demonstrator' (1000) ... Adding new user `demonstrator' (1000) with group `demonstrator' ... Creating home directory `/home/demonstrator' ... Copying files from `/etc/skel' ... Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully Changing the user information for demonstrator Enter the new value, or press ENTER for the default Full Name []: Enter the new value, or press ENTER for the default Full Name []: Room Number []: Work Phone []: Home Phone []: Other []: Is the information correct? [Y/n] Dear demonstrator, your account demonstrator has been created and is sudo enabled. Please use this account for your daily work from now on. root@orangepizero:~#
It seems the system date is wrong. The root can change it with command
date +%Y%m%d -s "20180831"
or
sudo date -s "5 SEP 2018 12:24:00"
Example output :
root@orangepizero:~# date Tue Aug 21 20:35:41 UTC 2018 root@orangepizero:~# date +%Y%m%d -s "20180831" 20180831 root@orangepizero:~# date Fri Aug 31 00:00:04 UTC 2018 root@orangepizero:~#
Steps to assign static Ethernet 192.18.2.240 with Network Monitor Command Line Interface :
nmcli con add con-name "static-eth0" ifname eth0 type ethernet ip4 192.168.2.240/24 gw4 10.10.10.1 nmcli con mod "static-eth0" ipv4.dns "192.168.2.1,8.8.8.8" nmcli con up "static-eth0" iface eth0 reboot now ping 192.168.2.240
Example output :
root@orangepizero:~# nmcli con add con-name "static-eth0" ifname eth0 type ethernet ip4 192.168.2.240/24 gw4 10.10.10.1 Connection 'static-eth0' (10bfb697-f23b-48ea-bfcd-86077890aca9) successfully added. root@orangepizero:~# nmcli con mod "static-eth0" ipv4.dns "192.168.2.1,8.8.8.8" root@orangepizero:~# nmcli con up "static-eth0" iface eth0 Unknown parameter: iface Unknown parameter: eth0