WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: How to install/setup the Grub2 bootloader on CorePlus ??  (Read 129 times)

Offline Len E.

  • WikiUser
  • *
  • Posts: 7
How to install/setup the Grub2 bootloader on CorePlus ??
« on: December 02, 2017, 08:28:13 PM »
Hi Juanito:

I hope this catches your attention because your name is on the grub2-multi.tcz extension description.

After installing the extension, I executed the mount and grub-install commands shown in the "how to"
instructions.   (I'm using partition sda3 on my test machine).

I checked the /mnt/sda3/boot/grub directory, but no grub.cfg was created.

From an online Grub 2.02 manual, I found a description of the grub-mkconfig command which usually creates grub.cfg.
Accordingly, I entered       sudo grub-mkconfig -o /boot/grub/grub.cfg

I got the following error message:

/usr/local/sbin/grub-probe: error:  failed to get canonical path of 'rootfs'

Please advise on what to do.

Thanks !
Len E.
« Last Edit: December 02, 2017, 08:31:02 PM by Len E. »

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 9707
Re: How to install/setup the Grub2 bootloader on CorePlus ??
« Reply #1 on: December 02, 2017, 10:40:34 PM »
The info file assumes that you would create grub.cfg manually - there are several examples if this in the forum.

I may be mistaken, but I'd guess that you are missing something in the grub-mkconfig command (which I've never used)?

Offline coreplayer2

  • Hero Member
  • *****
  • Posts: 2554
Re: How to install/setup the Grub2 bootloader on CorePlus ??
« Reply #2 on: December 02, 2017, 10:42:47 PM »
As previously mentioned, simply installing grub2 will not create a boot config file and even if asked of grub the installer may not even find the core files either..    So it's easiest to create a config file using the mkconfig commands if you wish to add windows and other linux distro to the menu options.  Remember the tinycore entries may be best created manually.

Here's an example off one of my PC's with some superfluous menu items removed for simplicity..
Code: [Select]
insmod part_msdos
insmod fat
insmod ext2
loadfont unicode
set gfxterm=auto
terminal_output gfxterm
GRUB_GFXMODE=1900X1200X16
GRUB_GFXPAYLOAD_LINUX=keep

#Timeout for menu
set default=3
set timeout=20


menuentry "*** TC-8-x86 (Xvesa on Samsung)" {
search --no-floppy --fs-uuid --set=root 196fcfb2-bd37-495d-b855-41f08201be7d
linux /linux/vmlinuz-4817 vmalloc=256MB tz=GMT loglevel=3 waitusb=5:UUID="196fcfb2-bd37-495d-b855-41f08201be7d" tce=UUID="196fcfb2-bd37-495d-b855-41f08201be7d"/tc8-x86 opt=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" home=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" lst=onboot_x86_Xvesa.lst mydata=mydata_tc8x86.Vesa
initrd /linux/rootfs-821.gz /linux/modules-4817.gz
}

menuentry "*** TC-8-x86 (Xorg on Samsung)" {
search --no-floppy --fs-uuid --set=root 196fcfb2-bd37-495d-b855-41f08201be7d
linux /linux/vmlinuz-4817 vmalloc=256MB tz=GMT loglevel=3 waitusb=5:UUID="196fcfb2-bd37-495d-b855-41f08201be7d" tce=UUID="196fcfb2-bd37-495d-b855-41f08201be7d"/tc8-x86 opt=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" home=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" lst=onboot_x86_Xorg.lst mydata=mydata_tc7x86.Xorg blacklist=snd_usb_audio
initrd /linux/rootfs-821.gz /linux/modules-4817.gz
}

menuentry "*** TC-8-Core64 (on Samsung)" {
search --no-floppy --fs-uuid --set=root 196fcfb2-bd37-495d-b855-41f08201be7d
linux /linux/vmlinuz64-4817 tz=GMT loglevel=3 waitusb=5:UUID="196fcfb2-bd37-495d-b855-41f08201be7d" tce=UUID="196fcfb2-bd37-495d-b855-41f08201be7d"/tc8-x86 opt=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" home=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" lst=onboot_Core64.lst blacklist=snd_usb_audio
initrd /linux/rootfs-821.gz /linux/modules64-4817.gz
}

menuentry "*** TC-8-Corepure64 (on Samsung)" {
search --no-floppy --fs-uuid --set=root 196fcfb2-bd37-495d-b855-41f08201be7d
linux /linux/vmlinuz64-4817 noswap tz=GMT loglevel=3 waitusb=5:UUID="196fcfb2-bd37-495d-b855-41f08201be7d" tce=UUID="196fcfb2-bd37-495d-b855-41f08201be7d"/tc8-x86_64 opt=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" home=UUID="196fcfb2-bd37-495d-b855-41f08201be7d" lst=onboot_CorePure64.lst mydata=mydataCorePure64 blacklist=snd_usb_audio
initrd /linux/rootfs64-821.gz /linux/modules64-4817.gz
}

menuentry "Windows (on SSD)" --class windows --class os {
insmod part_msdos
insmod ntfs
insmod ntldr
set root='(hd1,msdos1)'
search --no-floppy --fs-uuid --set=root 8C3A96F13A96D812
ntldr /bootmgr
}

menuentry "Windows BackUp (on Seagate HDD)" --class windows --class os {
insmod part_msdos
insmod ntfs
insmod ntldr
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set=root EE26108A261055C5
ntldr /bootmgr
}

menuentry "System restart" {
echo "System rebooting..."
reboot
}

You'll need to edit the menu item header
and the --set=root  will need to be amended with the UUID for the drive and /or partition where core files and kernel are installed
also the paths to the core + kernel files will need to be ammended
also tce, home and Opt UUID's will need to be updated with the correct partition UUID

I rarely get it right the first boot..  good luck


Oh and the
Code: [Select]
failed to get canonical path of 'rootfs'error message I believe comes from the fact that required partition's are not mounted (iirc)
« Last Edit: December 02, 2017, 10:44:21 PM by coreplayer2 »