Tiny Core Base > CorePlus

[Solved} Grub2 does not load grub.cfg automatically

<< < (3/6) > >>

Sashank999:

--- Quote from: Rich on May 23, 2020, 10:18:10 AM ---Hi Sashank999

--- Quote from: Sashank999 on May 23, 2020, 02:25:38 AM --- ... Another thing, do we have a way to change the boot directory after installation of grub2 ?
--- End quote ---
I think running the install command again using the  --boot-directory=  option should do it:

--- Code: ---sudo grub-install --boot-directory=/mnt/sda5/tce/boot /dev/sda5
--- End code ---

I would create a backup of your  grub.cfg  file before running the install command just to be safe.

--- End quote ---
@Rich . Now, I am gonna do a new grub install with --target=i386-pc (of course unnecessary) and also with --boot-directory=/tce/boot/ like this :

--- Code: ---grub-install --target=i386-pc --boot-directory=/tce/boot/ /dev/sda5

--- End code ---
I will also report any errors during installation, make a backup of current grub.cfg and restore grub.cfg after new grub installation.
P.S. I am also doing rm-rf those old grub folders (/boot and /tce/boot/grub)
[EDIT] : Added P.S.

aus9:

--- Quote ---I don't know if my TCL is 32 bit
--- End quote ---

for 32 bit....menu might show vmlinuz and core.gz 
for 64 bit ....menu might show vmlinuz64 and corepure64.gz as per
http://tinycorelinux.net/11.x/x86_64/release/distribution_files/

BTW I am not trying to force you on onto 64 bit as generally speaking 32 bit packages are smaller than 64 bit. But if you have lots of RAM....well you decide   ;D

Sashank999:
I rm -rf the old grub directories,got "sudo su" and typed :

--- Code: (bash) ---grub-install --target=i386-pc --boot-directory=/tce/boot /dev/sda5

--- End code ---
Then I got this error : "grub-install: error: failed to get canonical path of "rootfs" "
So, I tried this :

--- Code: (bash) ---grub-install --target=i386-pc --boot-directory=/mnt/sda5/tce/boot /dev/sda5

--- End code ---
Then, I got :
Installing for i386-pc platform.
grub-install: warning: File system `ext2' doesn't support embedding.
grub-install: warning: Embedding is not possible.  GRUB can only be installed in this setup by using blocklists.  However, blocklists are UNRELIABLE and their use is discouraged..
grub-install: error: will not proceed with blocklists.

But the grub folder was created in /mnt/sda5/tce/boot . So, I used the --force :

--- Code: (bash) ---grub-install --target=i386-pc --boot-directory=/mnt/sda5/tce/boot --force /dev/sda5

--- End code ---
Then I got :
Installing for i386-pc platform.
grub-install: warning: File system `ext2' doesn't support embedding.
grub-install: warning: Embedding is not possible.  GRUB can only be installed in this setup by using blocklists.  However, blocklists are UNRELIABLE and their use is discouraged..
Installation finished. No error reported.

Then, I restored the old grub.cfg into the grub folder and then rebooted. Then, I got the GRUB v0.4.6a console.
I booted into TCL and then did the previous trick: Copying /mnt/sda5/tce/boot directory to /mnt/sda5. Then, the GRUB v2 booted with the menu.


--- Quote from: aus9 on May 24, 2020, 02:58:29 AM ---
--- Quote ---I don't know if my TCL is 32 bit
--- End quote ---

for 32 bit....menu might show vmlinuz and core.gz 
for 64 bit ....menu might show vmlinuz64 and corepure64.gz as per
http://tinycorelinux.net/11.x/x86_64/release/distribution_files/

BTW I am not trying to force you on onto 64 bit as generally speaking 32 bit packages are smaller than 64 bit. But if you have lots of RAM....well you decide   ;D

--- End quote ---
Then, I got 32 bit TCL now. How to change to 64 bit ? Is replacing the vmlinuz and core.gz to vmlinuz64 and corepure64.gz enough ?

Juanito:
You can either replace them or copy them alongside and add a grub.cfg menu entry so that you have the choice of 32/64-bit.

If you decide to add a menu entry, use "tce=tce64" to create a separate tce folder for 64-bit tinycore.

Sashank999:

--- Quote from: Juanito on May 24, 2020, 03:58:19 AM ---You can either replace them or copy them alongside and add a grub.cfg menu entry so that you have the choice of 32/64-bit.

If you decide to add a menu entry, use "tce=tce64" to create a separate tce folder for 64-bit tinycore.

--- End quote ---
Hi Juanito
Thanks for the reply.
My question is why does the grub only load GRUB v2.02 from /boot/grub but not from /tce/boot/grub ?
UPDATE : The GRUB v2.02 loads grub.cfg from /tce/boot/grub, not from /boot/grub.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version