Open nazar2sfive opened 4 years ago
Grub supports this, but Clear Linux OS does not support grub, so, this is currently unsupported.
Move this to clr-boot-manager, perhaps, @dorileo ?
systemd-boot
is capable of showing other boot options under a very limited set of conditions. For the menu to show windows as a boot option, the windows bootloader needs to be installed to the same ESP as the CL bootloader in one of the locations it checks for it.
The boot menu can be shown on boot via:
sudo clr-boot-manager set-timeout 5
sudo clr-boot-manager update
However, it will only show options following the spec (I think it's the freedesktop bootloader spec) which is what CL uses via systemd-boot
and a windows bootloader on the same ESP. No other option will show in the menu, so depending on how it's installed you may end up only seeing a kernel or two for booting into CL in the menu. If it's not there, it doesn't meet that criteria!
@bktan8 is there anything cbm
is missing that would enable this use case?
@nazar2sfive - Please see our documentation on how to set up dual-booting scenarios:
@dorileo - cbm
could automate the steps documented in the above links.
clrlinux@clr-live~ $ lsblk -po NAME,SIZE,TYPE,PARTLABEL
NAME SIZE TYPE PARTLABEL
/dev/loop0 2.5G loop
/dev/sda 465.8G disk
├─/dev/sda1 150M part CLR_BOOT
├─/dev/sda2 256M part CLR_SWAP
├─/dev/sda3 74.8G part CLR_ROOT
├─/dev/sda4 529M part Basic data partition
├─/dev/sda5 100M part EFI system partition
├─/dev/sda6 16M part Microsoft reserved partition
├─/dev/sda7 89G part Basic data partition
└─/dev/sda8 301G part Basic data partition
/dev/sdb 14.7G disk
├─/dev/sdb1 2.7G part
└─/dev/sdb2 100M part
/dev/sr0 1024M rom
clrlinux@clr-live~ $ sudo mkdir /mnt/windows-efi
clrlinux@clr-live~ $ sudo mkdir /mnt/clearlinux
clrlinux@clr-live~ $ sudo mount /dev/sda5 /mnt/windows-efi
clrlinux@clr-live~ $ sudo mount /dev/sda3 /mnt/clearlinux
clrlinux@clr-live~ $ sudo mount /dev/sda1 /mnt/clearlinux/boot
clrlinux@clr-live~ $ sudo cp -r /mnt/windows-efi/EFI/Microsoft/ /mnt/clearlinux/boot/EFI/
clrlinux@clr-live~ $ sudo bootctl install --esp-path=/mnt/clearlinux/boot
Created "/mnt/clearlinux/boot/EFI/systemd".
Created "/mnt/clearlinux/boot/EFI/Linux".
Copied "/usr/lib/systemd/boot/efi/systemd-bootx64.efi" to "/mnt/clearlinux/boot/EFI/systemd/systemd-bootx64.efi".
Copied "/usr/lib/systemd/boot/efi/systemd-bootx64.efi" to "/mnt/clearlinux/boot/EFI/BOOT/BOOTX64.EFI".
Created "/mnt/clearlinux/boot/bc535889b3634086806491facf7ab802".
Random seed file /mnt/clearlinux/boot/loader/random-seed successfully written (512 bytes).
Successfully initialized system token in EFI variable with 512 bytes.
Created EFI boot entry "Linux Boot Manager".
clrlinux@clr-live~ $ sudo clr-boot-manager set-timeout 20 --path=/mnt/clearlinux
New timeout value is: 20
[ERROR] cbm (../src/lib/system_stub.c:L31): Invalid block device: 0:25
Out of memory
[FATAL] cbm (../src/bootman/bootman.c:L472): Cannot determine boot device
free(): double free detected in tcache 2
Aborted
clrlinux@clr-live~ $ sudo clr-boot-manager update --path=/mnt/clearlinux
clrlinux@clr-live~ $ sudo umount /mnt/windows-efi /mnt/clearlinux/boot /mnt/clearlinux
clrlinux@clr-live~ $
@nazar2sfive - Thanks for bringing this to our attention. Thanks to @dorileo for fixing these CBM issues starting with Clear version 32220.
I dual boot clear linux with windows 10.
But it directly loads to the clear linux and doesnot give me any dual boot option to load windows 10.
like ubuntu...