-
-
Notifications
You must be signed in to change notification settings - Fork 197
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
using disko-install from usb installation: wrong boot partition #743
Comments
Are you using grub or systemd-boot? |
I am using systemd-boot. |
I have looked into this a bit further and tried using the standard formatting command given when following the quickstart guide (https://github.com/nix-community/disko/blob/master/docs/quickstart.md#step-6-run-disko-to-partition-format-and-mount-your-disks): # nix --experimental-features "nix-command flakes" run github:nix-community/disko -- --mode disko /etc/nixos/hosts/thinkpad/disks.nix This results in the hard drive being formatted as per the defined scheme, but the wrong partitions get mounted. For example, on my thinkpad, the internal drive is If I instead use # nix --experimental-features "nix-command flakes" run github:nix-community/disko -- --mode format /etc/nixos/hosts/thinkpad/disks.nix
# mkdir -p /mnt/boot
# mount /dev/nvme0n1p2 /mnt
# mount -o umask=077 /dev/nvme0n1p1 /mnt/boot
# nixos-generate-config --no-filesystems --root /mnt --dir /etc/nixos/hosts/thinkpad/
# nixos-install --flake "/etc/nixos/?submodules=1#thinkpad" --no-root-passwd
# cp /var/lib/sops-nix/key.txt /mnt/var/lib/sops-nix/key.txt
# cp -r -T /etc/nixos /mnt/etc/nixos I have a hunch that this might be due to a naming clash resulting in the wrong partitions being mounted, which could potentially be mitigated by providing a The reason I have this hunch is that I had a similar issue when trying to boot from my usb having just installed nixos as above, as it was looking for a root partition with the name I have not had a chance to test this theory out yet! |
Just to make sure, if the USB stick is |
Sorry for the confusion - the first time I was having the issue on one laptop (elitebook), which has its internal drive at The second comment in which I successfully installed by manually mounting the partitions was done on a second laptop (thinkpad), which has its internal drive at If I were to try using |
Hi,
I have a full NixOS installation on a USB stick, to be able to use my own system from any PC.
I attempted to reinstall my NixOS configuration onto my laptop using
disko-install
from the USB installation, with the--write-efi-boot-entries
option, using the following command:This almost worked, however the EFI boot entry was written to the boot partition of the USB instead of the laptop.
What went wrong here, and what would I need to do in order to successfully install NixOS onto a computer from my USB installation?
The text was updated successfully, but these errors were encountered: