Hardware
I am using the following hardware:- SiFive HiFive Unmatched
- Sandisk Corp PC SN520 NVMe SSD
- GPU: Sapphire R7 250X
Install image
Links to RISC-V images are provided at https://ubuntu.com/download/risc-v. As my hardware includes an NVMe drive I downloaded the Live Installerwget https://cdimage.ubuntu.com/releases/22.04.1/release/ubuntu-22.04.1-live-server-riscv64.img.gz
To copy the image to the SD card I used
zcat ubuntu-22.04.1-live-server-riscv64.img.gz | sudo dd of=/dev/sdb bs=1M conv=fsync
Please, be careful that the device your are copying to matches your SD-card. The change cannot be undone. The Unmatched board does not accept all SD cards. SanDisk Ultra 32 GB tends to work fine.
I connected my computer to the serial console via USB cable and used
picocom -b 115200 /dev/ttyUSB1
to attach to the UART, inserted the SD-card and powered up.
The Unmatched board is very slow accessing the SD-card. Wait until the installer menu appears.
If there is a previous installation is on your NVMe drive, U-Boot may boot into that drive instead of into the installer. In this case you need to interrupt the countdown in U-Boot by pressing the key to get to the U-Boot command line and use the following commands to boot into the installer:
load mmc 0:1 $fdt_addr_r /dtb/sifive/hifive-unmatched-a00.dtb
load mmc 0:1 $kernel_addr_r EFI/boot/bootriscv64.efi
bootefi $kernel_addr_r $fdt_addr_r
https://ubuntu.com/server/docs/installation has detail on the installation process.
After the installation completes reboot.
After first boot
The kernel log showed a line with “watchdog: BUG: soft lockup”. So I created file /etc/default/grub.d/90-watchdog_thread.cfg with the following content
GRUB_CMDLINE_LINUX_DEFAULT="ro efi=debug earlycon sysctl.kernel.watchdog_thresh=60"
and ran
sudo update-grub
On Ubuntu 22.04 package ubuntu-desktop is missing for riscv64 so we have to install a number of packages to get the Gnome desktop:
sudo apt-get install \
adwaita-icon-theme-full \
mutter \
gdm3 \
gnome \
gnome-shell-extension-appindicator \
gnome-shell-extension-desktop-icons-ng \
gnome-shell-extension-ubuntu-dock \
gnome-terminal \
network-manager-gnome \
ubuntu-gnome-wallpapers \
ubuntu-settings
As I want to use X11 and not Wayland I edited file /etc/gdm3/custom.conf to have a line
WaylandEnable=false
To get the desktop a reboot is needed.