| 9 Feb 2023 |
K900 | I just randomly stumbled upon this in a completely unrelated codebase | 21:59:24 |
K900 | Now I need to fix the shim | 21:59:39 |
K900 | https://github.com/nix-community/NixOS-WSL/pull/219/files | 22:41:05 |
K900 | Started fixing the shim | 22:41:08 |
K900 | Don't merge until I get tests running in CI though | 22:41:23 |
| 10 Feb 2023 |
| hexagony joined the room. | 02:05:29 |
K900 | https://github.com/nix-community/NixOS-WSL/pull/219 should be good to review now | 07:26:05 |
| 11 Feb 2023 |
K900 | I merged 219 because I found a setup where the old one actually breaks | 14:40:17 |
| 12 Feb 2023 |
henrik-ch | I am very new to nixos, nixos wsl, and also to this channel. I hope that it's okay to post here to ask for your advice. I added this snippet to my /etc/nixos/configuration.nix
environment.systemPackages = with pkgs; [
emacs
];
(I put it under the experimental features flakes bit)
When I ran nixos-rebuild switch afterwards I get this error message:
building '/nix/store/51a2g3iffr4cv3wzh1k9g69231ldv8gj-etc.drv'...
building '/nix/store/p4c000pm7qzlmn2a72gnxfrkdvccdlbz-nixos-system-nixos-22.05.20220812.5c211b4.drv'...
error: creating symlink from '/nix/var/nix/profiles/system-2-link.tmp-6530-1022011929' to '/nix/store/wpirs5md50yzp3qws0chzpqr5s3jzfaf-nixos-system-nixos-22.05.20220812.5c211b4': Permission denied
then I try sudo nixos-rebuild switch and still get an error.
reloading user units for nixos...
setting up tmpfiles
fchmod() of /tmp/.X11-unix failed: Read-only file system
reloading the following units: dbus.service
Any pointers to what might be best next steps or things to check would be greatly appreciated!
| 19:59:08 |
K900 | You should probably update your nixos-wsl version | 20:00:20 |
K900 | And then run nixos-rebuild with sudo | 20:00:38 |
henrik-ch | Thank you for chatting back K900 🙏. Are you thinking of system.stateVersion = "22.05";, or more like downloading a new tar.gz? | 20:02:15 |
K900 | Never touch stateVersion | 20:02:22 |
K900 | Did you use the official tarball from the NixOS-WSL github page? | 20:02:51 |
henrik-ch | I think so, but just to make sure, I will start afresh, it's a quick thing to do. | 20:03:13 |
K900 | Which tarball version did you use? The 22.05 one from releases? | 20:04:20 |
K900 | Try the latest build from CI: https://github.com/nix-community/NixOS-WSL/actions/runs/4151829716 | 20:04:46 |
henrik-ch | Thank you for the advice - will do! What you mean for afterwards is basically installing as is, and then run the sudo nixos-rebuild without making any changes, to configuration.nix, right? | 20:05:20 |
henrik-ch | * Thank you for the advice - will do! What you mean for afterwards is basically installing as is, and then run the sudo nixos-rebuild without making any changes to configuration.nix, right? | 20:05:41 |
K900 | Just install from that latest build | 20:05:50 |
K900 | And then sudo nixos-rebuild switch when you want to make changes | 20:05:58 |
henrik-ch | Installed like this:
PS C:\Users\i97he> wsl --import NixOS .\NixOS\ installer.zip --version 2
then I run and get this error:
PS C:\Users\i97he> wsl --shutdown
PS C:\Users\i97he> wsl -d NixOS
Processing fstab with mount -a failed.
<3>WSL (8) ERROR: CreateProcessEntryCommon:358: getpwuid(0) failed 2
<3>WSL (8) ERROR: CreateProcessEntryCommon:362: getpwuid(0) failed 2
<3>WSL (8) ERROR: CreateProcessEntryCommon:570: execvpe /bin/sh failed 2
<3>WSL (8) ERROR: CreateProcessEntryCommon:579: Create process not expected to return
PS C:\Users\i97he>
| 20:13:35 |
K900 | You need to unzip the installer.zip to actually get the install image | 20:14:53 |
Arson Copperflame | There should be a .tar.gz inside that zip, you need to use that instead of the zip directly | 20:14:53 |
K900 | Why does it even work the other way | 20:15:03 |
henrik-ch | Sorry to waste your time with my rookie mistakes, and thanks for your patience! | 20:15:51 |
henrik-ch | trying now | 20:15:55 |
Arson Copperflame | In reply to @k900:0upti.me Why does it even work the other way Because WSL can actually use zips, but then you get a system with the tarball as the only file (and that won't boot obviously). And because this is a MS-Product, the error message does not give any clue to what is actually happening | 20:16:43 |
K900 | Should just ship a squashfs | 20:17:07 |
K900 | /s | 20:17:23 |