I got Arch Linux ARM installed on a Lenovo Chromebook Duet! I mostly used the instructions from the Arch Wiki as reference.
- Enable Linux development environment in Chrome OS's settings
- Get it running
This comes with Debian by default, but this guide will install Arch Linux alongside that.
(ctrl-alt-t)
# ^ Opens the crosh shell
#
# › crosh>
vmc start termina
# ^ Enters the Linux VM ("termina"). From this VM, we
# will create an LXC container from the Arch Linux image.
#
# › (termina) chronos@localhost ~ $
lxc launch images:archlinux/current arch
# ^ Creates the LXC container with Arch Linux.
# This will take a LONG time.
#
# › Creating arch
# Starting arch
lxc list
# ^ It should now be started and in this list after that.
#
# > | NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
# | arch | RUNNING | | | PERSISTENT | 0 |
# | penguin | STOPPED | | | PERSISTENT | 0 |
lxc exec arch bash
# ^ Enter the container.
# If you see the prompt below, you're now in Arch!
#
# > [root@arch ~]#There's already a default user (alarm). I renamed that to my own preferred name.
grep 1000:1000 /etc/passwd
# ^ Shows the default user. It's usually `alarm` for
# the ARM build, but I haven't tried it elsewhere.
#
# > alarm
groupmod -n tony alarm
usermod -d /home/tony -l tony -m -c tony alarm
# ^ Rename that user. I name mine `tony`. This should
# be the same username that was used to set up the
# default Debian environment.
passwd tony
# ^ Change passwd
visudo
# ^ Uncomment the line that says:
# %wheel ALL=(ALL) NOPASSWD ALL
usermod -aG wheel tony
# ^ Gives sudo rights to userhttps://wiki.archlinux.org/title/LXD#No_IPv4_with_systemd-networkd
Now that there's a user (tony), I logged on directly with it and did the first system update (pacman -Syu).
exit
# ^ Go back to termina if you're still inside Arch
# > (termina) chronos@localhost ~ $
lxc exec arch su - tony
# ^ Log in as the user
#
# > [rsc@arch ~]$
sudo nano /etc/pacman.d/mirrorlist
# ^ Optional: Use a closer mirror. Eg, change
# mirror.archlinuxarm.org => au.mirror.archlinuxarm.org
#
# A full list of mirrors are in this page:
# https://archlinuxarm.org/about/mirrors
sudo nano /etc/pacman.conf
# ^ Optional: Update pacman config. I prefer to:
# - uncomment #Color
# - uncomment #ParallelDownloads = 5
sudo pacman -Syu base-devel git curl make neovim wl-clipboard
# ^ Installs some packages# This step requires `base-devel`, which was installed
# in a previous step. If there are errors about
# fakeroot, try: sudo pacman -Syu base-devel
git clone https://aur.archlinux.org/yay.git
cd yay
makepkg -sicros-container-guest-tools allows X apps to work. It can be installed using yay.
yay -S cros-container-guest-tools-git
cp -r /etc/skel/.config/pulse ~/.config/pulse
# ^ As directed by the post-install message. This will
# enable audio to wor.
yay -S xorg-xwayland wayland
yay -S mousepad
# ^ Install a basic text editor so we can test it out
exit
# ^ Go back to termina
# (termina) chronos@localhost ~ $
lxc console arch
# ^ Log in via tty. This has no colours, but it
# will be necessary to start/enable user services.
#
# > To detach from the console, press: <ctrl>+a q
# arch login: tony
# password:
# [tony@arch ~]$
systemctl enable --now --user sommelier{,-x}@{0,1}.service
# ^ Starts and enables X11 and Wayland bridges
#
# > Created symlink /home/rsc/.config/systemd/user/default.target.wants/[email protected] -> /usr/lib/systemd/user/[email protected].
# Created symlink /home/rsc/.config/systemd/user/default.target.wants/[email protected] -> /usr/lib/systemd/user/[email protected].
# Created symlink /home/rsc/.config/systemd/user/default.target.wants/[email protected] -> /usr/lib/systemd/user/[email protected].
# Created symlink /home/rsc/.config/systemd/user/default.target.wants/[email protected] -> /usr/lib/systemd/user/[email protected].
mousepad
# ^ If it worked, this will open up a mousepad windowThe default image is Debian (penguin), but we can move that away and make Arch the default. To do this, we'll rename the LXC image to penguin.
# ^ Start in termina
# (termina) chronos@localhost ~ $
lxc list
lxc stop arch
lxc stop penguin
# ^ Stop all LXC containers that are `RUNNING`
lxc rename penguin google
lxc rename arch penguin
# ^ Swap out the names
exit
# ^ Go back to crosh
# > crosh>
vmc list
vmc stop termina
vmc stop dev
# ^ Stop all VMs
# ... after this, run the Terminal and it should boot
# up with your user

