Skip to content

Instantly share code, notes, and snippets.

@jhillix
Last active January 21, 2024 09:05
Show Gist options
  • Save jhillix/c0612f2f57b85b2390ba5241dc18449b to your computer and use it in GitHub Desktop.
Save jhillix/c0612f2f57b85b2390ba5241dc18449b to your computer and use it in GitHub Desktop.

Arch Linux Setup with XFCE4 on Rpi 3B

Purpose

The purpose for this Gist is to document for myself the steps to setup Arch Linux ARM on a Pi 3 with XFCE4 as the desktop environment. As well as, configuring XFCE4 to look like MacOS BigSur. Maybe someone else will find this useful/helpful.

NOTE: As of the time of this writing, ArchLinuxARM-rpi-armv7-latest has Xorg driver issues. Meaning, I was not able to use ArchLinuxARM-rpi-armv7-latest with a desktop environment. Just a black screen. I came to this deduction via trial & error and reading the Arch Linux ARM forums like here and here.

NOTE 2: Pay attention to $ and # when commands are shown. # indicates that the command needs to be run as root - - OR - - with elevated priveleges. $ indicates that the command is invoked as a regular user.

Steps Overview

  1. Install Arch Linux ARM
  2. Configure WiFi
  3. Update system
  4. Configure timezone
  5. Update system time
  6. Configure locale
  7. User setup
  8. Configure swap
  9. Tune swappiness
  10. Install XFCE4
  11. Install display manager
  12. XFCE Configuration
  13. MacOS BigSur

Step 1 - Install Arch Linux ARM

No need to duplicate - follow the steps for AArch64 Installation

Step 2 - Configure WiFi

  1. # nano /etc/systemd/network/wlan0.network
  2. Add the following to the file:
    [Match]
    Name=wlan0
    
    [Network]
    DHCP=yes
    
  3. # wpa_passphrase "<SSID>" "<PASSWORD>" > /etc/wpa_supplicant/wpa_supplicant-wlan0.conf - Replace with your respective WiFi network name and password
  4. # systemctl enable wpa_supplicant@wlan0 - enable WiFi when booting
  5. # systemctl start wpa_supplicant@wlan0 - connect to WiFi
  6. # hostnamectl set-hostname <name>
  7. # nano /etc/hosts:
    127.0.0.1	localhost
    ::1		localhost
    127.0.1.1	<hostname>.localdomain	<hostname>
    

Step 3 - Update System

# pacman -Syu

Step 4 - Configure Timezone

# timedatectl set-timezone America/Chicago

Step 5 - Update System Time

# timedatectl set-ntp true

Step 6 - Configure Locale

  1. # nano /etc/locale.gen and remove # from en_US.UTF-8
  2. # locale-gen
  3. # localectl set-locale LANG=en_US.UTF-8

Step 7 - User Setup

Keeping the alarm user, give it sudo priveleges.

  1. # pacman -S sudo
  2. # usermod -aG wheel,video,audio,storage alarm
  3. # EDITOR=nano visudo
  4. Remove # from %wheel ALL=(ALL) ALL
  5. Save and Exit
  6. Create the usual suspects:
    1. # pacman -S xdg-user-dirs
    2. $ xdg-user-dirs-update
  7. Setup AUR:
    1. # pacman -S --needed base-devel git
    2. $ mkdir /home/alarm/aur

Step 8 - Configure Swap

Using Swap as a guide

  1. # dd if=/dev/zero of=/swapfile bs=1M count=1024 status=progress - creating 1GiB of swap
  2. # chmod 0600 /swapfile
  3. # mkswap -U clear /swapfile
  4. # swapon /swapfile
  5. # nano /etc/fstab:
    /swapfile none swap defaults 0 0
    

Step 9 - Tune Swappiness

The why

  1. # nano /etc/sysctl.d/99-swappiness.conf
    vm.swappiness=1
    vm.vfs_cache_pressure=50
    

Step 10 - Install XFCE4

# pacman -S xfce4 xfce4-goodies xorg-server xorg-apps

Step 11 - Install Display Manager

  1. # pacman -S sddm
  2. $ cd /home/alarm/aur
  3. $ git clone https://aur.archlinux.org/archlinux-themes-sddm.git - theme for SDDM
  4. $ cd archlinux-themes-sddm/
  5. $ makepkg -si
  6. # systemctl enable sddm
  7. # systemctl start sddm

Step 12 - XFCE Configuration

Enable Audio

  1. # pacman -S pipewire pipewire-alsa pipewire-pulse
  2. # reboot

Install Browser

# pacman -S chromium

Install Archive Utility

# pacman -S file-roller

Step 13 - MacOS BigSur

Follow the steps in UPDATE : How to Customize Your Xfce Desktop Look Like macOS Big Sur | Version 2.0

@Alexandros-S
Copy link

Hello bro, really good instruction!
Respect for you!👍🏻
Sorry for my English))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment