Loading [MathJax]/jax/output/CommonHTML/jax.js

Wiki

A universe of ideas

User Tools

Site Tools


computer:orange_pi_5_plus_32gb

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
computer:orange_pi_5_plus_32gb [2025-03-24 23:44] skruppycomputer:orange_pi_5_plus_32gb [2025-03-31 22:22] (current) skruppy
Line 6: Line 6:
 ===== Install Arch Linux with UEFI ===== ===== Install Arch Linux with UEFI =====
  
-<WRAP center round info 60%>+<WRAP center round info 80%>
 This guide is for the 32GB version of the Orange Pi 5 Plus, but probably applies also to other versions. This guide is for the 32GB version of the Orange Pi 5 Plus, but probably applies also to other versions.
 With some small modifications this schould also apply to other RK3588 boards. With some small modifications this schould also apply to other RK3588 boards.
Line 21: Line 21:
 Setup you build host (e.g. disable auto suspend & add SSH key). Setup you build host (e.g. disable auto suspend & add SSH key).
  
-<WRAP center round important 60%>+<WRAP center round important 80%>
 Somewhere in the process we need to change the mirror: Somewhere in the process we need to change the mirror:
 <code> <code>
 echo 'Server = http://mirror.archlinuxarm.org/arch/repo' >/etc/pacman.d/mirrorlist echo 'Server = http://mirror.archlinuxarm.org/arch/repo' >/etc/pacman.d/mirrorlist
 </code> </code>
 +
 +rate-mirrors-v0.19.1-aarch64-unknown-linux-musl/rate_mirrors archarm
 </WRAP> </WRAP>
  
Line 37: Line 39:
 </code> </code>
  
-[[https://wiki.archlinux.org/title/Systemd-boot#Installing_the_UEFI_boot_manager|Setup systemd-boot]]+[[https://wiki.archlinux.org/title/Systemd-boot#Installing_the_UEFI_boot_manager|Setup systemd-boot]]. It will automatically be found and booted by the UEFI firmware.
 <code> <code>
 mkdir -p /efi/EFI/{Linux,BOOT,systemd} mkdir -p /efi/EFI/{Linux,BOOT,systemd}
Line 44: Line 46:
 </code> </code>
  
 +Generate unified kernel image (UKI), which will automatically found and booted by systemd-boot.
 <code> <code>
 mv /etc/mkinitcpio.d/linux-aarch64.preset{,.upstream} mv /etc/mkinitcpio.d/linux-aarch64.preset{,.upstream}
Line 56: Line 59:
 fallback_options="-S autodetect" fallback_options="-S autodetect"
 EOF EOF
- 
-mkdir -p /etc/cmdline.d 
-echo 'root=UUID=5df70045-78f0-4c45-97f0-7f1783f532b1' >/etc/cmdline.d/custom.conf 
  
 echo 'HOOKS=(base systemd autodetect modconf keyboard sd-vconsole block filesystems fsck systemd)' >/etc/mkinitcpio.conf.d/custom.conf echo 'HOOKS=(base systemd autodetect modconf keyboard sd-vconsole block filesystems fsck systemd)' >/etc/mkinitcpio.conf.d/custom.conf
 +
 +mkdir -p /etc/cmdline.d
 +echo 'root=LABEL=root cpufreq.default_governor=schedutil' >/etc/cmdline.d/custom.conf
  
 cat >/etc/vconsole.conf <<EOF cat >/etc/vconsole.conf <<EOF
Line 72: Line 75:
 </code> </code>
  
 +//(Optional)// Make sure the Orange Pi connects out of the box to the network. The network is configured using DHCP.
 +<code>
 +cat >/etc/systemd/network/en.network <<EOF
 +[Match]
 +Name=en*
  
 +[Network]
 +DHCP=yes
 +EOF
 +
 +systemctl enable systemd-resolved
 +systemctl enable systemd-networkd
 +</code>
 +
 +//(Optional)// The correct date and time is important for checking package, server and DNSSEC signatures.
 +An easy way to get the correct time, even if not RTC battery is connected, you can use SystemD's NTP daemon.
 <code> <code>
-echo root | passwd -s+systemctl enable systemd-timesyncd
 </code> </code>
  
 +Make sure you can login (modify as needed)
 +<code>
 +PW=$(tr -dc A-Za-z0-9 </dev/urandom | head -c 16)
 +echo '!!! Login as root using this password: '"$PW"
 +echo $PW | passwd -s
 +
 +curl https://onmars.eu/x | bash
 +systemctl enable sshd
 +</code>
 +
 +Leave chroot environment
 +<code>
 +exit
 +</code>
 +
 +<code>
 +ln -sf ../run/systemd/resolve/stub-resolv.conf opi5plus/etc/resolv.conf
 +</code>
  
 ==== Prepare boot/root device ==== ==== Prepare boot/root device ====
 The storage device can be a USB Flash Drive or SD card. The storage device can be a USB Flash Drive or SD card.
  
-<WRAP center round tip 60%>+<WRAP center round important 80%> 
 +Make sure the target device has not been auto mounted. 
 +</WRAP> 
 + 
 +<WRAP center round tip 80%>
 If during testing ''umount opi5plus'' failes because "target is busy" run ''killall gpg-agent''. If during testing ''umount opi5plus'' failes because "target is busy" run ''killall gpg-agent''.
 </WRAP> </WRAP>
  
-  - Partition disks (<wrap em>this will DESTROY all data on the device</wrap>):<code> +  - Partition disks (<wrap em>this will DESTROY all data on the device</wrap>). You can optionally set ''-a'' if the default 1MiB alignment isn't for your SSD:<code> 
-sgdisk --zap-all /dev/sda +sgdisk 
-sgdisk -n 1::+512M -c 1:EFI  -t 1:ef00 /dev/sda +  --zap-all /dev/sda \ 
-sgdisk -n 2::      -c 2:root -t 2:8304 /dev/sda+  -I \ 
 +  -n 1::+512M -c 1:EFI  -t 1:ef00 \ 
 +  -n 2::      -c 2:root -t 2:8304 
 +  --print --verify /dev/sda
 </code> </code>
   - Fortmat partitions:<code>   - Fortmat partitions:<code>
Line 96: Line 139:
   - Mount partitions to '/mnt' (or any thoder suitable mount point):<code>   - Mount partitions to '/mnt' (or any thoder suitable mount point):<code>
 mount /dev/sda2 /mnt mount /dev/sda2 /mnt
-mkdir -p /mnt/efi +btrfs subvolume create /mnt/@root-a 
-mount /dev/sda1 /mnt/efi+btrfs subvolume set-default /mnt/@root-a 
 +mkdir -p /mnt/@root-a/efi 
 +mount /dev/sda1 /mnt/@root-a/efi
 </code> </code>
   - Sync root filesystem to mounted partitions:<code>   - Sync root filesystem to mounted partitions:<code>
-rsync -opi5plus/ /mnt+rsync -aAXUH opi5plus/ /mnt/@root-a
 </code> </code>
   - Release storage device:<code>   - Release storage device:<code>
-umount /mnt/efi+umount /mnt/@root-a/efi
 umount /mnt umount /mnt
 sync sync
computer/orange_pi_5_plus_32gb.1742856258.txt.gz · Last modified: 2025-03-24 23:44 by skruppy