-->
Home » , » AlmaLinux Guide: Raspberry Pi.

AlmaLinux Guide: Raspberry Pi.

Spring 2025 Raspberry Pi Updates | AlmaLinux OS


The Raspberry Pi<?XML:NAMESPACE PREFIX = "[default] http://www.w3.org/2000/svg" NS = "http://www.w3.org/2000/svg" /> (opens new window)
is a compact computer primarily used for learning computing and programming. It's also very popular for many DIY projects, including home media centers and home automation. Whether you need a full desktop experience or prefer running it headless depends on your project. While the Raspberry Pi can run different operating systems, it was specifically designed for Linux.

TIP

The official AlmaLinux Raspberry Pi images come with the default username and password are both set to almalinux. By default, only console login is allowed. See the cloud-init sectionfor instructions on how to add you SSH public key for SSH access or perform additional customizations.

Tested models

The AlmaLinux OS releases have been tested on the following models.

  • Raspberry Pi 5 (supported since June 2024 images)
  • Raspberry Pi 500, 500+
  • Raspberry Pi 4 Model B
  • Raspberry Pi 400
  • Raspberry Pi 3 Model B+
  • Raspberry Pi 3 Model A+

32-bit Raspberry Pis (ARMv6/ARMv7) and original Raspberry Pi 3 (without "+" models) are not supported. Other ARMv8 Raspberry Pis such as Compute Modules are not tested but will probably work. Let us know if it doesn't work. See also How to contributesection.

Since AlmaLinux 9.5, images with GPT (GUID partition table) have been available in addition to traditional MBR images. GPT supports larger disks over 2TB and allows up to 128 partitions, compared to MBR's limit of 4. However, booting from a GPT disk is not supported on Raspberry Pi 3. Select the appropriate image for your Raspberry Pi model.

Installation steps

Download image

AlmaLinux OS provides standard Raspberry Pi images and images with a GNOME desktop environment. Raspberry Pi images can be found on repo.almalinux.org/rpi/ and mirrors (opens new window). It is recommended to get images from your nearest mirror. Dig into /9/raspberrypi/images/ or /8/raspberrypi/images/ directory of your nearest mirror.

Also, AlmaLinux OS Kitten images are available. Please also visit the AlmaLinux OS Kitten page.

DETAILS

At the time of our testing, these commands were used to fetch the images:

  • AlmaLinux OS 8
    $ curl -LO https://repo.almalinux.org/almalinux/8/raspberrypi/images/AlmaLinux-8-RaspberryPi-latest.aarch64.raw.xz
    
  • AlmaLinux OS 9
    $ curl -LO https://repo.almalinux.org/almalinux/9/raspberrypi/images/AlmaLinux-9-RaspberryPi-latest.aarch64.raw.xz
    
Verify AlmaLinux 9 images

The instructions below are typical examples based on AlmaLinux 9. If you use a different version, please adjust accordingly.

In order to verify a downloaded image:

  • Import the AlmaLinux OS PGP public key first:

    $ curl -O -s https://repo.almalinux.org/almalinux/RPM-GPG-KEY-AlmaLinux-9
    

    TIP

    If you are using an AlmaLinux OS-powered system, you already have the key stored in the /etc/pki/rpm-gpg/RPM-GPG-KEY-AlmaLinux-9 file. So you can skip the download the key and print the key fingerprint steps. Run the following command instead to import the key:

    gpg --import /etc/pki/rpm-gpg/RPM-GPG-KEY-AlmaLinux-9
    
  • Print the key fingerprint:

    $ gpg --with-subkey-fingerprints RPM-GPG-KEY-AlmaLinux-9
    pub   rsa4096 2022-01-18 [SC]
          BF18AC2876178908D6E71267D36CB86CB86B3716
    uid           AlmaLinux OS 9 <packager@almalinux.org>
    sub   rsa4096 2022-01-18 [E]
    

    WARNING

    The fingerprint is BF18AC2876178908D6E71267D36CB86CB86B3716. If you see a different fingerprint, it means you downloaded a compromised file. Please, let us know, remove the file and retry the download.

  • Next you need to import the key:

    $ gpg --import RPM-GPG-KEY-AlmaLinux-9
    gpg: key D36CB86CB86B3716: public key "AlmaLinux <packager@almalinux.org>" imported
    gpg: Total number processed: 1
    gpg:               imported: 1
    

To verify the image:

  • Download the checksum file and its signature first:

    $ curl -O -s https://repo.almalinux.org/rpi/9/images/CHECKSUM
    $ curl -O -s https://repo.almalinux.org/rpi/9/images/CHECKSUM.asc
    
  • Verify the checksum file signature:

    $ gpg --verify CHECKSUM.asc CHECKSUM
    gpg: Signature made Fri 18 Nov 2022 12:06:49 AM CET
    gpg:                using RSA key D36CB86CB86B3716
    gpg: Good signature from "AlmaLinux OS 9 <packager@almalinux.org>" [unknown]
    gpg: WARNING: This key is not certified with a trusted signature!
    gpg:          There is no indication that the signature belongs to the owner.
    Primary key fingerprint: BF18 AC28 7617 8908 D6E7  1267 D36C B86C B86B 3716
    

    TIP

    Make sure that you see the Good signature from "AlmaLinux <packager@almalinux.org>" message in the output.

  • Verify the checksum of the downloaded image:

    $ sha256sum -c CHECKSUM 2>&1 | grep OK
    AlmaLinux-9-RaspberryPi-latest.aarch64.raw.xz: OK
    

    WARNING

    If the output is different, you should download the image again.

Burn Raspberry Pi image

The next step is to burn the image to an SD card using

When it's done insert the SD Card into your Raspberry Pi and boot.

TIP

Do not use OS customization feature built in RPi Imager. AlmaLinux doesn't support the feature and it conflicts with our initialization process such as default user creation. If you want to apply custom configuration, edit user-data file as described in Configuration using cloud-initsection.

Getting started

When you boot your Raspberry Pi use you can login with the almalinux user and almalinux password. root account is locked by default.

Connecting to Wi-Fi
  • Check whether wifi is enabled:

    $ nmcli radio wifi
    

    You should see the command responding with enabled.

  • Next, check the list of local Wi-Fi networks next to you to find one you want to connect:

    $ nmcli dev wifi list
    
  • Connect to the Wi-Fi network:

    $ nmcli --ask dev wifi connect <network-ssid>
    

    TIP

    The --ask option will ask you to enter the password.

  • Your wlan0 interface should now be active and pull an IP via DHCP. You can verify this via nmcli con show to check the physical layer connection and then ip a to see if you've gotten an IP.

Getting GNOME working

TIP

If you got an AlmaLinux Raspberry Pi GNOME image, please, ignore this section, as you already have this desktop environment.

The steps below describe how to get a GNOME desktop environment:

(if you installed a standard AlmaLinux Raspberry Pi image)

  • You can install just a barebones GNOME desktop environment once you installed the Raspberry Pi system.

  • To do so run the following command:

    dnf groupinstall gnome-desktop
    

    TIP

    Please, note that you might need to install additional packages if needed.

  • If you want to install a more comprehensive GNOME environment:

    dnf groupinstall "Server with GUI"
    
  • When the GNOME is installed run the following command to change the boot target to graphical:

    systemctl set-default graphical
    
  • Reboot the system using the sudo reboot command and enjoy your Raspberry Pi with GNOME.

The Raspberry Pi demo video can be found in the GitHub repository (opens new window).

Configuration using cloud-init

AlmaLinux Raspberry Pi image now supports cloud-init (opens new window)to perform early initialization. This section describes some typical examples to setup AlmaLinux Raspberry Pi image. See the cloud-init official documentation (opens new window)for further information.

To configure early initialization, modify user-data file in FAT boot volume named CIDATA (the same location where config.txt exists). Please note that cloud-init usually only works at very first boot so modification on user-data file must be done before inserting SD card and power on your Raspberry Pi.

Add SSH public key to default user

The default user is almalinux. Add your SSH public key to enable to login to your Raspberry Pi.

-     #ssh_authorized_keys:
+     ssh_authorized_keys:
       # Put here your ssh public keys
       #- ssh-ed25519 AAAAC3Nz...
+      - ssh-rsa AAAAB3NzaC1yc2EAAAADAQ...
Change default user's password

Specify hashed password like this. Use mkpasswd -m sha-512 command to generate a hashed password.

   - name: almalinux
     groups: [ adm, systemd-journal ]
     sudo: [ "ALL=(ALL) NOPASSWD:ALL" ]
     lock_passwd: false
+    passwd: "$6$hjdBm161zuYLfb9.$jkJkq5pQDkFvWPeJhnon9xHIX93SgLTNLsyQcddWJLcQGcM8qHkxDztbwt1DzTP6dmlQ3J.AA6h4JeGaVg.pS1"
     #ssh_authorized_keys:
       # Put here your ssh public keys
       #- ssh-ed25519 AAAAC3Nz...
Enable SSH password authentication

Change ssh_pwauth to true to allow SSH password authentication. This does not enable password login for root user.

-ssh_pwauth: false
+ssh_pwauth: true
Network configuration: wired network with a static IPv4 address

Put network-config file in the same location as user-data. The following example assigns a static IPv4 address to eth0 interface.

version: 2

ethernets:
  eth0:
    dhcp4: false
    optional: true
    addresses:
      - 192.168.1.99/24
    gateway4: 192.168.1.1
    nameservers:
      addresses:
        - 8.8.8.8
        - 8.8.4.4
Network configuration: Wi-Fi with a dynamic IP address

Generally, the following network-config configuration enables to connect to Wi-Fi however this is not supported in AlmaLinux.

version: 2

wifis:
  wlan0:
    dhcp4: true
    optional: true
    access-points:
      "Wi-Fi_SSID":
        password: "Wi-Fi_PreSharedKey"

Add the following two lines at the bottom of user-data instead (example is diff style).

+runcmd:
+  - nmcli dev wifi connect "Wi-Fi_SSID" password "Wi-Fi_PreSharedKey"

Configure Boot Order

In March 2025, the rpi-eeprom package was added, enabling the Raspberry Pi bootloader configuration, such as boot order, to be changed using only AlmaLinux. Here are the instructions on how to change the Raspberry Pi boot order.

The rpi-eeprom tool is an optional package that is not pre-installed in our Raspberry Pi images. Install it if you wish to configure the Raspberry Pi boot order.

dnf install -y rpi-eeprom

Run rpi-eeprom-config command with the -e (edit) option. The editor will open, letting you edit the bootconfiguration. Refer to the official documentation (opens new window)for the meaning of BOOT_ORDER and detailed examples.

rpi-eeprom-config -e

The following example attempts to boot from the SD card first, followed by a USB mass storage device, and then NVMe. To boot from a USB mass storage device first, move 4 to the rightmost position, 0xf614.

[all]
BOOT_UART=1
POWER_OFF_ON_HALT=0
BOOT_ORDER=0xf641

After saving the changes and exiting the editor, the following message will be displayed. Raspberry Pi will boot up with the new order after reboot.

(ommitted)

EEPROM updates pending. Please reboot to apply the update.
To cancel a pending update run "sudo rpi-eeprom-update -r".

Upgrading Major Version

In-place upgrades between major versions using Elevate are not supported for Raspberry Pi images. The recommended approach is to perform a fresh setup from a clean image of the new major version.

If you want to perform an in-place upgrade from AlmaLinux 9 to 10, try running the following command:

WARNING

Please note that the result of the following command may be unpredictable. We recommend creating a backup before proceeding.

rpm --import https://repo.almalinux.org/almalinux/RPM-GPG-KEY-AlmaLinux-10
dnf update --releasever=10 --allowerasing

Frequent Issues

If you installed a GUI, and your screen has a black border around it, follow the steps below to fix this:

  • Run the command below in the terminal:
    sudo nano /boot/config.txt
    
  • Add a new line to the file:
    disable_overscan=1
    
  • Type Ctrl+x on your keyboard to exit nano, and a little message at the bottom or the terminal will say, “save modified buffer?’. Type y for ‘yes’.
  • Reboot your system:
    sudo reboot
    

source

0 commenti:

Post a Comment

Random Posts

Recent Posts

Recent Posts Widget

Popular Posts

Labels

Archive

page counter follow us in feedly
 
Copyright © 2014 Linuxlandit & The Conqueror Penguin
-->