Orange Pi Zero 3 - микрокомпьютер на микропроцессоре Allwinner H618. Orange Pi Zero 3 выпускают с 1Gb, 1.5Gb, 2Gb и 4Gb оперативной памяти. В качестве постоянного запоминающего устройства используется micro SD Flash карта.

Опишем процесс установки операционной системы Linux Ubuntu Nobile (24.04) server и desktop на Orange Pi Zero 3.

Установка Ubuntu server на Orange Pi Zero2. Используем файл образа Ubuntu 22.04 Jammi (20.04 Focal) server с сайта orangepi.org. Файлы образов можно выбрать на странице этого сайта serviceAndSupport и скачать через Google disk.

Архив с образом необходимо распаковать и проверить на целостность.

sha256sum -c *.sha

Для записи образа операционной системы на micro SD Flash карту используем программу balenaEtcher. Ссылка для скачивания balenaEtcher. Программу balenaEtcher устанавливать не надо, по ссылке загружается архив программы. Скачиваем, разархивируем и запускаем двойным щелчком. BalenaEtcher работает на Linux, Windows и macOS.

При первом старте сервера происходит подготовка SD карты к использованию.

  ___  ____ ___   _____             _____ 
 / _ \|  _ \_ _| |__  /___ _ __ ___|___ / 
| | | | |_) | |    / // _ \ '__/ _ \ |_ \ 
| |_| |  __/| |   / /|  __/ | | (_) |__) |
 \___/|_|  |___| /____\___|_|  \___/____/ 
                                          
Welcome to Orange Pi 1.0.6 Noble with Linux 6.1.31-sun50iw9

System load:   27%           	Up time:       5 min	Local users:   3            	
Memory usage:  4% of 3.84G  	IP:	       192.168.1.12
CPU temp:      51°C           	Usage of /:    4% of 58G

Используйте login root или orangepi, пароль orangepi.

Рекомендуется использовать micro SD Flash карту с торговой маркой SanDisk class 10.

Обновите операционную систему.

sudo apt update
sudo apt upgrade

Некоторые настройки можно сделать с помощью утилиты sudo orangepi-config

sudo orangepi-config

Утилита orangepi-config предлагает диалоговый режим:

Рис. 1. Orangepi-config.

Рис. 1. HTop.

Настройка поддержки русского языка

Проверим языки установлены в системе.

locale -a
C
C.utf8
POSIX

Лист. 5.

Приступаем к настройкам.

sudo dpkg-reconfigure locales
   ┌────────────────────────────────┤ Configuring locales ├─────────────────────────────────┐
   │ Locales are a framework to switch between multiple languages and allow users to use    │ 
   │ their language, country, characters, collation order, etc.                             │ 
   │                                                                                        │ 
   │ Please choose which locales to generate. UTF-8 locales should be chosen by default,    │ 
   │ particularly for new installations. Other character sets may be useful for backwards   │ 
   │ compatibility with older systems and software.                                         │ 
   │                                                                                        │ 
   │ Locales to be generated:                                                               │ 
   │                                                                                        │ 
   [ ] ro_RO.UTF-8 UTF-8                                                              
   [*] ru_RU.UTF-8 UTF-8                                                              
   [ ] ru_UA.UTF-8 UTF-8                                                              
   │                                                                                        │ 
   │                                                                                        │ 
   <Ok>                            <Cancel>                        │ 
   │                                                                                        │ 
   └────────────────────────────────────────────────────────────────────────────────────────┘ 
                                                                                              
 ┌──────────────────────────────────┤ Configuring locales ├──────────────────────────────────┐
 │ Many packages in Debian use locales to display text in the correct language for the       │ 
 │ user. You can choose a default locale for the system from the generated locales.          │ 
 │                                                                                           │ 
 │ This will select the default language for the entire system. If this system is a          │ 
 │ multi-user system where not all users are able to speak the default language, they will   │ 
 │ experience difficulties.                                                                  │ 
 │                                                                                           │ 
 │ Default locale for the system environment:                                                │ 
 │                                                                                           │ 
 │                                       None                                                │ 
 │                                       C.UTF-8                                             │ 
 ru_RU.UTF-8  
 │                                                                                           │ 
 │                                                                                           │ 
 <Ok>                             <Cancel>                         │ 
 │                                                                                           │ 
 └───────────────────────────────────────────────────────────────────────────────────────────┘ 
                                                                                               
sudo dpkg-reconfigure tzdata
 ┌──────────────────────────────────┤ Configuring tzdata ├───────────────────────────────────┐
 │ Please select the geographic area in which you live. Subsequent configuration questions   │ 
 │ will narrow this down by presenting a list of cities, representing the time zones in      │ 
 │ which they are located.                                                                   │ 
 │                                                                                           │ 
 │ Geographic area:                                                                          │ 
 │                                                                                           │ 
 │                                       Atlantic       ↑                                    │ 
 │                                       Australia      ▒                                    │ 
 Europe         ▒                                    │ 
 │                                       Indian         ▮                                    │ 
 │                                       Pacific        ▒                                    │ 
 │                                       Etc            ↓                                    │ 
 │                                                                                           │ 
 │                                                                                           │ 
 <Ok>                             <Cancel>                         │ 
 │                                                                                           │ 
 └───────────────────────────────────────────────────────────────────────────────────────────┘ 
                                                                                               
             ┌───────────────────────┤ Configuring tzdata ├───────────────────────┐
             │ Please select the city or region corresponding to your time zone.  │ 
             │                                                                    │ 
             │ Time zone:                                                         │ 
             │                                                                    │ 
             │                           Minsk           ↑                        │ 
             │                           Monaco          ▒                        │ 
             Moscow          ▒                        │ 
             │                           Nicosia         ▮                        │ 
             │                           Oslo            ▒                        │ 
             │                           Paris           ▒                        │ 
             │                           Podgorica       ▒                        │ 
             │                           Prague          ↓                        │ 
             │                                                                    │ 
             │                                                                    │ 
             <Ok>                     <Cancel>                  │ 
             │                                                                    │ 
             └────────────────────────────────────────────────────────────────────┘ 
                                                                                    
Current default time zone: 'Europe/Moscow'
Local time is now:      Sun Feb  2 19:43:36 MSK 2025.
Universal Time is now:  Sun Feb  2 16:43:36 UTC 2025.
sudo dpkg-reconfigure console-setup
                            ┌────┤ Configuring console-setup ├─────┐
                            │                                      │ 
                            │                                      │ 
                            │ Encoding to use on the console:      │ 
                            │                                      │ 
                            │         ISO-8859-7           ↑       │ 
                            │         ISO-8859-8           ▒       │ 
                            │         ISO-8859-9           ▒       │ 
                            │         KOI8-R               ▒       │ 
                            │         KOI8-U               ▒       │ 
                            │         TIS-620              ▮       │ 
                            UTF-8                ▒       │ 
                            │         VISCII               ↓       │ 
                            │                                      │ 
                            │                                      │ 
                            │       <Ok>           <Cancel>        │ 
                            │                                      │ 
                            └──────────────────────────────────────┘ 
                                                                     
Package configuration────────────┤ Configuring console-setup ├───────────────────────┐
         │ Please choose the character set that should be supported by the console   │ 
         │ font.                                                                     │ 
         │                                                                           │ 
         │ If you don't use a framebuffer, the choices that start with "." will      │ 
         │ reduce the number of available colors on the console.                     │ 
         │                                                                           │ 
         │ Character set to support:                                                 │ 
         │                                                                           │ 
         │      . Arabic                                                        ↑    │ 
         │      # Armenian                                                      ▮    │ 
         # Cyrillic - KOI8-R and KOI8-U                                  ▒    │ 
         │      # Cyrillic - non-Slavic languages                               ▒    │ 
         │      . Cyrillic - non-Slavic languages (for blind users)             ▒    │ 
         │      # Cyrillic - Slavic languages (also Bosnian and Serbian ...     ▒    │ 
         │      . Cyrillic - Slavic languages (for blind users)                 ↓    │ 
         │                                                                           │ 
         │                                                                           │ 
         <Ok>                        <Cancel>                   │ 
         │                                                                           │ 
         └───────────────────────────────────────────────────────────────────────────┘ 
                                                                                       
Package configuration────────────┤ Configuring console-setup ├───────────────────────┐
         │ "VGA" has a traditional appearance and has medium coverage of             │ 
         │ international scripts. "Fixed" has a simplistic appearance and has        │ 
         │ better coverage of international scripts. "Terminus" may help to reduce   │ 
         │ eye fatigue, though some symbols have a similar aspect which may be a     │ 
         │ problem for programmers.                                                  │ 
         │                                                                           │ 
         │ If you prefer a bold version of the Terminus font, choose either          │ 
         │ TerminusBold (if you use a framebuffer) or TerminusBoldVGA (otherwise).   │ 
         │                                                                           │ 
         │ Font for the console:                                                     │ 
         │                                                                           │ 
         Fixed                                     ↑               │ 
         │                 Terminus                                  ▮               │ udo systemctl list-units --state=failed
[sudo] password for dior:
UNIT LOAD ACTIVE SUB DESCRIPTION
● smartmontools.service loaded failed failed Self Monitoring and Reporting Technology (SMART) Daemon

Legend: LOAD → Reflects whether the unit definition was properly loaded.
ACTIVE → The high-level unit activation state, i.e. generalization of SUB.
SUB → The low-level unit activation state, values depend on unit type.
│ TerminusBold ▒ │ │ TerminusBoldVGA ↓ │ │ │ │ │ │ <Ok> <Cancel> │ │ │ └───────────────────────────────────────────────────────────────────────────┘
           ┌─────────────────────┤ Configuring console-setup ├──────────────────────┐
           │ Please select the size of the font for the console.  Some font sizes   │ 
           │ require framebuffer.                                                   │ 
           │                                                                        │ 
           │ Font size:                                                             │ 
           │                                                                        │ 
           │                                 8x13                                   │ 
           │                                 8x14                                   │ 
           │                                 8x15                                   │ 
           8x16  
           │                                 8x18                                   │ 
           │                                                                        │ 
           │                                                                        │ 
           │                   <Ok>                       <Cancel>                  │ 
           │                                                                        │ 
           └────────────────────────────────────────────────────────────────────────┘ 
                                                                                      

Лист. 6

Эту команду надо выполнить локально:

sudo dpkg-reconfigure keyboard-configuration
reboot

Лист. 7

Поменяем пользователя

sudo adduser newuser

Лист. 8.

groups
orangepi tty disk dialout sudo audio video plugdev games users netdev input systemd-journal

Лист. 9.

sudo usermod -a -G orangepi,tty,disk,dialout,sudo,audio,video,plugdev,games,users,netdev,input,systemd-journal newuser

Лист. 10.

Удаляем пользователя orangepi

# 1. Завершить процессы и сессии
sudo pkill -9 -u orangepi
sudo loginctl terminate-user orangepi

# 2. Остановить и отключить службы
sudo systemctl stop orangepi-* --ignore-errors
sudo systemctl disable orangepi-* --now

# 3. Удалить конфигурацию автологина
sudo sed -i '/autologin-user=orangepi/d' /etc/lightdm/lightdm.conf
sudo rm /etc/systemd/system/Адрес электронной почты защищен от спам-ботов. Для просмотра адреса в вашем браузере должен быть включен Javascript..d/*autologin*.conf

# 4. Удалить пользователя и данные
sudo userdel -r orangepi
sudo rm -rf /var/lib/systemd/linger/orangepi

# 5. Почистить оставшиеся файлы
sudo find / -user orangepi 2>/dev/null | xargs sudo rm -rf --
sudo rm /etc/systemd/system/orangepi-*.target 2>/dev/null
sudo systemctl daemon-reload

# 6. Проверить результат
sudo systemctl --all | grep orangepi
id orangepi 2>/dev/null || echo "Пользователь удален"

Лист. 11.

Отключаем автоматический вход пользователя orangepi в систему.

# 1. Удалите проблемные конфиги автовхода
sudo rm /lib/systemd/system/getty@.service.d/override.conf
sudo rm /lib/systemd/system/serial-getty@.service.d/override.conf

# 2. Отключите сервис автовхода Orange Pi
sudo systemctl disable orangepi-disable-autologin.service
sudo systemctl stop orangepi-disable-autologin.service

# 3. Перезагрузите системные сервисы
sudo systemctl daemon-reload

# 4. Пересоздайте стандартные настройки Getty
sudo cp /lib/systemd/system/getty@.service /etc/systemd/system/getty@.service
sudo systemctl restart getty@tty1

Лист. 12.

Проверяем наличие ошибок в системе.

sudo systemctl list-units --state=failed

Лист. 13.

Установка рабочего стола

sudo apt install xorg lxqt-core sddm --no-install-recommends

Лист. 14. Установка графической подсистемы.

sudo apt install openbox obconf lxqt-config -y

Лист. 15. Установите openbox (если не установлен).

echo "window_manager=openbox" >> ~/.config/lxqt/session.conf

Лист. 16. Установка OpenBox как оконного менеджера по умолчанию.

mkdir -p ~/.config/openbox
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/
cp /etc/xdg/openbox/menu.xml ~/.config/openbox/

Лист. 17. Создание файлов минимальной конфигурации OpenBox для пользователя.

sudo apt install linux-firmware
echo "dtoverlay=panfrost" | sudo tee -a /boot/firmware/config.txt

Лист. 18. Настройка драйверов Mali.

sudo apt install mesa-utils libgl1-mesa-dri libglx-mesa0 libegl-mesa0 -y
sudo apt install libgl1 --no-install-recommends -y
sudo apt-get install libglu1-mesa-dev freeglut3-dev mesa-common-dev
sudo apt-get install qtcreator libglfw3-dev libglm-dev libepoxy-dev libboost-all-dev libglew-dev libopenal-dev libalut-dev

Лист. 19. Установите необходимые утилиты.

glxinfo | grep "OpenGL renderer"

OpenGL renderer string: Mali-G31 (Panfrost)

Лист. 20. Проверьте работу GPU.

sudo apt install pcmanfm-qt qterminal firefox-esr

Лист.