[Nix-dev] Nixos boot fails at stage 1 in virtualbox

Wout Mertens wout.mertens at gmail.com
Mon May 12 14:10:42 CEST 2014


Looks like your root disk got corrupted?
On May 12, 2014 10:19 AM, "Corentin Henry" <corentinhenry at gmail.com> wrote:

> Hi,
>
> I am trying to install Nixos in virtualbox. I follow
> insttructions from here :
> https://nixos.org/wiki/Installing_NixOS_in_a_VirtualBox_guest
>
>  $ fdisk /dev/sda ;# Create only one ext4 partition, make it bootable.
>  $ mkfs.ext4 -j -L nixos /dev/sda1
>  $ mount LABEL=nixos /mnt
>  $ nixos-generate-config --root /mnt
>
> /etc/configuration.nix :
>
> { config, pkgs, ... };
> {
>     imports =
>         [
>             ./hardware-configuration.nix
>         ];
>
>     boot.loader.grub.enable = true
>     boot.loader.grub.version = 2
>     boot.loader.grub.enable = "/dev/sda"
>     fileSystems = [
>         {
>             mountPoint = "/";
>             label = "nixos"
>         }
>     ];
> }
>
>
>
> /etc/hardware-configuration.nix :
>
> { config, pkgs, ... };
> {
>     imports =
>         [<nixpkgs/nixos/modules/installer/scan/not-detected.nix>
>         ];
>     boot.initrd.availableKernelModules = [ "ata_piix" "ohci_pci" "ahci" ];
>     boot.kernelModules = [ ];
>     boot.extraModulePackages = [ ];
>     swapDevices = [ ];
>     nix.maxJobs = 1;
>     services.virtualbox.enable = true;
> }
>
> Installation does not show any error but when rebooting :
>
>    [fsck.ext4 (1) -- /mnt-root/] fsck.ext4 -a /dev/sda1
>    nixos: recovering journal
>    nixos: clean, 62800/1310720 files, 376636/5242624 blocks
>    mounting /dev/sda1 on /...
>    checking /dev/disk/by-label/nixos...
>    fsck (busybox 1.22.1, 2014-04-20 17:51:13 UTC)
>    [fsck.ext4 (1) -- /mnt-root/] fsck.ext4 -a /dev/disk/by-label/nixos
>    /dev/disk/by-label/nixos is mounted
>    e2fsck: Cannot continue, aborting.
>
>    fsck on /dev/disk/by-label/nixos failed.
>
>    An error occurred in stage 1 of the boot process, which must mount the
>    root filesystem on '/mnt-root' and then start stage 2. Press one of the
>    following keys:
>
>            r) to reboot immediately
>            *) to ignore the error and continue
>    *
>    Continuing...
>    mounting /dev/disk/by-label/nixos on /...
>    mount: mounting /dev/disk/by-label/nixos on /mnt-root/ failed: Device
>    or resource busy
>
>    An error occurred in stage 1 of the boot process, which must mount the
>    root filesystem on '/mnt-root' and then start stage 2. Press one of the
>    following keys:
>
>            r) to reboot immediately
>            *) to ignore the error and continue
>
> Anyone could help with this, please ?
>
> _______________________________________________
> nix-dev mailing list
> nix-dev at lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20140512/5bc856f7/attachment.html 


More information about the nix-dev mailing list