!apXxbtexmNGJaAryzM:nixos.org

NixOS on WSL

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

Load older messages


SenderMessageTime
15 Jun 2024
@toddt:matrix.orgTodd Thompson

warning: Nix search path entry '/nix/var/nix/profiles/per-user/root/channels/nixos' does not exist, ignoring
warning: Nix search path entry '/nix/var/nix/profiles/per-user/root/channels' does not exist, ignoring
error: file 'nixpkgs' was not found in the Nix search path (add it using $NIX_PATH or -I)

   at «none»:0: (source not available)

building the system configuration...
warning: Nix search path entry '/nix/var/nix/profiles/per-user/root/channels/nixos' does not exist, ignoring
warning: Nix search path entry '/nix/var/nix/profiles/per-user/root/channels' does not exist, ignoring
error: file 'nixpkgs/nixos' was not found in the Nix search path (add it using $NIX_PATH or -I)

   at «none»:0: (source not available)
08:27:22
@k900:0upti.meK900 You want --upgrade-all 08:30:07
@k900:0upti.meK900And you want to run all of that as root 08:30:13
@toddt:matrix.orgTodd Thompsonran "sudo nix-channel --update" first and then upgrade again, but it failed with...08:31:12
@toddt:matrix.orgTodd Thompson error: package clap v4.5.4 cannot be built because it requires rustc 1.74 or newer, while the currently active rustc version is 1.73.0
Either upgrade to rustc 1.74 or newer, or use
cargo update -p clap@4.5.4 --precise ver
where ver is the latest version of clap supporting rustc 1.73.0
error: builder for '/nix/store/vz70pnvz94w0is3vrpkf6yg7kx2q8d9v-nixos-wsl-utils-1.0.0.drv' failed with exit code 101;
last 10 log lines:
> Finished cargoSetupPostPatchHook
> Running phase: updateAutotoolsGnuConfigScriptsPhase
> Running phase: configurePhase
> Running phase: buildPhase
> Executing cargoBuildHook
> ++ env CC_X86_64_UNKNOWN_LINUX_GNU=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/cc CXX_X86_64_UNKNOWN_LINUX_GNU=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/c++ CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/cc CC_X86_64_UNKNOWN_LINUX_GNU=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/cc CXX_X86_64_UNKNOWN_LINUX_GNU=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/c++ CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/cc CARGO_BUILD_TARGET=x86_64-unknown-linux-gnu HOST_CC=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/cc HOST_CXX=/nix/store/shdkxxdlpv66wl33rh9d01zfypaka1dn-gcc-wrapper-12.3.0/bin/c++ cargo build -j 16 --target x86_64-unknown-linux-gnu --frozen --profile release
> error: package clap v4.5.4 cannot be built because it requires rustc 1.74 or newer, while the currently active rustc version is 1.73.0
> Either upgrade to rustc 1.74 or newer, or use
> cargo update -p clap@4.5.4 --precise ver
> where ver is the latest version of clap supporting rustc 1.73.0
For full logs, run 'nix-store -l /nix/store/vz70pnvz94w0is3vrpkf6yg7kx2q8d9v-nixos-wsl-utils-1.0.0.drv'.
error: 1 dependencies of derivation '/nix/store/ykr6zrnfjbim073hk6sbc35s3hk7anvn-nixos-system-nixos-23.11.7609.5c2ec3a5c2ee.drv' failed to build
08:31:19
@k900:0upti.meK900 Did you run the nix-channel --add command as root? 08:31:46
@k900:0upti.meK900You need to run that as root, otherwise it only affects your user's channels 08:31:57
@toddt:matrix.orgTodd Thompson"sudo nixos-rebuild switch --upgrade-all"?08:31:57
@k900:0upti.meK900 sudo nix-channel --add https://channels.nixos.org/nixos-24.05 nixos first 08:32:27
@k900:0upti.meK900 And then sudo nixos-rebuild switch --upgrade-all 08:32:39
@toddt:matrix.orgTodd Thompsonok, that's not stated in https://nixos.org/manual/nixos/stable/#sec-upgrading08:32:40
@toddt:matrix.orgTodd Thompsonthanks08:32:46
@toddt:matrix.orgTodd Thompsonlooks like that worked. maybe you can recommend updating the community page and manual08:34:48
@toddt:matrix.orgTodd ThompsonI appreciate your help08:35:03
@k900:0upti.meK900We should just update the bootstrap tarball to 24.0508:37:07
@k900:0upti.meK900Now it's officially out 08:37:12
@k900:0upti.meK900 nzbr (they/it) can you do the thing? 08:37:20
@k900:0upti.meK900(I can't releng) 08:37:29
@toddt:matrix.orgTodd Thompsonyes, but community page still needs to be updated to 24.0508:38:25
@toddt:matrix.orgTodd Thompsonand manual doesn't show using sudo08:38:43
@toddt:matrix.orgTodd ThompsonI updated my configuration.nix file to ... but it now starts me as root with "<3>WSL (36034) ERROR: CreateProcessParseCommon:748: getpwnam(nixos) failed 5"08:48:39
@toddt:matrix.orgTodd Thompson

{ config, lib, pkgs, ... }:

{
imports = [
# include NixOS-WSL modules
<nixos-wsl/modules>
];

users.users.todd = {
isNormalUser = true;
home = "/home/todd";
description = "Todd Thompson";
extraGroups = [ "wheel" "networkmanager" ];
};

wsl.enable = true;
wsl.defaultUser = "todd";

This value determines the NixOS release from which the default

settings for stateful data, like file locations and database versions

on your system were taken. It's perfectly fine and recommended to leave

this value at the release version of the first install of this system.

Before changing this value read the documentation for this option

(e.g. man configuration.nix or on https://nixos.org/nixos/options.html).

system.stateVersion = "24.05"; # Did you read the comment?
system.autoUpgrade.enable = true;
system.autoUpgrade.allowReboot = true;
}

08:48:43
@k900:0upti.meK900You need to restart WSL entirely if changing the default user name 08:49:29
@k900:0upti.meK900 Run wsl --shutdown 08:49:35
@toddt:matrix.orgTodd Thompsongotcha08:49:37
@k900:0upti.meK900 And then wsl again 08:49:40
@toddt:matrix.orgTodd Thompsonthanks08:49:44
@k900:0upti.meK900Also, do not use allowReboot08:49:59
@k900:0upti.meK900The WSL VM cannot reboot 08:50:05
@k900:0upti.meK900Attempting to reboot it leaves it in a weird fucked up state half the time 08:50:20

Show newer messages


Back to Room ListRoom Version: 9