Skip to content

Instantly share code, notes, and snippets.

@lukts30
Created August 10, 2024 19:31
Show Gist options
  • Save lukts30/a2333f4b405cb19a6e5f24285e8c5304 to your computer and use it in GitHub Desktop.
Save lukts30/a2333f4b405cb19a6e5f24285e8c5304 to your computer and use it in GitHub Desktop.
slow 20min but works: make-disk-image.nix under qemu-user
nixos-disk-image> error while reading directory /build/root: Cannot allocate memory
nixos-disk-image> [ 118.933097] reboot: Restarting system
nixos-disk-image> WARNING: Image format was not specified for 'nixos.raw' and probing guessed raw.
nixos-disk-image> Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
nixos-disk-image> Specify the 'raw' format explicitly to remove the restrictions.
nixos-disk-image> kvm version too old
nixos-disk-image> qemu-system-aarch64: failed to initialize kvm: Inappropriate ioctl for device
nixos-disk-image> qemu-system-aarch64: falling back to tcg
nixos-disk-image> loading kernel modules...
nixos-disk-image> cat: can't open '/nix/store/4dsqx50k3x8yxa5akmxfi733fv07ak8r-linux-6.6.44-shrunk/insmod-list': No such file or directory
nixos-disk-image> mounting Nix store...
nixos-disk-image> mounting host's temporary directory...
nixos-disk-image> starting stage 2 (/nix/store/q8z46641vm9q08zya0hk5k4nksksbdhv-vm-run-stage2)
nixos-disk-image> tune2fs 1.47.0 (5-Feb-2023)
nixos-disk-image> Setting maximal mount count to -1
nixos-disk-image> Setting interval between checks to 0 seconds
nixos-disk-image> Setting time filesystem last checked to Sat Aug 10 18:30:55 2024
nixos-disk-image> mkfs.fat 4.2 (2021-01-31)
nixos-disk-image> setting up /etc...
nixos-disk-image> setting up secrets...
nixos-disk-image> Cannot read ssh key '/etc/ssh/ssh_host_rsa_key': open /etc/ssh/ssh_host_rsa_key: no such file or directory
nixos-disk-image> Cannot read ssh key '/etc/ssh/ssh_host_ed25519_key': open /etc/ssh/ssh_host_ed25519_key: no such file or directory
nixos-disk-image> /nix/store/a8acj93ypd2m0sahq3mwj3cxqjzlxffp-sops-install-secrets-0.0.1/bin/sops-install-secrets: cannot read keyfile '/var/lib/sops-nix/key.txt': open /var/lib/sops-nix/key.txt: no such file or directory
nixos-disk-image> Activation script snippet 'setupSecrets' failed (1)
nixos-disk-image> Initializing machine ID from random generator.
nixos-disk-image> Created "/boot/EFI".
nixos-disk-image> Created "/boot/EFI/systemd".
nixos-disk-image> Created "/boot/EFI/BOOT".
nixos-disk-image> Created "/boot/loader".
nixos-disk-image> Created "/boot/loader/entries".
nixos-disk-image> Created "/boot/EFI/Linux".
nixos-disk-image> Copied "/nix/store/hg0gma6hg0p70cs95bpxhhbvxc8w8rvn-systemd-255.9/lib/systemd/boot/efi/systemd-bootaa64.efi" to "/boot/EFI/systemd/systemd-bootaa64.efi".
nixos-disk-image> Copied "/nix/store/hg0gma6hg0p70cs95bpxhhbvxc8w8rvn-systemd-255.9/lib/systemd/boot/efi/systemd-bootaa64.efi" to "/boot/EFI/BOOT/BOOTAA64.EFI".
nixos-disk-image> ⚠ Mount point '/boot' which backs the random seed file is world accessible, which is a security hole! ⚠
nixos-disk-image> ⚠ Random seed file '/boot/loader/.#bootctlrandom-seed36f6f7a157b07528' is world accessible, which is a security hole! ⚠
nixos-disk-image> Random seed file /boot/loader/random-seed successfully written (32 bytes).
nixos-disk-image> tune2fs 1.47.0 (5-Feb-2023)
nixos-disk-image> Setting maximal mount count to -1
nixos-disk-image> Setting interval between checks to 0 seconds
nixos-disk-image> Setting time filesystem last checked to Sat Aug 10 18:39:51 2024
nixos-disk-image> tune2fs 1.47.0 (5-Feb-2023)
nixos-disk-image> Setting time filesystem last checked to Thu Jan 1 00:00:00 1970
nixos-disk-image> [ 808.851283] reboot: Power down
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment