Pi 5

From Wildsong
Jump to navigationJump to search

I have two Pi 5s now, "pi5" and "asl". I started out setting up All Star Link on ASL, hence its name. It's not there right now. It's just Bookworm.

I put a reservation for both 5s for addresses on Wenda DHCP and into pihole on Bellman.

Getting an operating system onto the NVME is a trick. You install a full GUI onto an SD card and then run the Raspberry Pi Imager and target the NVME. This is the easiest way, really. It's a squeeze to get an SD card into the Pi when it has the NVME adapter installed because the ribbon cable gets in the way. You can set the Pi to boot first from the NVME or the SD, so it's possible to just leave the SD card in there "for next time" or as a rescue disk.

WiFi did not get set up during installation. I did it with command line, like this

sudo nmcli d wifi connect "wildsong" password "YOUR SECRET HERE" ifname wlan0

Disable ipv6 by adding this to /etc/sysctl.conf

# Disabling the IPv6
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1
net.ipv6.conf.wlan0.disable_ipv6 = 1

NVME

I added the Pimroni NVME interface and wanted to start again.

I did not want to have to mess around with taking the NVME card out to rewrite it so I downloaded the OS image, then used the SD card image to write to it, like this

wget https://downloads.raspberrypi.com/raspios_lite_arm64/images/raspios_lite_arm64-2024-07-04/2024-07-04-raspios-bookworm-arm64-lite.img.xz
sudo rpi-imager --cli *xz /dev/nvme0n1

I set the boot order with raspi-config to be NVME first, then SD card.

I had to edit the config.txt to add these lines to get UART access.

enable_uart=1 
dtoverlay=disable-bt
dtparam=uart0=on

This ends up not setting up an account though, it's back to logging in as "pi". This was a minor problem since I was never able to set the password and so the system was useless. I disconnected the NMVE, booted from SD, set it to boot from SD, reconnected NVME, booted from SD, used commands to mount the NVME, and manually edited passwd, shadow, and group. Then set it to boot from NVME again and finally I am back in business.

Testing speed

Now that I have the NVME installed I need to know about speed.

https://linuxconfig.org/how-to-test-sd-card-speed-on-raspberry-pi

Write a 1GB file

dd if=/dev/zero of=./TestingFile bs=100M count=10 oflag=direct

Read the file

dd if=./TestingFile of=/dev/zero bs=100M count=10 oflag=dsync

Results

32GB SD card

write: 1048576000 bytes (1.0 GB, 1000 MiB) copied, 35.41 s, 29.6 MB/s
read: 1048576000 bytes (1.0 GB, 1000 MiB) copied, 11.7282 s, 89.4 MB/s

NVME

read: 1048576000 bytes (1.0 GB, 1000 MiB) copied, 3.13241 s, 335 MB/s
write: 1048576000 bytes (1.0 GB, 1000 MiB) copied, 2.36035 s, 444 MB/s

NVME with pcie gen 3 enabled

read: 1048576000 bytes (1.0 GB, 1000 MiB) copied, 2.81857 s, 372 MB/s
write:1048576000 bytes (1.0 GB, 1000 MiB) copied, 1.46088 s, 718 MB/s

Overclocking

https://www.tomshardware.com/how-to/overclock-raspberry-pi-5

I set it to 3000 for the CPU and 1000 for the GPU and set turbo mode on and now the system won't boot. :-) Okay. Now how do I get it running again. I guess I should be doing the SD card to test overclocking.

Boot order

To recover more easily I need it to boot from the SD card first and the NVME second, so that I can pop in the SD card when I make NVME unbootable.

For now I have no choice but to unplug the NVME cable again.