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

Activating native systemd support breaks shell #486

Open
aikooo7 opened this issue Jun 7, 2024 · 2 comments
Open

Activating native systemd support breaks shell #486

aikooo7 opened this issue Jun 7, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@aikooo7
Copy link

aikooo7 commented Jun 7, 2024

Bug description

When enabling native systemd support and rebuild, switch and restart system you will be unable to log in to your system unless you use the recovery shell or use the shell binary directly instead of the wrapper.

Note: While trying to find what was the cause of the issue I rebuilt my home-manager and got Failed to connect to bus: No such file or directory so maybe #375 is related.

To Reproduce

Steps to reproduce the behavior:
Add wsl.nativeSystemd = true;
Run sudo nixos-rebuild switch
Run wsl --shutdown in cmd.
Run wsl -d NixOS in cmd. NixOS should be your nixos distro's name in wsl.

Logs

thread 'main' panicked at src/shell_wrapper.rs:105:10:
called `Result::unwrap()` on an `Err` value: When initializing journal logger

Caused by:
    No such file or directory (os error 2)
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

WSL version

2.0.9.0

WSL version: 2.0.9.0
Kernel version: 5.15.133.1-1
WSLg version: 1.0.59
MSRDC version: 1.2.4677
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.19045.4170
@aikooo7 aikooo7 added the bug Something isn't working label Jun 7, 2024
@nzbr
Copy link
Member

nzbr commented Jun 15, 2024

It looks like systemd hasn't started properly. That should obviously not crash the shell though, I'll fix that

@nzbr
Copy link
Member

nzbr commented Jun 15, 2024

As for the underlying problem: Can you send me the output of dmesg executed in another distro right after this happens. To reduce the size of the output, it probably makes sense to shut down WSL with wsl --shutdown before that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants