Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nixos-upgrade.service can't exec su: No such file or directory #47385

Closed
8573 opened this issue Sep 26, 2018 · 3 comments
Closed

nixos-upgrade.service can't exec su: No such file or directory #47385

8573 opened this issue Sep 26, 2018 · 3 comments

Comments

@8573
Copy link
Contributor

8573 commented Sep 26, 2018

Issue description

In the systemd journal for nixos-upgrade.service, I notice error messages about being unable to find the program su:

systemd[1]: Starting NixOS Upgrade...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: unpacking 'https://nixos.org/channels/nixos-unstable/nixexprs.tar.xz'...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: warning: Nix search path entry '$HOME/.nix-defexpr/channels' does not exist, ignoring
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: building Nix...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: warning: Nix search path entry '$HOME/.nix-defexpr/channels' does not exist, ignoring
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: building the system configuration...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: warning: Nix search path entry '$HOME/.nix-defexpr/channels' does not exist, ignoring
nixos[21622]: switching to system configuration /nix/store/dvc3aq1rlyddjbc50si8sjfcrc9f9ga9-nixos-system-[hostname]-19.03pre153158.7df10f388da
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: activating the configuration...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: setting up /etc...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: reloading user units for root...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: Can't exec "su": No such file or directory at /nix/store/dvc3aq1rlyddjbc50si8sjfcrc9f9ga9-nixos-system-[hostname]-19.03pre153158.7df10f388da/bin/switch-to-configuration line 422, <$listActiveUsers> line 1.
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: reloading user units for c74d...
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: Can't exec "su": No such file or directory at /nix/store/dvc3aq1rlyddjbc50si8sjfcrc9f9ga9-nixos-system-[hostname]-19.03pre153158.7df10f388da/bin/switch-to-configuration line 422, <$listActiveUsers> line 2.
jz91zw8nmyzvdbb0w6mqvfhsmx8195zk-unit-script-nixos-upgrade-start[20020]: setting up tmpfiles
nixos[21622]: finished switching to system configuration /nix/store/dvc3aq1rlyddjbc50si8sjfcrc9f9ga9-nixos-system-[hostname]-19.03pre153158.7df10f388da
systemd[1]: Started NixOS Upgrade.

I note that most other executables invoked in this switch-to-configuration script seem to be invoked by absolute store paths, whereas it invokes su as simply su.

Steps to reproduce

Use nixos-upgrade.service (system.autoUpgrade.enable = true in configuration.nix) and check its journal entries (journalctl -eu nixos-upgrade.service as the superuser).

Technical details

  • system: "x86_64-linux"
  • host os: Linux 4.14.59, NixOS, 19.03pre153158.7df10f388da (Koi)
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.1.2
  • channels(root): "nixos-19.03pre152634.218ce4de508"
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos
@stale
Copy link

stale bot commented Jun 3, 2020

Thank you for your contributions.

This has been automatically marked as stale because it has had no activity for 180 days.

If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.

Here are suggestions that might help resolve this more quickly:

  1. Search for maintainers and people that previously touched the related code and @ mention them in a comment.
  2. Ask on the NixOS Discourse.
  3. Ask on the #nixos channel on irc.freenode.net.

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jun 3, 2020
@8573
Copy link
Contributor Author

8573 commented Jun 4, 2020

I no longer seem to have this issue.

@alunduil: I see that you "thumbs-upped" my issue report. Do you still have this issue?

@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jun 4, 2020
@alunduil
Copy link
Contributor

alunduil commented Jun 4, 2020

Nope, I haven't seen this in a while either. I think it can safely be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants