why didn't I have to $ sudo update-grub2?

Chat about Linux in general
Post Reply
oldgranola
Level 3
Level 3
Posts: 187
Joined: Fri Sep 05, 2014 1:39 am

why didn't I have to $ sudo update-grub2?

Post by oldgranola » Sat Aug 25, 2018 3:44 pm

Hello,
Kernel hopping, distro hopping, and running Arch alongside LM19. Two grub things are different than expected.
1. after getting rid of a kernel in LM19

Code: Select all

remove --purge linux-unsigned-image-4.17.0-generic
I should have to

Code: Select all

sudo update-grub2
But I don't seem to have to. It appears to now be a part of the purge. Boot menu seems to already be updated. Cool. Did something change?

2. Arch documentation says it has to own grub (or whatever boot controler) to boot; that updating debian/ubuntu/mint grub will wipe out the Arch grub and one must go back to the arch live install media, chroot, mount to the arch install and repair its grub to have arch in the boot menu and to work. Prior, I did have my Monjaro at the top of the boot menu. After purging the mainline kernel as in 1 while in LM19, and the apparent auto updating of grub2, I still see Manjaro but it is now at the bottom. That makes me believe it was indeed the ubuntu grup2 that did the work. Yet I can still boot to the Arch distro.

Is the dogma now incorrect? Did the Arch grub actually get updated (while running LM19) even if it appears the grub version is ubuntu?

Code: Select all

grub-install --version
grub-install (GRUB) 2.02-2ubuntu8.3
Not a big deal but I like to know whats going on
comadore, pcDOS, hpux, solaris, vms-vax ....blah blah blah..
Yet I'm still a fn nooob

ajgringo619
Level 5
Level 5
Posts: 543
Joined: Thu Mar 01, 2018 8:36 pm
Location: San Diego, California

Re: why didn't I have to $ sudo update-grub2?

Post by ajgringo619 » Sat Aug 25, 2018 3:50 pm

Code: Select all

ls /usr/sbin/update-grub*
-rwxr-xr-x 1 root root  64 Jul 13 06:21 /usr/sbin/update-grub
lrwxrwxrwx 1 root root  11 Jul 13 06:21 /usr/sbin/update-grub2 -> update-grub
-rwxr-xr-x 1 root root 301 Mar 27  2015 /usr/sbin/update-grub-gfxpayload
Same difference...
[Mint 19 XFCE, AMD FX-8350 Eight-Core w/16 GB RAM, 4.15.0-42-generic, GeForce GTX 960 w/Nvidia 415.18]
Image

oldgranola
Level 3
Level 3
Posts: 187
Joined: Fri Sep 05, 2014 1:39 am

Re: why didn't I have to $ sudo update-grub2?

Post by oldgranola » Sat Aug 25, 2018 4:07 pm

Code: Select all

ls /usr/sbin/update-grub*
-rwxr-xr-x 1 root root 64 Jul 13 06:21 /usr/sbin/update-grub
lrwxrwxrwx 1 root root 11 Jul 13 06:21 /usr/sbin/update-grub2 -> update-grub
-rwxr-xr-x 1 root root 301 Mar 27 2015 /usr/sbin/update-grub-gfxpayload

Same difference...
Not sure how that answers the questions posed. Please elaborate
comadore, pcDOS, hpux, solaris, vms-vax ....blah blah blah..
Yet I'm still a fn nooob

gm10
Level 13
Level 13
Posts: 4543
Joined: Thu Jun 21, 2018 5:11 pm

Re: why didn't I have to $ sudo update-grub2?

Post by gm10 » Sat Aug 25, 2018 4:17 pm

1. The removal script includes update-grub and you needed to sudo the removal.
2. I have never heard of Ubuntu's GRUB package being unable to boot Arch so you probably just misunderstood something.
Last edited by gm10 on Sat Aug 25, 2018 4:19 pm, edited 1 time in total.

User avatar
Flemur
Level 16
Level 16
Posts: 6271
Joined: Mon Aug 20, 2012 9:41 pm
Location: Potemkin Village

Re: why didn't I have to $ sudo update-grub2?

Post by Flemur » Sat Aug 25, 2018 4:18 pm

oldgranola wrote:
Sat Aug 25, 2018 3:44 pm
I should have to

Code: Select all

sudo update-grub2
But I don't seem to have to. It appears to now be a part of the purge. Boot menu seems to already be updated. Cool. Did something change?
Removing a kernel has always resulted in a an updated grub menu as far as I know.
that updating debian/ubuntu/mint grub will wipe out the Arch grub and one must go back to the arch live install media, chroot, mount to the arch install and repair its grub to have arch in the boot menu and to work.
Depends what you mean by "updating" - "update-grub" won't wipe out another grub install, it just updates your grub.cfg menu. "grub-install" will wipe out another OSs grub MBR.
Prior, I did have my Monjaro at the top of the boot menu. After purging the mainline kernel as in 1 while in LM19, and the apparent auto updating of grub2, I still see Manjaro but it is now at the bottom. That makes me believe it was indeed the ubuntu grup2 that did the work. Yet I can still boot to the Arch distro.
"update-grub" looks for the other OSs and adds them to the grub menu.
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
Mint 18.3 Xfce/fluxbox/pulse-less
Xubuntu 17.10/fluxbox/pulse-less

JeremyB
Level 19
Level 19
Posts: 9429
Joined: Fri Feb 21, 2014 8:17 am

Re: why didn't I have to $ sudo update-grub2?

Post by JeremyB » Sat Aug 25, 2018 4:28 pm

Because of the file /etc/kernel/postrm.d/zz-update-grub

oldgranola
Level 3
Level 3
Posts: 187
Joined: Fri Sep 05, 2014 1:39 am

Re: why didn't I have to $ sudo update-grub2?

Post by oldgranola » Sat Aug 25, 2018 6:18 pm

I see. Its only grub-install that does.
Here is a reference, one among many that arch needs its grub to be in charge.
https://ingbrief.wordpress.com/2018/04/ ... u-upgrade/
comadore, pcDOS, hpux, solaris, vms-vax ....blah blah blah..
Yet I'm still a fn nooob

Post Reply

Return to “Chat about Linux”