You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fdisk /dev/vda
Command (m for help): g
Created a new GPT disklabel (GUID: 56905986-F7A8-4848-8F81-CBE765CE8154).
Command (m for help): n
Partition number (1-128, default 1):
First sector (2048-97656216, default 2048):
Last sector, +/-sectors or +/-size{K,M,G,T,P} (2048-97656216, default 97656216): +512M
Created a new partition 1 of type'Linux filesystem' and of size 512 MiB.
Command (m for help): t
Selected partition 1
Partition type or alias (type L to list all): 1
Changed type of partition 'Linux filesystem' to 'EFI System'.
Command (m for help): n
Partition number (2-128, default 2):
First sector (1050624-97656216, default 1050624):
Last sector, +/-sectors or +/-size{K,M,G,T,P} (1050624-97656216, default 97656216):
Created a new partition 2 of type'Linux filesystem' and of size 46.1 GiB.
Command (m for help): w
# format disk
mkfs.vfat -F 32 /dev/vda1
mkfs.ext4 /dev/vda2
Install Archlinux AArch64 base system.
mount /dev/vda2 /mnt/gentoo
cd /mnt/gentoo/
wget http://os.archlinuxarm.org/os/ArchLinuxARM-aarch64-latest.tar.gz
tar -xpf ArchLinuxARM-aarch64-latest.tar.gz -C ./
mv boot ./boot_tmp
mkdir ./boot
mount /dev/vda1 ./boot
cp -r ./boot_tmp/* ./boot/
Chrooting
mount --types proc /proc /mnt/gentoo/proc
mount --rbind /sys /mnt/gentoo/sys
mount --make-rslave /mnt/gentoo/sys
mount --rbind /dev /mnt/gentoo/dev
mount --make-rslave /mnt/gentoo/dev
mount --bind /run /mnt/gentoo/run
mount --make-slave /mnt/gentoo/run
chroot /mnt/gentoo /bin/bash
source /etc/profile
export PS1="(chroot) ${PS1}"