!apXxbtexmNGJaAryzM:nixos.org

NixOS on WSL

332 Members
https://github.com/nix-community/NixOS-WSL55 Servers

Load older messages


SenderMessageTime
18 Aug 2024
@whovian9369:matrix.orgWhovian9369
In reply to @k900:0upti.me
Check journalctl on the NixOS side, are there any errors?

Aug 18 16:50:18 nixos-wsl kernel: FS-Cache: Duplicate cookie detected then its information

Aug 18 16:50:18 nixos-wsl unknown: /usr/lib/wsl/lib/libcuda.so.1 is not a symbolic link
Aug 18 16:50:18 nixos-wsl unknown: WSL (2) ERROR: WaitForBootProcess:3352: /sbin/init failed to start within 10000ms

Aug 18 16:50:18 nixos-wsl systemd-journald[79]: Received client request to flush runtime journal.
Aug 18 16:50:18 nixos-wsl systemd-journald[79]: File /var/log/journal/3f0405037402365e4122e654618a2843/system.journal corrupted or uncleanly shut down, renaming and replacing.
...
Aug 18 16:50:18 nixos-wsl systemd-sysctl[263]: Couldn't write '16' to 'kernel/sysrq', ignoring: No such file or directory

These are what stood out to me, and mostly repeat a few times

20:56:28
@k900:0upti.meK900Yeah that's fine20:56:41
@whovian9369:matrix.orgWhovian9369
In reply to @k900:0upti.me
Check journalctl on the NixOS side, are there any errors?
*

Aug 18 16:50:18 nixos-wsl kernel: FS-Cache: Duplicate cookie detected then its information

Aug 18 16:50:18 nixos-wsl unknown: /usr/lib/wsl/lib/libcuda.so.1 is not a symbolic link
Aug 18 16:50:18 nixos-wsl unknown: WSL (2) ERROR: WaitForBootProcess:3352: /sbin/init failed to start within 10000ms
...
Aug 18 16:50:18 nixos-wsl systemd-journald[79]: Received client request to flush runtime journal.
Aug 18 16:50:18 nixos-wsl systemd-journald[79]: File /var/log/journal/3f0405037402365e4122e654618a2843/system.journal corrupted or uncleanly shut down, renaming and replacing.
...
Aug 18 16:50:18 nixos-wsl systemd-sysctl[263]: Couldn't write '16' to 'kernel/sysrq', ignoring: No such file or directory

These are what stood out to me, and mostly repeat a few times

20:56:41
@k900:0upti.meK900As in none of that is fatal20:56:51
@k900:0upti.meK900Though init not starting is weird20:56:55
@k900:0upti.meK900Is this NixOS 24.05 or unstable?20:57:02
@whovian9369:matrix.orgWhovian9369Should be Unstable20:57:10
@k900:0upti.meK900Oh20:57:19
@k900:0upti.meK900And did you update in between restarting the VMs?20:57:28
@whovian9369:matrix.orgWhovian9369You mean while we were experimenting? No, not to my knowledge20:57:50
@k900:0upti.meK900 Do you have

[wsl2]
kernelCommandLine = cgroup_no_v1=all

in your .wslconfig?
20:58:02
@whovian9369:matrix.orgWhovian9369 I don't have anything in my C:\Users\Whovian\.wslconfig (Everything is commented out.) 20:59:05
@k900:0upti.meK900Yeah, you need to set that20:59:33
@k900:0upti.meK900For systemd 256 to start correctly20:59:36
@k900:0upti.meK900Otherwise things get Funny20:59:40
@whovian9369:matrix.orgWhovian9369Ah damn it, thanks 😅 I'll try that in a moment20:59:49
@whovian9369:matrix.orgWhovian9369 wsl.exe --shutdown, add that, and try again? 21:00:00
@k900:0upti.meK900Thank Microsoft for not shipping a cgv2-by-default kernel like three months after Ubuntu shipped it as a requirement21:00:16
@k900:0upti.meK900(and like multiple years after everyone else decided it was a good idea)21:00:28
@whovian9369:matrix.orgWhovian9369
╭─whovian@nixos-wsl ~
╰─$  sudo whoami
root

Okay cool, this is a good sign

21:02:34
@whovian9369:matrix.orgWhovian9369And the errors on every tab are magically gone, which means that all of the services are starting as I'd expect again. Thank you so so much for the help and time, K900. 21:03:12
@k900:0upti.meK900I just realized we can probably get better errors if we actually dup systemd logs to kmsg21:04:57
@k900:0upti.meK900 CC @nzbr:nzbr.de 21:05:02
@k900:0upti.meK900Oh never mind 21:10:06
@k900:0upti.meK900systemd is trying to be smart 21:10:10
@k900:0upti.meK900And write to /dev/console21:10:18
@k900:0upti.meK900And guess what WSL does to that 21:10:23
@whovian9369:matrix.orgWhovian9369 Then as a followup question, do you know if there's a way to automatically check for the .wslconfig entry (without reading the file directly) to warn a user to add it? 21:11:49
@k900:0upti.meK900No 21:11:58
@k900:0upti.meK900We basically have no user facing communication until after systemd21:12:13

Show newer messages


Back to Room ListRoom Version: 9