installing two kernels in a single machine booting with lilo
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
installing two kernels in a single machine booting with lilo
I am trying to add a kernel to my ubuntu 12.04.I have a kernel version of 3.2.x.x and now I want to add kernel 3.0.x.x with out affecting the one working perfectly. But the thing is in am getting this different ideas from different sites and I don know which one to use.Is there any one who could guide me or point me to a correct reading material?
Simple enough - I do it all the time. Make sure CONFIG_LOCAL_VERSION is set to a different setting.
Then you end up with 2 module trees, 2 kernels, and one root drive. The module trees will be in
/lib/modules/<kernel version><local_version> e.g. 3.2.29-mine
Then rename each to the <kernel version><local_version> e.g. vmlinuz-3.2.29-mine & System.map-3.2.29-mine.
Ok that is solved thanks.Now the problem is my system boots properly with my old kernel but when i try to boot from the new kernel i get
mount:mounting /dev on /root/dev failed:no such file or directory
mount:mounting /sys on /root/sys failed:no such file or directory
mount:mounting /proc on /root/proc failed:no such file or directory
target filesystem doesn't have requested /sbin/init
No init found.try passing init=bootarg
i can not do any thing .how do i lose this (initramfs) prompt?
It strikes me you have left out some fundamental piece of the jigsaw.
You need tmpfs, fuse filesystem, & your own hard disk filesystem compiled into the kernel.
Without tmpfs & a /dev/ directory, the system cannot mount the device tree on /dev so no devices get made. This is the setup from my 3.7.1 kernel, which works with no initrd.
bash-4.2$ grep -ne 'FUSE' -e 'TMPFS' -e 'EXT4' .config
3404:# CONFIG_EXT4_DEBUG is not set
3470:# CONFIG_TMPFS_POSIX_ACL is not set
In my case, I was installing in a VM using virtual disks for speed (the vda driver). I had to tell the mkinitrd the root device (/dev/vda3) and include the driver modules (ext4 for root, virtio* for the disk).
No need to have them compiled into the kernel, though that would work too.
Modules are all that are needed - and this makes it easier to update the drivers without having to rebuild the kernel.
Thank you all for your replays.Could any one please explain to me what you are saying.As i am new to this thing i am kind of confused to what you are trying to tell me.I have installed the other kernel,at list i think i do,using this site "file:///media/6824BB7F24BB4F36/pdf/fork/kernel/kernel-compile.html".I can boot my system using the original kernel but not able with the newly installed one.So how do i make the things that you are suggesting by booting from the other kernel.And could you please be a little clear about what you are telling me because i am new.
First it is interesting that you are using Ubuntu which in turn uses Lilo? I thought that Ubuntu uses Grub or something else? But if there is indeed Lilo, then you need to configure lilo to have an entry for the second kernel, then rerun lilo, so that all the things are set up for you, reboot and if the kernel is good, then you are good to go.
First step is to configure Lilo. You need to find the lilo config file, so go and see, if there is a file called /etc/lilo.conf and if so, please post the contents of that file into this thread. Then we can guide you further.
I did all that it works just fine for the originally installed kernel.But i had to install and configure additional kernel and boot with any of the kernels.I tried to install and configure the additional kernel.Yes i did update the lilo.conf file.Lilo lets me choose from the two kernels.But the problem is with the last installed kernel it doesn't finish booting it stacks giving mi the above error messages.
I am new to the forum
As I am installing new kernel 3.7.1. on my Ubuntu 12.04
in /boot folder when I run mkinitrd -o initrd.img-3.7.1 3.7.1 it says command not found
but I can see initrd.img-3.7.1 file in /boot folder
You need to show the command and the errors (put them in a code block for formatting). We can't tell what your error may be associated with. mkinitrd is actually a shell script, so there may be something missing for it to work.
as there was error in running mkinitrd -o initrd.img-3.7.1. 3.7.1 I just updated grub without running mkinitrd command
and the kernel 3.7.1 is running efficeintly.
As I am new could plz tell me what is the basic need for running mkinitrd command and what if I didnt use it