Skip to content

October 11, 2013

Installing new kernel within Linux kickstart

by Joe Kuan

I have to build a Ubuntu installer ISO using the kickstart utility but I need the installer to install a particular version of kernel. Here is the link for a quick guide on setting up Ubuntu kickstart. First, I added the following line into %packages section in the installer build script to install the target kernel package, ks.cfg:

@ ubuntu-server

But this produces a boot error with kernel panic from the new installed Ubuntu system.

kernel panic-not syncing: VFS: unable to mount root fs on
unknown block(0,0)

This is because the grub update for the default kernel hasn’t been performed yet during the %packages stage (The grub update is performed after %packages and before the %post stages). So the kernel update should be placed within the post installation stage. This will resolve the above boot error.

%post --interpreter /bin/bash
dpkg -i /media/cdrom/pool/extras/linux-image-3.5.0-39-generic_3.5.0-39.60_amd64.deb

The above dpkg line is basically to install the kernel image package file pre-packed inside the installer ISO. So that the installer can work straight offline. For details on how to create an installer ISO with pre-packed packges, see this link.

Read more from Operating System, Ubuntu

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

Note: HTML is allowed. Your email address will never be published.

Subscribe to comments

%d bloggers like this: