How to update grub on hard disk via usb-live-stick

Having installed my ManjaroOS on my hard disk. If I boot my computer with an USB live system stick, how can I edit the original grub file on my hard disk in case of a crash for repairing it in case needed?

This command does not work.

sudo chroot /path/to/temporarily/mounted/harddiskwithOS/ update-grub

What about manjaro-chroot -a ?

will likely not work easily
If I remember correctly
he has got an luks encrypted system with btrfs inside

Bootfehler mit 2. verschlĂĽsselter btrfs Festplatte sowie verschlĂĽsselter SWAP Partition - ERROR: resume: hibernation device - #31 by Nachlese

In the case described here:
luks container opened and the filesystem within mounted on:

/path/to/temporarily/mounted/harddiskwithOS

it would likely be:

manjaro-chroot /path/to/temporarily/mounted/harddiskwithOS

to chroot into the system mounted there

update-grub
has to be a separate command - not on the same line as written in the OP
but only after it has been verified that the chroot has actually worked

@Rulinux
probier das doch mal so …

this is not a command
it is two commands - does not work this way

that might partially work
You probably want to use
manjaro-chroot instead of plain chroot
(it takes care of all the things you have to do manually to actually be able to successfully use your
chroot)

check and verify that that will put you into your system, mounted there

if it did (it’s likely)
then you can do things like:
editing /etc/default/grub
and
running update-grub

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.