Option 'No' at question 'Continue without installing GRUB?' does nothing. Forced to answer 'Yes'.

Bug #580408 reported by Sander Smeenk
150
This bug affects 28 people
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Invalid
High
Unassigned
Lucid
Fix Released
High
Colin Watson

Bug Description

Binary package hint: grub2

This bug is in the debconf screens of grub-pc.

During upgrades it asks 'You chose not to install GRUB to any devices. [ ... ] Continue without installing GRUB?' and offers two options: Yes or No. Answering 'No' does nothing and brings you back to the same screen which forces you to answer 'Yes' and continue upgrading (and manually installing / updating GRUB in the MBR of your disks).

It would be nice if answering 'No' in that screen brings you to a screen to select which devices to install GRUB to and disable the question in later upgrades.

SRU justification:

IMPACT: This was caused by the fact that there's a while loop around the code that asks the grub-pc/install_devices or grub-pc/install_devices_disks_changed question, in order that it can be asked again on failure, but the code that did upgrade analysis on the previous value of that question ran every time round the while loop instead of just once; plus, we failed to make sure that the question would be asked again on subsequent runs around the while loop. The above description is one possible symptom; the other major ones are that if disk device names changed on upgrade from Lucid or later (e.g. due to removing a removable device to which GRUB had been installed) then the wrong question will be asked second and subsequent times round the loop, and that on upgrades from Karmic the question may have the wrong defaults second and subsequent times round the loop. This can cause upgrades to get stuck in a loop unless you give a probably-undesirable answer to a question, at which point you have to use dpkg-reconfigure in a terminal to fix it.

DEVELOPMENT BRANCH: While I haven't uploaded this yet due to the Alpha-2 freeze, I've committed it to the Maverick branch for grub2 1.98+20100614-2ubuntu4: http://bazaar.launchpad.net/~ubuntu-core-dev/ubuntu/maverick/grub2/maverick/revision/1998

PATCH: The raw patch is quite large due to indentation changes (the result would have been much more confusing without those changes!). 'diff -bu' makes it much more readable, though: http://launchpadlibrarian.net/51174650/580408.patch

TEST CASE: Install Karmic on a two-disk system, run 'echo SET grub-pc/install_devices /dev/sda | sudo debconf-communicate' to arrange for initial conditions that trigger this bug, then upgrade to Lucid. The first time round the loop, uncheck all the boxes, and then answer "No" to "Continue without installing GRUB"; it should ask you the same question with a list of checkboxes again, and should have left all of them unchecked. Also try an upgrade from Lucid as released to this update on the same system, running 'echo SET grub-pc/install_devices /dev/hda | sudo debconf-communicate' before starting the upgrade; this should give you a dialog reading "The GRUB boot loader was previously installed to a disk that is no longer present ...", and again if you uncheck all the boxes you should get consistent behaviour the second time round the loop. You may be able to save time by testing this together with bug 576724.

REGRESSION POTENTIAL: As with bug 576724, upgrades or dpkg-reconfigure might break. I think this test case should exercise most of the possible problem cases, though.

ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: grub-pc 1.98-1ubuntu6
ProcVersionSignature: Ubuntu 2.6.32-21.32-server 2.6.32.11+drm33.2
Uname: Linux 2.6.32-21-server x86_64
Architecture: amd64
Date: Fri May 14 11:22:47 2010
InstallationMedia: Ubuntu-Server 10.04 LTS "Lucid Lynx" - Release amd64 (20100427)
ProcEnviron:
 LC_COLLATE=C
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/zsh
SourcePackage: grub2

Revision history for this message
Sander Smeenk (ubuntu-freshdot) wrote :
Colin Watson (cjwatson)
Changed in grub2 (Ubuntu):
status: New → Fix Committed
importance: Undecided → High
Changed in grub2 (Ubuntu Lucid):
importance: Undecided → High
assignee: nobody → Colin Watson (cjwatson)
status: New → Triaged
milestone: none → ubuntu-10.04.1
Changed in grub2 (Ubuntu):
assignee: nobody → Colin Watson (cjwatson)
Colin Watson (cjwatson)
Changed in grub2 (Ubuntu Lucid):
status: Triaged → In Progress
Revision history for this message
Colin Watson (cjwatson) wrote :
Colin Watson (cjwatson)
description: updated
description: updated
tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 1.98+20100614-2ubuntu4

---------------
grub2 (1.98+20100614-2ubuntu4) maverick; urgency=low

  * Rearrange postinst install_devices logic so that preparatory code is run
    only once and the while loop only encloses actual asking of questions,
    and so that the question being asked is always marked for redisplay when
    going round the while loop again (LP: #580408).
  * Only offer partitions containing /, /boot, or /boot/grub for
    grub-install; installing to other partitions may have harmful effects
    such as making Windows unbootable, and installing GRUB to every single
    partition is likely to result in confusion anyway (LP: #576724).
 -- Colin Watson <email address hidden> Thu, 01 Jul 2010 18:26:37 +0100

Changed in grub2 (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote : Please test proposed package

Accepted grub2 into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in grub2 (Ubuntu Lucid):
status: In Progress → Fix Committed
tags: added: verification-needed
Revision history for this message
Erick Brunzell (lbsolost) wrote :
Download full text (3.5 KiB)

Well, I think this looks good, but I'm going to be very specific (and unfortunately long winded) to be sure my testing meets your needs. If I did anything wrong I'll be glad to repeat the testing.

I began by installing Karmic on sdb3, maybe my labels will help:

lance@lance-desktop:~$ sudo blkid
/dev/sda1: LABEL="Maverick" UUID="b7a0df33-53e4-4f0d-856b-0da92ff0d743" SEC_TYPE="ext2" TYPE="ext3"
/dev/sda2: LABEL="Karmic" UUID="1332b9d0-cf18-4299-9094-12acbdac91ad" TYPE="ext3"
/dev/sda3: LABEL="Lucid" UUID="d252929b-949d-432e-a18c-18f9ae770d28" SEC_TYPE="ext2" TYPE="ext3"
/dev/sda5: LABEL="Backups" UUID="594c3d40-2791-4c0a-8644-d9812545da2d" TYPE="ext3"
/dev/sda6: LABEL="Pictures" UUID="8a3f6c83-cb52-4caf-96b8-5faf2c830453" TYPE="ext3"
/dev/sda7: LABEL="Downloads" UUID="05289ee4-d681-4806-b6fd-aefd784f9323" TYPE="ext3"
/dev/sda8: LABEL="Documents" UUID="571cfad8-68c7-4703-883e-c0baa2a381d4" TYPE="ext3"
/dev/sda9: UUID="80627269-1ccd-4774-b4ea-a5ef8824ffaa" TYPE="swap"
/dev/sda10: LABEL="Isadora" UUID="f223fe5d-3acb-4d96-950c-62661ad8714b" SEC_TYPE="ext2" TYPE="ext3"
/dev/sda11: LABEL="Squeeze" UUID="0eec2831-7805-437e-a06e-e18ab3268e6a" SEC_TYPE="ext2" TYPE="ext3"
/dev/sda12: UUID="f6062e12-09f1-4f19-b6c2-ad58812d6794" SEC_TYPE="ext2" TYPE="ext3"
/dev/sdb1: LABEL="Not used" UUID="e5b97883-9431-477e-bc71-a68db5c07cba" TYPE="ext2"
/dev/sdb3: LABEL="This test case" UUID="5f555613-01f8-4c98-acc3-ca123cd81b06" TYPE="ext4"
/dev/sdb5: UUID="8d9402a0-29a4-44c1-ab74-94e268865e8f" TYPE="swap"
/dev/sdb6: LABEL="Maverick" UUID="4ac10d96-7aea-44f4-a69e-5dfa2a992b44" TYPE="ext4"

You can see that everything is Debian/Ubuntu based. Does that matter? I can do this on a computer with Windows on one drive if needed.

While installing this Karmic I allowed it to install grub to /dev/sda since that's default (the /dev/sdb MBR was assigned to the Maverick on /dev/sdb6), then just after installation I ran the following command:

lance@lance-desktop:~$ echo SET grub-pc/install_devices /dev/sda | sudo debconf-communicate
0 value set
lance@lance-desktop:~$

Then I upgraded to Lucid. I did not first apply the Karmic updates!

When confronted with "configure grub-pc" I chose to install the maintainers version, then I got the typical screen asking where to install grub and only /dev/sda was checked. I unchecked it and went to the screen where it says, "Continue without installing grub?", and I left the box unchecked which took me back to the previous screen with no boxes checked. I finally chose to install to /dev/sda (where it originally was) and continued.

When prompted to restart I did so, rebooted successfully, then ran:

lance@lance-desktop:~$ echo SET grub-pc/install_devices /dev/hda | sudo debconf-communicate
[sudo] password for lance:
0 value set
lance@lance-desktop:~$

Then I upgraded grub-pc & grub-common from proposed. I was then confronted with the new behavior (showing only /dev/sda, /dev/sdb, and /dev/sdb3 as possible locations) The info: "The GRUB boot loader was previously installed to a disk that is no longer present ..." appears only with a "mouse-over" in notify-osd or if you click on Help so it's possible that warning could be missed...

Read more...

Revision history for this message
Colin Watson (cjwatson) wrote :

Thanks, Erick, this all matches what I expected to see. There's one more thing I'd like to make sure of, though; my fault for not being very clear in the test case. Could you try the karmic->lucid update test again, but this time go straight from karmic (as released is fine; the updates won't be relevant) to lucid-proposed, rather than going through the original released version in lucid?

Many thanks for your efforts - I appreciate that this is time-consuming.

Revision history for this message
Erick Brunzell (lbsolost) wrote :

@ Colin Watson,

That's no problem. So I'm thinking instead of upgrading through update-manager I could just change the sources.list via "sed -i 's/karmic/lucid/g' /etc/apt/sources.list", then check to be sure 'proposed' is not commented out, and then upgrade via terminal with 'apt-get update && apt-get dist-upgrade'. Would that do the trick?

I have read:

https://wiki.ubuntu.com/Testing/EnableProposed

But I'm still just a bit unclear how to go straight to proposed during a distribution upgrade.

My current "stable" Lucid has all the "proposed" updates installed anyway so I'm not concerned about parsing only the grub packages.

I'll go ahead and make a fresh install of Karmic now so I'll be ready when I see your reply. Sorry to be a pain.

Revision history for this message
Sander Smeenk (ubuntu-freshdot) wrote :

Great to see progress on this 'bug'.

For what it's worth, this is how i managed to produce the situation in the first place; i installed Lucid (server, amd64) in a VM. Installing Grub bailed out in the installer because of VirtIO weirdness and i had to select 'do not install any bootloader'. Then i manually installed Grub on the disk from the ALT-F3-console. Finished the installation-steps on the ALT-F1-console, rebooted, and ran an update which installed a new grub.

At the moment Grub was updated i encountered the 'bug'.

HTH, Thanks for all the hard work. Wish i had time to test it thoroughly for you too.

Revision history for this message
Erick Brunzell (lbsolost) wrote :

@ Colin Watson,

My greatest fear is that my ineptitude dealing with this bug will hold back the fix for #576724 which effected many, many more people. Most probably thousands!

I've tried the new version many different ways, but trying the old version I was never able to reproduce the abhorrent behavior described here. Even trying "echo SET grub-pc/install_devices /dev/ohdearnosuchdevice | sudo debconf-communicate" i never could reproduce the problem, or even get "The GRUB boot loader was previously installed to a disk that is no longer present ...".

Now, I never did try my box with Windows on it but I think you said that wasn't necessary. Reading Flour's explanation I'm certainly not able to duplicate that behavior because I've never used the server version nor do I understand using a VM.

IMHO it would be a bloody shame to hold back this fix for #576724 because of a corner issue like this. I most recently tried this only upgrading the grub-pc and grub-common packages in Karmic to the new Lucid packages numerous ways and finally with a full upgrade.

I should be able to leave that installation in tact until I need to do iso and/or upgrade testing again.

I really want to see this update move from proposed to recommended :^)

If I can do anything to facilitate that just tell me, but be very detailed and I'll comply.

Revision history for this message
Colin Watson (cjwatson) wrote :

I tested the last little bit of this myself, since it was easier than explaining the horribly convoluted method. :-) In conjunction with your testing, everything looks fine to my eye. Thanks for your work - I'll mark this as verification-done now.

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 1.98-1ubuntu7

---------------
grub2 (1.98-1ubuntu7) lucid-proposed; urgency=low

  * Update harmfully incorrect German translation of menu legend, which
    omitted mention of pressing Ctrl-x to boot (LP: #580178).
  * Rearrange postinst install_devices logic so that preparatory code is run
    only once and the while loop only encloses actual asking of questions,
    and so that the question being asked is always marked for redisplay when
    going round the while loop again (LP: #580408).
  * Only offer partitions containing /, /boot, or /boot/grub for
    grub-install; installing to other partitions may have harmful effects
    such as making Windows unbootable, and installing GRUB to every single
    partition is likely to result in confusion anyway (LP: #576724).
 -- Colin Watson <email address hidden> Wed, 30 Jun 2010 14:37:47 +0100

Changed in grub2 (Ubuntu Lucid):
status: Fix Committed → Fix Released
Revision history for this message
Brad Clarke (brad-bradclarke) wrote :

I get stuck in the same loop when doing the upgrade to 1.98-1ubuntu7. System is a simple VM with 10.04 Server 64bit, all in one partition

Revision history for this message
Sander Smeenk (ubuntu-freshdot) wrote :

Bug is fixed for me. On upgrade it now prompts me 'GRUB has been installed to a device that is no longer present', after which i get a list of devices to install GRUB to. Thanks!

Revision history for this message
Frederik Elwert (frederik-elwert) wrote :

I can confirm Brad Clarke’s observation: When doing the upgrade on 10.04 Server 64bit in a virtual machine, I’m also stuck in that loop.

I actually don’t know why I’m asked that question at all, because I chose to install grub to the MBR during installation. So why doesn’t grub just update the installation?

Revision history for this message
Frederik Elwert (frederik-elwert) wrote :

Another observation: When choosing “Yes”, when generating the grub.cfg and after the “Found xy” messages, I get “File descriptor 3 (pipe:[84304]) leaked on lvs invocation. Parent PID 28677: /bin/sh”. Maybe that’s related?

Revision history for this message
Marc Kiefer (m-kiefer) wrote :

I can also confirm this bug still exists (or again?) on a 10.04 32 bit virtual machine. I can't choose "no". Is there a workaround for this? I didn't even choose anything before this dialogue appeared.

Revision history for this message
Brad Clarke (user-bradclarke) wrote :

This is happening again when upgrading to 1.98-1ubuntu8

Revision history for this message
Brian Candler (b-candler) wrote :
Download full text (4.2 KiB)

This bug still exists in Lucid; I've had it on two separate Lucid Server VMs (the first is i386 running under VMware Server 1.x/RHEL4; the second is x86_64 running under KVM/Karmic)

The problem was triggered by a simple upgrade, which pulled in a new versions of grub-common and grub-pc. Here's the full transcript of when it happened the second time:

$ sudo apt-get dist-upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following NEW packages will be installed
  linux-image-2.6.32-26-virtual
The following packages will be upgraded:
  grub-common grub-pc linux-image-virtual linux-virtual
4 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 14.7MB of archives.
After this operation, 36.0MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get: 1 http://gb.archive.ubuntu.com/ubuntu/ lucid-updates/main linux-image-2.6.32-26-virtual 2.6.32-26.47 [12.5MB]
Get: 2 http://gb.archive.ubuntu.com/ubuntu/ lucid-updates/main grub-pc 1.98-1ubuntu8 [650kB]
Get: 3 http://gb.archive.ubuntu.com/ubuntu/ lucid-updates/main grub-common 1.98-1ubuntu8 [1,540kB]
Get: 4 http://gb.archive.ubuntu.com/ubuntu/ lucid-updates/main linux-virtual 2.6.32.26.28 [4,150B]
Get: 5 http://gb.archive.ubuntu.com/ubuntu/ lucid-updates/main linux-image-virtual 2.6.32.26.28 [4,160B]
Fetched 14.7MB in 19s (758kB/s)
Preconfiguring packages ...
Selecting previously deselected package linux-image-2.6.32-26-virtual.
(Reading database ... 17623 files and directories currently installed.)
Unpacking linux-image-2.6.32-26-virtual (from .../linux-image-2.6.32-26-virtual_2.6.32-26.47_amd64.deb) ...
Done.
Preparing to replace grub-pc 1.98-1ubuntu7 (using .../grub-pc_1.98-1ubuntu8_amd64.deb) ...
Unpacking replacement grub-pc ...
Preparing to replace grub-common 1.98-1ubuntu7 (using .../grub-common_1.98-1ubuntu8_amd64.deb) ...
Unpacking replacement grub-common ...
Preparing to replace linux-virtual 2.6.32.25.27 (using .../linux-virtual_2.6.32.26.28_amd64.deb) ...
Unpacking replacement linux-virtual ...
Preparing to replace linux-image-virtual 2.6.32.25.27 (using .../linux-image-virtual_2.6.32.26.28_amd64.deb) ...
Unpacking replacement linux-image-virtual ...
Processing triggers for man-db ...
Processing triggers for ureadahead ...
ureadahead will be reprofiled on next reboot
Setting up linux-image-2.6.32-26-virtual (2.6.32-26.47) ...
Running depmod.
update-initramfs: Generating /boot/initrd.img-2.6.32-26-server
Running postinst hook script /usr/sbin/update-grub.
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-26-server
Found initrd image: /boot/initrd.img-2.6.32-26-server
Found linux image: /boot/vmlinuz-2.6.32-25-server
Found initrd image: /boot/initrd.img-2.6.32-25-server
Found linux image: /boot/vmlinuz-2.6.32-24-server
Found initrd image: /boot/initrd.img-2.6.32-24-server
done

Setting up grub-common (1.98-1ubuntu8) ...

Setting up grub-pc (1.98-1ubuntu8) ...

***
At this point, the dialog box came up:
--------------------------------------------------------------
You chose not to install GRUB to any device....

Read more...

Revision history for this message
Andy Brody (abrody) wrote :

Hit this bug just now in a 64-bit virtual machine.

Revision history for this message
GaryParr (gary-garyparr) wrote :

Just happened to me on 2 64 bit Lucid KVM machines on a Lucid 64 bit host, complete with that leaking file descriptor on lvs invocation on a dpkg-reconfigure.

Revision history for this message
GaryParr (gary-garyparr) wrote :

Didn't happen on the host system though...

Revision history for this message
ubuntu_demon (ubuntu-demon) wrote :

It just happened to me on 2 64 bit Lucid virtual machines on ESX. I answered YES. Ran update-grub to be sure and gave them a reboot. They booted fine.

Revision history for this message
Sander Smeenk (ubuntu-freshdot) wrote :

During a maintenancerun this morning, a large portion of my servers promped to install grub to disks, but a few of them still suffered from the "can't answer 'no'"-bug, so i was forced to answer 'yes' to the question and not install / update the MBR.

Revision history for this message
Michael Evans (mjevans1983) wrote :

Do I need to file a regression against 1.98-1ubuntu9 for Lucid 10.04 LTS? These precise symptoms are occurring again.

Revision history for this message
Michael Evans (mjevans1983) wrote :

I downloaded and installed grub-pc_1.99~20101126-1ubuntu3_amd64.deb 03-Dec-2010 06:05 872K (along with grub-common same version) and the problem is fixed in that version.

Revision history for this message
Richard Laager (rlaager) wrote :

I have grub-pc version 1.98-1ubuntu9 installed and this is still a problem (on multiple servers). It seems that grub-pc/install_devices is set to the empty set.

This fixes it for me, without changing anything on systems that are not affected:
if sudo debconf-show grub-pc | grep -q "install_devices:$" ; then echo SET grub-pc/install_devices `mount | grep "on / " | cut -d' ' -f1 | sed "s|[0-9]\+$||"` | sudo debconf-communicate && sudo dpkg-reconfigure -fnoninteractive grub-pc ; fi

TO THOSE LOOKING FOR A MAGICAL FIX: THIS COMMAND IS ONLY SAFE IF YOU WANT TO INSTALL GRUB ON THE DEVICE THAT HOLDS THE PARTITION FOR / AND EVEN THEN, IT MAY BE UNSAFE IN VARIOUS CIRCUMSTANCES. IF YOU ARE GOING TO BLINDLY COPY-AND-PASTE, DON'T BLAME ME FOR BREAKAGE.

Revision history for this message
Richard Laager (rlaager) wrote :

Whoops, in my haste to add the warning, I forgot some potentially useful debugging information...

The systems that work have grub-pc/install_devices set to a path under /dev/disk/by-id. On the systems that don't work, the /dev/disk/by-id directory doesn't contain anything for the hard drive. One has a USB drive only; the rest have no /dev/disk/by-id directory at all.

Revision history for this message
Jamin W. Collins (jcollins) wrote :

I just encountered this upon upgrading a 10.04 64bit VM. Like Richard, I found that grub-pc/install_devices was empty. Following his suggestions and setting a value for this debconf field does indeed fix it. Perhaps an upgrade should check this field and if empty prompt for a value?

Revision history for this message
Martin Steigerwald (ms-proact) wrote :

I found this during upgrading our Zimbra server from Ubuntu 8.04 LTS to 10.04 LTS with

root@zimbra:~# dpkg -l | grep grub-pc
ii grub-pc 1.98-1ubuntu10[...]

So this bug is not fixed completely, one year after release of a long term support edition of Ubuntu and almost one year after reporting it. This makes me wonder, cause I assumed that Ubuntu LTS 10.04 was supposed to be a stabler branch of Ubuntu.

Manual work around I applied:

root@zimbra:~# debconf-show grub-pc
  grub-pc/kopt_extracted: true
  grub2/kfreebsd_cmdline:
* grub-pc/install_devices:
  grub-pc/postrm_purge_boot_grub: false
  grub-pc/disk_description:
* grub2/linux_cmdline:
* grub-pc/install_devices_empty: true
  grub2/kfreebsd_cmdline_default: quiet
  grub-pc/partition_description:
  grub-pc/install_devices_failed: false
  grub-pc/install_devices_disks_changed:
* grub2/linux_cmdline_default: quiet splash
* grub-pc/chainload_from_menu.lst: true
  grub-pc/hidden_timeout: true
  grub-pc/timeout: 3

root@zimbra:~# echo get grub-pc/install_devices | debconf-communicate
0

install_devices is not set, debconf *should* ask.

Set the value - adapt device name as needed for your setup.

root@zimbra:~# echo set grub-pc/install_devices /dev/sda | debconf-communicate
0 value set

Verify that it is set:

root@zimbra:~# echo get grub-pc/install_devices | debconf-communicate
0 /dev/sda

root@zimbra:~# dpkg-reconfigure grub-pc
[...]
Installation finished. No error reported.
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-31-server
Found initrd image: /boot/initrd.img-2.6.32-31-server
Found linux image: /boot/vmlinuz-2.6.24-29-server
Found initrd image: /boot/initrd.img-2.6.24-29-server
Found memtest86+ image: /boot/memtest86+.bin
done

Of course, grub-install /dev/sda should do the same job manually.

I never seen something like this in any version of debian stable.

Revision history for this message
Martin Steigerwald (ms-proact) wrote :

IMHO the debconf process should differentiate:

- the user never answered the on which device(s) to install question
  => ask

- the user chose not to install grub
  => inform the user by the "You chose not to install GRUB" dialog and let him choose to install grub nonetheless now

- the user already chose where to install grub
  => do it

This should work on a new installation as well as on an upgrade from GRUB 1.

Revision history for this message
Brad Clarke (brad-bradclarke) wrote :

I built two virtual machines a couple of weeks ago from the 10.04.2 server iso and fully updated them. The most recent update of grub (1.98-1ubuntu12) caused this problem again when they updated. I also saw it on about 25% of my other VMs, so it is not isolated to new installs.

This bug needs to be reopened.

Revision history for this message
Oli Wade (olithered) wrote :

I experienced this today upgrading an ESX VM.

Revision history for this message
Jeff Harris (lo-aeif-h6) wrote :

This is still happening today, September 12th, 2011.

I did this to fix it, as suggested above, with sudo, as my disk is /dev/sda

echo set grub-pc/install_devices /dev/sda | sudo debconf-communicate
sudo dpkg-reconfigure grub-pc

tags: added: testcase
Revision history for this message
Christian Hintze (hintze) wrote :

this bug occured to me right now with grub-pc version 1.98-1ubuntu13.

Revision history for this message
Helmut (debesh) wrote :

Just experienced this bug when updating a Ubuntu 10.04.3 LTS server to grub-pc (1.98-1ubuntu13). Before finding myself in the endless loop when answering 'No' at question 'Continue without installing GRUB?' I was prompted by another screen asking me what to do regarding the modified /etc/default/grub file, where I have chosen to install the maintainer's version and then I reapplied my changes (and ran update-grub).

Anyway, answering 'Yes' to get out of the otherwise endless 'Continue without installing GRUB?' loop, did not seem to have any adverse effect and the system booted properly.

Right after that I updated another server, which I thought to be pretty similar. Surprisingly I was not prompted about what to do with the changed /etc/default/grub file and was also not prompted with the 'Continue without installing GRUB?' question. I can only speculate as to why I was not prompted: I already had 'GRUB_CMDLINE_LINUX_DEFAULT="noquiet nosplash"' and no surrounding comments like on the other server ... just guessing here.

This bug has not been fixed.

Revision history for this message
SeanBoran (sean-boran) wrote :

I too got hit by this today which doing regular patching on Ubuntu 10.04
apt-get update || apt-get upgrade
No could not be selected, and luckily as in #35, selecting Yes did not have any adverse effects.

Revision history for this message
MarcRandolph (mrand) wrote :

This is easily reproducible with a VM (install 10.04 and then do the 10.04 updates).

Changed in grub2 (Ubuntu):
status: Fix Released → Triaged
Revision history for this message
Daniel Drucker (dmd-c) wrote :

This is still happening in Ubuntu 12.04 LTS.

With the following lines in preseed:

d-i grub-installer/only_debian boolean true
d-i grub-installer/with_other_os boolean true

it still prompts that grub was not installed.

Revision history for this message
Tamlin (storyjesse-gmail) wrote :

This error is still not fixed in grub-pc:i386 (1.99-21ubuntu3.1, 1.99-21ubuntu3.4)

I use Ubuntu 12.04 LTS and today did a routine "Update Manager" (gui) package update/upgrade

I was presented with the grup-pc window asking me where to install grub and given three options:
- /dev/sda [SSD drive]
- - /dev/sda1 [root partition]
- /dev/dsb [External HDD]

I selected /dev/sda and clicked 'forward'

I was then shown a window with a check box labeled "Continue without installing grub"
Investigating the "help" button revealed a message saying the I had not chosen to install grub anywhere and that this may lead to incompatibility problems on reboot.

Clicking continue (without checking the box labeled "Continue without installing grub") sent me back to the grub-pc window asking me where to install grub. /dev/sda was STILL CHECKED!

After investigating online I went to the command line and did "sudo grub-install /dev/sda" which resulted in "Installation finished. No error reported."
I then went back to the grub-pc window left /dev/sda checked and clicked 'forward' then I checked the "Continue without installing grub" box and clicked 'forward'.

The rest of the update manager process continued as expected.

These are very alarming questions to ask a novice Ubuntu user who has installed via a live CD. Fortunately for me I have heard of grub and understand what it's for, but that little knowledge means that I also know that if I screw up grub, my system won't boot!! As this is my ONLY computer, issues with grub are extremely important.

I don't have the skills to assist but I thank those who are working to fix this.

Colin Watson (cjwatson)
Changed in grub2 (Ubuntu):
assignee: Colin Watson (cjwatson) → nobody
Revision history for this message
Michel-Ekimia (michel.ekimia) wrote :

This bug is back with a 14.04.2 fresh install and updates , I don't get why this appears !

This should be a high priority bug, it scares everybody and create a lot of support calls .

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

This release of Ubuntu is no longer receiving maintenance updates. If this is still an issue on a maintained version of Ubuntu please let us know.

Changed in grub2 (Ubuntu):
status: Triaged → Incomplete
Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

This issue has sat incomplete for more than 60 days now. I'm going to close it as invalid. Please feel free re-open if this is still an issue for you. Thank you.

Changed in grub2 (Ubuntu):
status: Incomplete → Invalid
Revision history for this message
Daniel Alonso (eldanialonso) wrote :

I got same behavior during a "Software Updater" session.
A window with "shim-signed" title lists "GRUB install devices", from there I pick /dev/sda1, then after clicking "Next" button comes next checkbox "Continue without installing GRUB?", and there if I keep as "no" it goes back to first screen. The only way to "finish" the process is by selecting the "Continue without installing GRUB?" checkbox in second screen.

Revision history for this message
Daniel Alonso (eldanialonso) wrote :

Sorry I forgot to add my current version:

$ cat /etc/os-release
NAME="Ubuntu"
VERSION="20.04.2 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.2 LTS"
VERSION_ID="20.04"

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.