Describe the bug
I have some child configuration specified in nesting.clone. In the recent nixos-unstable channel, switching to a child using something like /run/current-system/fine-tune/child-1/bin/switch-to-configuration test will crash the xserver. Switching works fine in the nixos-19.09 channel.
To Reproduce
Steps to reproduce the behavior:
nixos-unstable channel and build.switch-to-configurationAdditional context
I'm using gnome3 desktop with gdm.
Metadata
"x86_64-linux"Linux 5.3.5, NixOS, 20.03pre196201.07d4df59626 (Markhor)yesyesnix-env (Nix) 2.3"home-manager, nixpkgs-20.03pre196201.07d4df59626, rolling-20.03pre196523.9cf81e9174e"Hopefully fixed by #70357. That have worked for me at least, though no idea why, so would be good to get someone who can verify.
Unfortunately that doesn't work. I tried change to tty7, tty9, tty11, tty17, the issue is not gone. :(
The output of switch-to-configuration dry-activate might be interesting. It's possible that a relevant systemd service is being restarted or even stopped (depending on how much the configurations differ).
it doesn't give me much interesting output:
would restart systemd
would reload the following units: firewall.service
Yeah, I'm able to trigger it with a minimal rebuild (ie. no changes).
from a66adfcc5bf6d12af8ca6d74621dae4dc95e8027 to a66adfcc5bf6d12af8ca6d74621dae4dc95e8027:
File: master->master
building Nix...
building the system configuration...
trace: warning: The option `services.gnome3.gpaste.enable' defined in `/home/hed/src/nixconfiguration/co
nfiguration.nix' has been renamed to `programs.gpaste.enable'.
activating the configuration...
setting up /etc...
reloading user units for hed...
setting up tmpfiles
going from the the proposed fix (https://github.com/hedning/nixpkgs/commit/e84811df74f8f5afc49ca08871838cfb9c5772b8) to a66adfcc5bf6d12af8ca6d74621dae4dc95e8027 doesn't kill the session. Going from a66adfcc5bf6d12af8ca6d74621dae4dc95e8027 to https://github.com/hedning/nixpkgs/commit/e84811df74f8f5afc49ca08871838cfb9c5772b8 also works and results in this log:
File: master->fix
building Nix...
building the system configuration...
trace: warning: The option `services.gnome3.gpaste.enable' defined in `/home/hed/src/nixconfiguration/co
nfiguration.nix' has been renamed to `programs.gpaste.enable'.
stopping the following units: accounts-daemon.service
NOT restarting the following changed units: display-manager.service, [email protected]
activating the configuration...
setting up /etc...
reloading user units for hed...
setting up tmpfiles
reloading the following units: dbus.service
restarting the following units: polkit.service
starting the following units: accounts-daemon.service
the following new units were started: [email protected]
Now just removing [email protected] from gdm's service config seemed to work too, which does indicate that tty1 gets enabled or something.
Though it's pretty weird that @Ninlives can't reproduce :/
OK, hopefully #70357 should fix it. You might need gdm 3.34.1 which is available in the newest nixos-unstable.
OK, looks like there were two issue, if you're using boot splash (plymouth), #71065 should probably fix things.
Hi @hedning , many thanks! It solved my problem(I just disabled the plymouth :P ). I think this issue could be closed now.
That's good to hear :) I'll close when https://github.com/NixOS/nixpkgs/pull/71065 is merged.