<stiell>
I'm having trouble keeping the system configuration up to date across reboots on my RPi 4. I update /etc/nixos/configuration.nix, then do `sudo nixos-rebuild switch`. Configuration updated. But whenever I reboot (`sudo reboot`), I have to do `sudo nixos-rebuild switch` again to get the latest config. Shouldn't the latest config persist across reboots when using `nixos-rebuild switch`?
<clever>
stiell: what does /run/current-system point to before and after the reboot?
<samueldr>
clever: FIRMWARE partition with raspberry pi bootloader issue
<samueldr>
stiell: did you mount the FIRMWARE partition at /boot?
<samueldr>
that information is lacking from the default instructions since it is specific to how that (temporary) image is made
<samueldr>
I didn't think we'd be stuck with it for that long though :/
<stiell>
I see now, it's updating the files in /boot, but that is on /dev/mmcblk0p2, while the bootloader uses the files on /dev/mmcblk0p1. What's the fix/workaround here?
<clever>
stiell: remove /boot from your configuration.nix
<samueldr>
clever: huh?
<clever>
samueldr: isnt that right? since /boot is part of the / fs?
<samueldr>
clever: raspberry pi 4
<samueldr>
clever: the 4 doesn't use u-boot for now
<clever>
3 partitions at play then?
<clever>
wrong one on /boot?
<samueldr>
nah
<samueldr>
/boot is simply not at the root of mmcblk0p2
<samueldr>
stiell: you may want to empty /boot/ (or move it and mkdir a fresh one), and setup the partition in configuration.nix
<samueldr>
you'll also need https://nixos.org/nixos/options.html#boot.loader.raspberry the rasperryPi one enabled, and make sure you don't use extlinux of uboot.enable
<samueldr>
(future readers of the logs: verify this is still the case in the year 20XX where you read from!)
<samueldr>
(it's likely to change!)
<stiell>
samueldr: So, mount /dev/mmcblk0p1 on /boot, right?
<samueldr>
clever: the raspberry pi 4 image being built out of nixpkgs right now is basically built like the other one, but with u-boot removed, and the kernel being booted by the raspberry pi bootloader, if that helps
<samueldr>
stiell: yes
<stiell>
Will try that, thanks.
<clever>
ah, so its the reverse of my directions, what i was trying to undo
<samueldr>
clever: yeah :)
<samueldr>
clever: just so you know, that's the current state for raspberry pi 4 _only_
<samueldr>
though I *think* we could review the image to use u-boot, but no mainline kernel still
h0m1 has quit [Ping timeout: 240 seconds]
h0m1 has joined #nixos-aarch64
<stiell>
That fixed the problem. Now I can even get X to start supposedly using the GPU. org.gnome.Shell.desktop is segfaulting, though (not that I intend on using Gnome).
<clever>
DigitalKiwi: probably, though ive not tried it
<clever>
DigitalKiwi: an ftdi can also be jtag
<DigitalKiwi>
lots of search results about doing it
zupo has quit [Ping timeout: 255 seconds]
<clever>
DigitalKiwi: once you have a jtag adapter working in openocd (must build from master, not the release), then i can help with the target side of things
<DigitalKiwi>
hopefully the console works because this looks not fun heh
<clever>
DigitalKiwi: having jtag allowed me to single-step linux as it booted
<clever>
all of the normal stuff gdb can do, but on a bare cpu
zupo has joined #nixos-aarch64
<DigitalKiwi>
i write haskell i don't know how to use a debugger