User Tools

Site Tools


os:archlinux:aarch64

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
os:archlinux:aarch64 [2025/03/27 11:39] warnaudos:archlinux:aarch64 [2025/03/27 16:44] (current) – [Hyprland] warnaud
Line 1: Line 1:
 +====== Archlinux on Silicon Procs ======
 +Doc to set it up on UTM
 +===== Alpine Linux =====
 +First Download the aarch64 iso -> https://alpinelinux.org/downloads/ | https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/aarch64/
 +===== UTM setup =====
 +Create a New VM
 +Type: Other
 +add the CD/DVD boot ise file (Alpine ISO)
 +Edit the display settings for "ramfb"
 +===== Boot on Alpine =====
 +==== Basic setup ====
 +<code bash> setup-alpine</code>
 +Mostly [Enter] even for disk...
 +==== Let's go ====
 +<code bash>apk update
 +apk add curl tar gptfdisk btrfs-progs</code>
 +<code>
 +gdisk /dev/vda
 +GPT fdisk (gdisk) version 1.0.10
 +
 +Partition table scan:
 +  MBR: not present
 +  BSD: not present
 +  APM: not present
 +  GPT: not present
 +
 +Creating new GPT entries in memory.
 +
 +Command (? for help): o
 +This option deletes all partitions and creates a new protective MBR.
 +Proceed? (Y/N): Y
 +
 +Command (? for help): n
 +Partition number (1-128, default 1): 
 +First sector (34-134217694, default = 2048) or {+-}size{KMGTP}: 
 +Last sector (2048-134217694, default = 134215679) or {+-}size{KMGTP}: +2G
 +Current type is 8300 (Linux filesystem)
 +Hex code or GUID (L to show codes, Enter = 8300): ef00
 +Changed type of partition to 'EFI system partition'
 +
 +Command (? for help): n
 +Partition number (2-128, default 2): 
 +First sector (34-134217694, default = 4196352) or {+-}size{KMGTP}: 
 +Last sector (4196352-134217694, default = 134215679) or {+-}size{KMGTP}: 
 +Current type is 8300 (Linux filesystem)
 +Hex code or GUID (L to show codes, Enter = 8300): 
 +Changed type of partition to 'Linux filesystem'
 +
 +Command (? for help): p
 +Disk /dev/vda: 134217728 sectors, 64.0 GiB
 +Sector size (logical/physical): 512/512 bytes
 +Disk identifier (GUID): CC9275CB-EC7E-42E7-8567-967F8A3BCCBD
 +Partition table holds up to 128 entries
 +Main partition table begins at sector 2 and ends at sector 33
 +First usable sector is 34, last usable sector is 134217694
 +Partitions will be aligned on 2048-sector boundaries
 +Total free space is 4029 sectors (2.0 MiB)
 +
 +Number  Start (sector)    End (sector)  Size       Code  Name
 +              2048         4196351   2.0 GiB     EF00  EFI system partition
 +           4196352       134215679   62.0 GiB    8300  Linux filesystem
 +
 +Command (? for help): w
 +
 +Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING
 +PARTITIONS!!
 +
 +Do you want to proceed? (Y/N): y
 +OK; writing new GUID partition table (GPT) to /dev/vda.
 +The operation has completed successfully.</code>
 +==== Format ====
 +<code bash>
 +mkfs.vfat -F32 /dev/vda1          # Format EFI partition
 +mkfs.btrfs -L ROOT /dev/vda2      # Format root partition</code>
 +==== Mount ====
 +<code bash>rm -rf /mnt/*
 +modprobe btrfs
 +mount /dev/vda2 /mnt
 +mkdir -p /mnt/boot/efi
 +
 +modprobe vfat
 +mount /dev/vda1 /mnt/boot/efi
 +</code>
 +==== DL Arch ====
 +<code bash>curl -L https://archlinuxarm.org/os/ArchLinuxARM-aarch64-latest.tar.gz -o /archlinuxarm.tar.gz
 +tar -xpf /archlinuxarm.tar.gz -C /mnt
 +
 +sync
 +</code>
 +==== CHROOT ====
 +<code bash>
 +mount --bind /dev /mnt/dev
 +mount --bind /proc /mnt/proc
 +mount --bind /sys /mnt/sys
 +</code>
 +<code bash> cp /etc/resolv.conf /mnt/etc/resolv.conf</code>
 +<code bash>chroot /mnt /bin/bash</code>
 +==== Config ====
 +=== Pacman ===
 +<code bash>pacman-key --init
 +pacman-key --populate archlinuxarm
 +pacman -Syu</code>
 +If it fails... edit mirrorlist to uncomment the closest alive:
 +<code bash>vi /etc/pacman.d/mirrorlist</code>
 +⇒ Server = http://de3.mirror.archlinuxarm.org/
 +=== Linux & Grub ===
 +<code bash> pacman -S linux linux-firmware grub</code>
 +=== FSTAB ===
 +<code bash>
 +pacman -S arch-install-scripts
 +genfstab -U / >> /etc/fstab</code>
 +
 +=== Hostname  ===
 +<code bash>echo "alarm" > /etc/hostname</code>
 +=== Network ===
 +<code bash>
 +systemctl enable dhcpcd
 +</code>
 +=== User ===
 +<code bash>
 +useradd -m -G wheel -s /bin/bash yourusername
 +passwd yourusername
 +echo "%wheel ALL=(ALL) ALL" >> /etc/sudoers
 +</code>
 +=== Final touch ===
 +<code bash>
 +pacman -S grub sudo
 +grub-install --target=arm64-efi --efi-directory=/boot/efi --bootloader-id=GRUB
 +grub-mkconfig -o /boot/grub/grub.cfg
 +
 +exit
 +poweroff</code>
 +
 +==== Important INFO ====
 +  * /dev/vda1 (efi partition) MUST be mounted on /boot/efi
 +
 +
 +remove Alpine ISO\\
 +Light a candle... boot\\
 +If stuck:\\
 +<code bash>
 +fs0:
 +cd EFI\ArchARM
 +grubaa64.efi</code>
 +
 +===== SSH =====
 +crap in /etc/ssh/sshd_config.d/* is preventing ssh-copy-id to work (good job!)
 +
 +===== Hyprland =====
 +<code bash>
 +pacman -Syu
 +pacman -S base-devel git
 +pacman -S wayland wlroots xorg-server xorg-xwayland mesa seatd pipewire pipewire-pulse wireplumber vulkan-virtio spice-vdagent qemu-guest-agent kitty mesa glxinfo
 +
 +systemctl enable --now seatd
 +
 +export LIBSEAT_BACKEND=seatd
 +</code>
 +as normal user...
 +<code bash>
 +git clone https://aur.archlinux.org/yay.git
 +cd yay
 +makepkg -si
 +
 +sudo pacman -S lightdm lightdm-gtk-greeter
 +sudo systemctl enable lightdm
 +</code>
 +
 +Vérifier que l'"input" Display dans UTM est "virtio-gpu-gl-pci"
 +
 +Reboot... To be continued car la conf de base utilise tous les raccourcis MacOS/UTM.... et kitty se lance pas
 +
 +