![]() |
[SOLVED] Cannot install Snakeoil on UEFI-only NUC - Printable Version +- Snakeoil Forums (https://forums.snakeoil-os.net) +-- Forum: Snakeoil Topics (https://forums.snakeoil-os.net/Forum-Snakeoil-Topics) +--- Forum: Support & Troubleshooting (https://forums.snakeoil-os.net/Forum-Support-Troubleshooting) +--- Thread: [SOLVED] Cannot install Snakeoil on UEFI-only NUC (/Thread-SOLVED-Cannot-install-Snakeoil-on-UEFI-only-NUC) Pages:
1
2
|
Cannot install Snakeoil on UEFI-only NUC - scskam - 08-Aug-2020 Hi there, I am interested in Snakeoil and have purchased an Intel NUC7CJYH with a fanless chasis to try it. This NUC doesn't only legacy BIOS boot so UEFI is my only choice. I tried both burning the Snakeoil ISO image to CD-ROM and creating a bootable USB using Rufus. CD-ROM could boot up and I could start the installation. For USB, it always stops at grub-rescue and I had to issue the following commands to make it proceed to boot: set prefix=(hd,msdos1)/boot/grub set root=(hd0,1) insmod normal normal For both cases, I could install to my SSD without problems. However, when booting from SSD, the following error is displayed: error: kernel doesn't support EFI handover. Loading initial ramdisk ... alloc magic is broken at.... I have tried replacing other Snakeoil kernels in the USB and performed the installation again, the result is the same. I have also tried installing the SSD on another NUC supporting legacy boot, and then moved it to the UEFI NUC and used Boot Repair as suggested in another thread. No luck so far. Searching on the web suggested that the following flag should be set when building the kernel: CONFIG_EFI_STUB=y Any chance that a kernel can be built to support the UEFI boot? Many Thanks. SK RE: Cannot install Snakeoil on UEFI-only NUC - Bromf - 08-Aug-2020 UEFI boot works here but I had to boot Win 7 and clear all partitions prior to installing. You want a cleared drive formatted to Fat32 or Ext4... Reboot and install works as expected. :-) RE: Cannot install Snakeoil on UEFI-only NUC - scskam - 08-Aug-2020 (08-Aug-2020, 02:30 PM)Bromf Wrote: UEFI boot works here but I had to boot Win 7 and clear all partitions prior to installing. I always select the option of "Erase the whole drive and install Ubuntu".... RE: Cannot install Snakeoil on UEFI-only NUC - Bromf - 08-Aug-2020 (08-Aug-2020, 04:41 PM)scskam Wrote:(08-Aug-2020, 02:30 PM)Bromf Wrote: UEFI boot works here but I had to boot Win 7 and clear all partitions prior to installing. Yes..I did that over and over again on a thin client with UEFI and Snakeoil install failed every time. Finally I installed Win7 and at the drive allocation prompt I deleted all partitions (including the reserved and UEFI boot) then rebooted and was able to install Snakeoil. RE: Cannot install Snakeoil on UEFI-only NUC - scskam - 09-Aug-2020 (08-Aug-2020, 04:50 PM)Bromf Wrote:(08-Aug-2020, 04:41 PM)scskam Wrote:(08-Aug-2020, 02:30 PM)Bromf Wrote: UEFI boot works here but I had to boot Win 7 and clear all partitions prior to installing. Hi Bromf, Thanks for your reply. To ensure the partitions and their contents are right, I first installed stock Ubuntu on the SSD, then resized the partition to free up some space for installing Snakeoil OS alongside with the stock Ubuntu. I can choose inside grub to boot stock Ubuntu (which boots up ok) or Snakeoil OS. The same error message displayed when Snakeoil kernel boots up. So the problem is the Snakeoil kernel not built with UEFI fully turned on. As said, there are suggestions that the following flag should be turned on when building the kernel: CONFIG_EFI_STUB = y I just checked the config file released with one of the customized Snakeoil kernels, this flag was not set while other EFI flags are set: CONFIG_EFI_PARTITION=y . . CONFIG_EFI=y # CONFIG_EFI_STUB is not set . . Hopefully the UEFI support can be improved by adding this flag back. Many thanks. SK RE: Cannot install Snakeoil on UEFI-only NUC - agent_kith - 10-Aug-2020 Check your BIOS and look for anything that says "Compatibility Support Module", can you turn on legacy support mode? Technically, the problem with the ISO is it will not boot in a EFI environment, but the OS itself should be fine (as long as your computer works with unsigned boot). After the install, start a command shell, and try this and see if it works? 1. After install, start a command shell. 2. Changeroot to remount the install edition as your root. I can't remember offhand what the path is, but you can find it in df or mount, then run chroot Code: chroot /path/to/your/install/partition Code: sudo grub-mkconfig -o /boot/grub/grub.cfg RE: Cannot install Snakeoil on UEFI-only NUC - scskam - 10-Aug-2020 (10-Aug-2020, 07:58 AM)agent_kith Wrote: Check your BIOS and look for anything that says "Compatibility Support Module", can you turn on legacy support mode?Thanks agent-kith. There is no legacy boot support nor CSM smode in the bios. I have disabled secure boot and S3 related settings, the UEFI boot cannot be turned off and no legacy boot available in the BIOS menu. The Snakeoil automatically rebooted after installation so I had to change to seed file on the USB to disable reboot. The partition in of the newly installed OS is /target. Here is the output when I issued the suggested commands. Many thanks. SK [/code] snakeoil@snakeoil:/$ df Filesystem 1K-blocks Used Available Use% Mounted on udev 7977460 0 7977460 0% /dev tmpfs 1597148 10800 1586348 1% /run /dev/sdb1 30026752 411776 29614976 2% /cdrom /dev/loop0 375808 375808 0 100% /rofs /cow 7985724 231052 7754672 3% / tmpfs 7985724 0 7985724 0% /dev/shm tmpfs 5120 4 5116 1% /run/lock tmpfs 7985724 0 7985724 0% /sys/fs/cgroup tmpfs 7985724 28 7985696 1% /tmp /dev/sda2 98647660 1916784 91696792 3% /target /dev/sda1 523248 8596 514652 2% /target/boot/efi snakeoil@snakeoil:/$ chroot /target/boot/efi chroot: cannot change root directory to '/target/boot/efi': Permission denied snakeoil@snakeoil:/$ sudo chroot /target root@snakeoil:/# sudo grub -mkconfig -o /boot/grub/grub.cfg sudo: unable to resolve host snakeoil: Connection timed out sudo: grub: command not found root@snakeoil:/# grub The program 'grub' is currently not installed. You can install it by typing: apt install grub root@snakeoil:/# apt install grub Reading package lists... Done Building dependency tree Reading state information... Done You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies: grub : Depends: libc6-i386 (>= 2.15) but it is not going to be installed Conflicts: grub-efi-amd64 Conflicts: grub-efi-amd64:i386 grub-efi : Depends: grub-efi-amd64 (= 2.02~beta2-9ubuntu1.12) grub-efi-amd64 : Conflicts: grub but 0.97-29ubuntu68 is to be installed grub2-common : Breaks: grub (< 0.97-54) but 0.97-29ubuntu68 is to be installed E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution). root@snakeoil:/# apt-get -f install Reading package lists... Done Building dependency tree Reading state information... Done Correcting dependencies... Done The following packages were automatically installed and are no longer required: dmeventd dmraid gir1.2-javascriptcoregtk-4.0 gir1.2-soup-2.4 gir1.2-vte-2.91 gir1.2-webkit2-4.0 kpartx kpartx-boot laptop-detect libdevmapper-event1.02.1 libdmraid1.0.0.rc16 libiw30 liblvm2cmd2.02 libparted-fs-resize0 libreadline5 libtimezonemap-data libvte-2.91-0 libvte-2.91-common lzma Use 'sudo apt autoremove' to remove them. The following additional packages will be installed: grub-efi The following packages will be upgraded: grub-efi 1 upgraded, 0 newly installed, 0 to remove and 358 not upgraded. 1 not fully installed or removed. Need to get 2,544 B of archives. After this operation, 16.4 kB disk space will be freed. Do you want to continue? [Y/n] y 0% [Connecting to hk.archive.ubuntu.com] 0% [Connecting to hk.archive.ubuntu.com] Err:1 http://security.ubuntu.com/ubuntu xenial-security/main amd64 grub-efi amd64 2.02~beta2-36ubuntu3.27 Temporary failure resolving 'hk.archive.ubuntu.com' Err:1 http://security.ubuntu.com/ubuntu xenial-security/main amd64 grub-efi 4 2.02~beta2-36ubuntu3.27 Temporary failure resolving 'hk.archive.ubuntu.com' E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/g/grub2/grub-2.02~beta2-36ubuntu3.27_amd64.deb Temporary failure resolving 'hk.archive.uu.com' E: Unable to fetch some archives, maybe run apt-get update or try with --fixsing? root@snakeoil:/# sudo grub-mkconfig -o /boot/grub/grub.cfg sudo: unable to resolve host snakeoil: Connection timed out /usr/sbin/grub-probe: error: cannot find a device for / (is /dev mounted?). root@snakeoil:/# [/quote] RE: Cannot install Snakeoil on UEFI-only NUC - agent_kith - 10-Aug-2020 Almost certain you don't need to install grub_efi... Because Ubuntu will detect your system is using EFI and install the correct bootloader. Correct to chroot to /target. That's the correct directory. Once you've done that, can u run Code: sudo mount /dev and then run this command again (ignore grub-mkconfig for now): Code: sudo grub-install --target=x86_64-efi --bootloader-id=grub_uefi --recheck grub-mkconfig -o /boot/grub/grub.cfg RE: Cannot install Snakeoil on UEFI-only NUC - scskam - 10-Aug-2020 (10-Aug-2020, 03:17 PM)agent_kith Wrote: Almost certain you don't need to install grub_efi... Because Ubuntu will detect your system is using EFI and install the correct bootloader. Hi there, Here is the command I issued and the output: snakeoil@snakeoil:/$ sudo chroot /target mount /dev mount: can't find /dev in /etc/fstab snakeoil@snakeoil:/$ Content of /target/etc/fstab: # /etc/fstab: static file system information. # # Use 'blkid' to print the universally unique identifier for a # device; this may be used with UUID= as a more robust way to name devices # that works even if disks are added and removed. See fstab(5). # # <file system> <mount point> <type> <options> <dump> <pass> # / was on /dev/sda2 during installation UUID=6bf65c47-9647-4cec-95e2-a768d459f544 / ext4 errors=remount -ro 0 1 # /boot/efi was on /dev/sda1 during installation UUID=D721-9A00 /boot/efi vfat umask=0077 0 1 # swap was on /dev/sda3 during installation UUID=bf78d7ab-0034-4ee9-8cf6-a4decad376a6 none swap sw 0 0 Thanks for your help. SK RE: Cannot install Snakeoil on UEFI-only NUC - agent_kith - 11-Aug-2020 Hmm. After you have chroot to /target. Try and run this: Code: mount udev -t devtmpfs /dev Make sure your snakeoil partition is at / before you run the above command, and also grub-install. Still waiting for my network card to get here.. Once it's here it will be easier for me to work out EFI issues. Having said that, all my computers have CSM so I'm not too hopeful.. At least then I can properly start work on getting the new ISO out. Hopefully the latest Ubuntu will have better EFI support. It's been almost 3 months I think.. Almost takes a season for my network card to get here, and I'm not even sure if it's a legit NIC or not. ![]() |