PDA

View Full Version : Preseed value for installing Grub on Ubuntu 14.04 unattended



phikapjames
April 29th, 2014, 03:40 PM
I had posted this in ask ubuntu with no luck, so I'm going to try here (sorry about two mediums). I'm running into issues installing grub using the preseed on an unattended installation. This has worked for us on 12.04 and 13.10 though. We currently have the two lines in the preseed file in regards to grub:


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

The problem is, while watching the failed installs through the serial console, we are hitting a section in the grub installation portion that shows:



┌──────────┤ [!!] Install the GRUB boot loader on a hard disk ├───────────┐

│ You need to make the newly installed system bootable, by installing
│ the GRUB boot loader on a bootable device. The usual way to do this
│ is to install GRUB on the master boot record of your first hard
│ drive. If you prefer, you can install GRUB elsewhere on the drive, or
│ to another drive, or even to a floppy.

│ The device should be specified as a device in /dev. Below are some
│ examples:
│ - "/dev/sda" will install GRUB to the master boot record of your
│ first
│ hard drive;
│ - "/dev/sda2" will use the second partition of your first hard
│ drive;

│ __________________________________________________ ___________________

│ <Go Back> <Continue>

└───────────────────────────────────────────────── ────────────────────────┘


Notice that this screen came up and that it doesn't even have a device path specified yet. In our case we can type in /dev/sda and it will work. If we don't type it in and just hit continue, the installation will proceed just fine, but after the reboot it does not have the correct grub2 bootloader installed.

I tried doing d-i grub-installer/bootdev string (hd0,0) with no luck already.

So, any idea what we should put into the preseed to tell it to install grub on the first MBR?

sire1
June 4th, 2014, 02:01 PM
This helped me: https://bugs.launchpad.net/ubuntu/+source/grub-installer/+bug/1012629/comments/5