SOLVED Building the system configuration... error:

hi, i have an error when i run ‘sudo nixos-rebuild switch --upgrade’, and would like to know what causes the error.

before the first error, here i tried to install four packages firejail, abiword, transmission, and fish. and i have tried a little with the firewall, added two lines, after which came the errors that are in the log, after which the four programs are removed from the config file of the two extra lines in the firewall are ignored, the firejail is installed with ‘programs.firejail.enable = true;’ and it seems to work, after removing the new additions there are no problems, but I would like to know what I have done wrong, it would be nice to be able to install new packages on the system.

#networking.firewall.enable = true;

#networking.firewall.allowPing = false;

and the error log from the terminal

unpacking 1 channels…
building the system configuration…
error:
… while calling the ‘head’ builtin
at /nix/store/whilq7inyndwdakb4syfvjprdmj2bb7g-nixos-25.11/nixos/lib/attrsets.nix:1696:13:
1695| if length values == 1 || pred here (elemAt values 1) (head values) then
1696| head values
| ^
1697| else

   … while evaluating the attribute 'value'
     at /nix/store/whilq7inyndwdakb4syfvjprdmj2bb7g-nixos-25.11/nixos/lib/modules.nix:1118:7:
     1117|     // {
     1118|       value = addErrorContext "while evaluating the option `${showOption loc}':" value;
         |       ^
     1119|       inherit (res.defsFinal') highestPrio;

   … while evaluating the option `system.build.toplevel':

   … while evaluating definitions from `/nix/store/whilq7inyndwdakb4syfvjprdmj2bb7g-nixos-25.11/nixos/nixos/modules/system/activation/top-level.nix':

   … while evaluating the option `system.systemBuilderArgs':

   … while evaluating definitions from `/nix/store/whilq7inyndwdakb4syfvjprdmj2bb7g-nixos-25.11/nixos/nixos/modules/system/activation/activatable-system.nix':

   … while evaluating the option `system.activationScripts.etc.text':

   … while evaluating definitions from `/nix/store/whilq7inyndwdakb4syfvjprdmj2bb7g-nixos-25.11/nixos/nixos/modules/system/etc/etc-activation.nix':

   … while evaluating definitions from `/nix/store/whilq7inyndwdakb4syfvjprdmj2bb7g-nixos-25.11/nixos/nixos/modules/system/etc/etc.nix':

   … while evaluating the option `environment.etc.dbus-1.source':

   … while evaluating the option `environment.systemPackages':

   … while evaluating definitions from `/etc/nixos/configuration.nix':

   (stack trace truncated; use '--show-trace' to show the full, detailed trace)

   error: transmission_3 has been removed in favour of transmission_4. Note that upgrade caused data loss for some users so backup is recommended (see NixOS 24.11 release notes for details)

Command ‘nix-build ‘<nixpkgs/nixos>’ --attr config.system.build.toplevel --no-out-link’ returned non-zero exit status 1.

The error message tells you everything it can. Use transmission_4 if you didn’t have it installed before.

yes transmissio_4 is installed and that’s fish too
an additional question is, I haven’t installed transmissio_3 and my
NixOS system is not 24.11 but a 25.11.
it’s a new installation of NixOS

Show the code you wrote, we aren’t mind-readers.

this is my code from nix config file

environment.systemPackages = with pkgs; [
fish
transmission
abiword
firejail
];

it now appears that fish is installed, but not transmission_4 or any other version of transmission

lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 931,5G 0 disk
├─sda1 8:1 0 1G 0 part /boot
└─sda2 8:2 0 930,5G 0 part /nix/store
/
sr0 11:0 1 1024M 0 rom

I have also run lsblk and there is a question about the result, it seems that there is an extra root ‘/’ at the bottom, should it be there or has it survived from a previous installation

So you didn’t use transmission_4, you used transmission. Please use transmission_4.

I installed transmission_4 and abiword but only abiword is installed and reboot pc

$ sudo transmission_4
[sudo] password for hanshb:
sudo: transmission_4: command not found

man transmission_4
No manual entry for transmission_4

That’s the package name, you’ll want to check the program names via search:

Programs provided

transmission-cli transmission-create transmission-daemon transmission-edit transmission-remote transmission-show

yes now I have transmission-cli, this is how it seems to work,

Thanks for your input, I would never have thought of that name myself. :innocent:

Do you have any idea about this ‘/’ root?

As I see it, there are two root /,/ on /dev/sda2 and an unallocated part at the beginning of the disk, does anyone have an idea what happened to my installation?

I do not understand what you mean by “there are 2 root on /dev/sda2”.

I only see a single one.

The device /dev/sda2 is currently mounted 2 times, once at / and once at /nix/store, the latter very likely being a read-only bind mount to itself.

I think there is another explanation for the problem, there is an unallocated part on the hdd 2.2 mb before efi boot, which I find with gparted via a live boot
in the boot menu I can see that there are two boot options ‘Linux boot manager’ but only one works, can I remove the old one and how?

I don’t understand what you mean, when I look at the output of ‘lsblk’ it seems to be an extra ‘/’ below ‘/dev/sda2’

why is dev/‘sda2’ mounting twice

There is no “extra” /, there is only one. And it is mounted twice because your config does contain instructions to mount the blockdevice itself as /, while also is configured to remount /nix/store read only. The latter is the default on NixOS. And at least on a quick search, I am unable to find the option that controlls this behaviour. I am under the impression that this was optional in the past, though it seems as if it is mandatory now.

okay and thank you

and the boot problem is solved by ‘efibootmgr -b xxxx -B’

:grinning_face: