Make your own archiso
2026-02-10
the Arch live environment is pretty good already, but for convenience we can change a few small things to make using it more enjoyable.
I like having SSH access the moment it's booted, and to make that secure enough i add my SSH public key to /root/authorized_keys . I also do not use the US keyboard layout, and i don't like the "PC beep" it does in certain situations.
For installing arch, i also add some files like /etc/locale.gen and /etc/locale.conf so i can simply copy these into the new arch installation and don't have to edit manually.
Preparation
- this tutorial assumes you are on a working archlinux commandline.
- ensure package archiso is installed
- i like working as root for this, so i have a dir /root/isomaking
- From now in i'll assume the workingdir is /root/isomaking
- have the bootable media (usb) ready to go. NOT mounted! we will wipe it completely.
Prepare releng
- first, i recommend updating your archlinux in case anything has changed, it may avoid some errors.
- copy the latest "releng" profile into /root/isomaking (delete the old one if applicable): cp -r /usr/share/archiso/configs/releng /root/isomaking/releng
Prepare airootfs (archiso root filesystem)
- in theory you can place files in the releng dir, but its easier to update that if you keep them seperate
- mkdir -p airootfs/etc
- mkdir -p airootfs/root/.ssh
- Place the files you'll want in there (assuming your current system is config'd nicely):
- cp /etc/vconsole.conf airootfs/etc/vconsole.conf
- cp (your-authorized-keys-file) airootfs/root/.ssh
- additional files you might want in the live system
- for the beeper: create etc/modprobe.d/ as well and put nobeep.conf in there. archwiki. contents: blacklist pcspkr
- doublecheck latest sshd settings - usually, root login via keypair is allowed, but if that changes or you want to allow password login too, ship a /etc/ssh/sshd_config file as well.
- Ensure .ssh and authorized-keys permissions:
- chmod 700 airootfs/root/.ssh && chmod 644 airootfs/root/.ssh/authorized_keys
Copy our wanted files into the "releng" dir:
- cp -r airootfs/* releng/airootfs/
Make our iso and write it to usb
- first, delete the working and output dirs if they exist:
- rm -r work && rm -r out
- make our iso:
- mkarchiso -v releng
- this should take a moment, and give us our iso in the "out" directory
- write it to usb stick (i like cat)
- cat out/(iso-file) > /dev/(your-usb-device) DATA ON IT WILL BE GONE
- find your usb device with lsblk, usually it'd be /dev/sda or /dev/sdb (do NOT write it to /dev/sda1 or similar, write it to the entire drive)
Now you should be able to boot that usb into a live environment with your chosen settings. If you assigned your device's MAC address a fixed IP address in your router, you can easily "ssh root@192.168.0.yourip" and have access if you did the authorized_keys file and your ssh setup correctly. if not you'll have to find the device's IP first. if SSH gives you trouble because of "changed host identification", you should be able to remove the entry with ssh-keygen -R 192.168.0.yourip and try again.
Fun fact: you could make an entire distro out of this by adding some graphical desktop environment and a few other things. but that will take some maintenance, my setup has been the same for years now and i haven't had issues (as long as i remember to get the lastest releng profile and delete the work dir).