ubunutu grub-pc kickstart install
I'm trying to get Ubuntu 12.04 to install via a kickstart setup, and so far we are seeing two issues:
1) in a virtual machine (VirtualBox and VMware Fusion) if there is a network device present it fails to install grub.
2) in a physical (IBM x3755 from memory) if the installation is not of a physical medium (eg Virtual disk via IMM) it fails.
In both cases the problem is that the installer complains that grub failed to install to /target/ .
I've gotten to the stage that then doing
- an Alt+F2 to go to a console,
- chroot /target/ bash,
- update /etc/apt/sources.list
- apt-get update -y
- apt-get install grub-pc -y
This last step gets me to a dialog that then asks where I want to install grub to. I've since put these steps into the post install section of my kickstart configuration file. All this is fine up to the point where it would require interaction, which never appears to take place, which I assume either it fails silently or doesn't happen.
I've taken a general look at grub-pc's postinst script, but I don't see anything in the script that gives a means of configuring it via a command line argument or file on disk. However it does appear that once grub is setup, that the postinst script will deploy it to the same location again. So at this point, I'm going back to the interactive Alt-F2 , chroot and running `/var/lib/dpkg/info/grub-pc.postinst configure` and then selecting /dev/sda ...
Thus my question:
Is there a way to configure grub-pc from the command line to install to the MBR, and thus complete the setup completely non-interactively, via a kickstart configuration file?
Interesting .. I wasn't aware that Ubuntu had added kickstart support. Had you thought about trying expect ? .. another option (to allow user interaction) would be to switch terminals like so:
Ubuntu and kickstart, since at least 10.04:
I'll have a play with your suggestions. Thanks!
vmware esxi grub failed to install
When receiving the following error on VMware ESXi
"the grub-pc package failed to install into /target/"
for Ubuntu 12.04 we were able to resolve the issue
by disconnecting the network interface (Edit -> Settings)
before installing from the DVD .iso
The most recent grub package (downloaded from the network)
apparently causes the problem.
After booting from the installed OS add the following to /etc/network/interfaces
to enable dhcp:
iface eth0 inet dhcp
|All times are GMT -5. The time now is 01:16 PM.|