IRC user 'anticomputer' wrote the following about their experience with
this problem:

I have also run into this bug. It manifested itself as an empty boot
parameters file causing guix system errors:

`guix system: error: unrecognized boot parameters at 
'/var/guix/profiles/system/parameters'"`

Roll backs and generation switches are no longer possible due to the current
system profile being in a broken state.

It is still possible to boot into an older generation.

Can confirm that manually activating an older generation per:

`sudo guile -s /var/guix/profiles/system-XX-link/activate`

With a rw remount of `/` to manually set the current system profile link to
that profile will get you back into a state that lets you delete the offending
generation using `guix system delete-generation`.

Curiously, my latest working generation is where the faulty system generation
was configured from, and I was still seeing intermittent generation of e.g.
empty `.drv` files on this generation:

guix system describe:
...
Generation 33   Mar 04 2025 23:02:24    (current)
  file name: /var/guix/profiles/system-33-link
  canonical file name: /gnu/store/qszg286n66l3gwjipvzg0nhswz7pv996-system
  label: GNU with Linux 6.12.13
  bootloader: grub-efi
  root device: /dev/mapper/system-root
  kernel: /gnu/store/gz7w72cj3icm58zj9vs6vvvs6khcqzil-linux-6.12.13/bzImage
  channels:
    nonguix:
      repository URL: https://gitlab.com/nonguix/nonguix
      branch: master
      commit: 8c41304decb916892fa07ca86893e4cf926ee884
    guix:
      repository URL: https://git.savannah.gnu.org/git/guix.git
      branch: master
      commit: 8bc831325a905dbd9015739b58e3a5138d2217da
  configuration file: 
/gnu/store/45gp6why4xgkxxxl1cs2v7nkf1fxrmag-configuration.scm
...
uname -a:
...
Linux thinkpad 6.12.13 #1 SMP PREEMPT_DYNAMIC 1 x86_64 GNU/Linux

This is a configuration that deploys cleanly on another system but from
this generation (33) I get (inconsistent/intermittent) empty drv files:

...
Reconfiguring system ...
guix system: error: error parsing derivation 
`/gnu/store/f2xi0b47yvgb4h8b92hlj7xmaqairidq-shepherd-nftables.go.drv': 
expected string `Derive(['
λ ~ › cat /gnu/store/f2xi0b47yvgb4h8b92hlj7xmaqairidq-shepherd-nftables.go.drv
λ ~ › ls -alrt 
/gnu/store/f2xi0b47yvgb4h8b92hlj7xmaqairidq-shepherd-nftables.go.drv
-r--r--r-- 1 root root 0 Dec 31  1969 
/gnu/store/f2xi0b47yvgb4h8b92hlj7xmaqairidq-shepherd-nftables.go.drv
λ ~ ›
```

`guix gc --verify=contents` also then shows many empty files with unexpected
hashes.

To get back into a working state I followed the following steps:

- Boot into a known-working older generation XX to purge broken generation YY

- Activate the known-working generation manually using:
`sudo -E guile -s /var/guix/profiles/system-XX-link/activate`

Note: this seems redundant, but just including as the actual steps I took

- remount `/` rw and manually update the current profile link
to enable `guix system` commands to work again:
`sudo mount -o remount,rw /dev/your-root-dev /`
`sudo rm /var/guix/profiles/system`
`sudo ln -s /var/guix/profiles/system-XX-link /var/guix/profiles/system`

- delete the offending generation YY:
`sudo -E guix system delete-generations YY`

- collect garbage:
`guix gc`

Note: I had ~35GB of gc, but plenty of diskspace, not sure if related but
curious that a `guix gc` resulted in being able to reconfigure without
empty files appearing once more

- update guix:
`guix pull`

- reconfigure to intended current generation system config:
`sudo -E guix system -L . reconfigure dolores/systems/CONFIG.scm`

- reboot

Leaving me in the following current/working state:

...
Generation 34   Mar 11 2025 18:09:09    (current)
  file name: /var/guix/profiles/system-34-link
  canonical file name: /gnu/store/17z7fpnbwbmi78v211xfm5r9wxhjgv6b-system
  label: GNU with Linux 6.13.5
  bootloader: grub-efi
  root device: /dev/mapper/system-root
  kernel: /gnu/store/skdgsqhqdwif0adykjg867i1n3xwfz9i-linux-6.13.5/bzImage
  channels:
...
    guix:
      repository URL: https://git.savannah.gnu.org/git/guix.git
      branch: master
      commit: d685a45edf0f89e5876ffc9d880068d8610e5f8a
  configuration file: 
/gnu/store/vnp7mhfhfff802zsp2vw74a7v0cv54hj-configuration.scm
...

Kind regards,
Bas



Reply via email to