CentOS LiveCD boot via PXE fails with kernel panic

General support questions

CentOS LiveCD boot via PXE fails with kernel panic

Postby blackest » 2012/06/15 07:07:50

Hello,
I'm new to the forum, started using CentOS as a RH clone.
As there are some booting restrictions in my company (boot from HD or network only) I decided to boot clients from PXE server, which is Centos 6.2 :) System I want to boot via pxe is centos livecd.

DHCPD is working (set for static in order not to mess with dhcp within company network), tftpd is working. Client is given the IP, then is downloads vmlinuz and initrd files and starts booting.
Booting fails on kernel panic:
Code: Select all
dracut Warning: No root device "block:/dev/ram0" found
dracut Warning: Boot has failed. To debug this issue add "rdshell" to the kernel command line.
dracut Warning: Signal caught!
dracut Warning: Boot has failed. To debug this issue add "rdshell" to the kernel command line.
Kernel panic - not syncing: Attempted to kill init!


It's obvius that there is a problem with root device that is configured not correctly. My current /tftpboot/pxelinux.cfg/default entries for CentOS:
Code: Select all
LABEL CentOS-Live
MENU LABEL CentOS Live
KERNEL images/centos_live/vmlinuz0 rdshell
APPEND initrd=images/centos_live/initrd0.img boot=live fetch=tftp://10.154.40.213/images/centos_live/squashfs.img root=/dev/ram0 ramdisk_size=9466178 ip=dhcp


Note, as instructed in kernel panic message, I added rdshell to the KERNEL command. System booted into dracut prompt, from where I found out there is no /dev/ram0 device.

My questions:
1. I'm missing something (besides /dev/ram0) in PXE default config file, can somebody point me what is missing in order to boot centos livecd ?
2. I'm able to boot Clonezilla, but this goes without root parameter. How can I determine the most suitable root device on client

Thanks in advance for tips.

BR :)
b.
blackest
 
Posts: 5
Joined: 2012/06/15 06:39:56

CentOS LiveCD boot via PXE fails with kernel panic

Postby pschaff » 2012/06/15 19:14:01

Welcome to the CentOS fora. Please see the recommended reading for new users linked in my signature.

Assuming the process is similar to that for CentOS-5 LiveCD you need to use livecd-iso-to-pxeboot from livecd-tools (available from EPEL) to create an initial RAM disk containing the LiveCD image.
pschaff
Retired Moderator
 
Posts: 18277
Joined: 2006/12/13 20:15:34
Location: Tidewater, Virginia, North America

Re: CentOS LiveCD boot via PXE fails with kernel panic

Postby blackest » 2012/06/18 12:00:40

Thanks for response.
I managed to install livecd-tools. It generated an 690Mb of initrd file from centos LiveCD. Then I booted client and got this message:
Code: Select all
initrd too large to handle, disabling initrd
pci 0000:05:00.0: BAR 0: no parent found for of devide [...]
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)

This is a bit strange, required RAM would be around 1,4Gb, while client has 3Gb of RAM.

So, back to my original question:
what options shall I place in pxelinux.cfg/default file to have the CentOS livecd booted via PXE ?
blackest
 
Posts: 5
Joined: 2012/06/15 06:39:56

Re: CentOS LiveCD boot via PXE fails with kernel panic

Postby pschaff » 2012/06/18 15:01:55

Don't know if it is the problem, but CentOS-6 dracut normally uses initramfs and not initrd,
pschaff
Retired Moderator
 
Posts: 18277
Joined: 2006/12/13 20:15:34
Location: Tidewater, Virginia, North America

Re: CentOS LiveCD boot via PXE fails with kernel panic

Postby Sekm » 2014/04/15 01:52:19

Hi there, I had the same error
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)


I was using a 1.2GB .img file (generated from the iso-to-pxe script off the livecd, and 2GB of ram. Upon moving the client to 3GB of ram the kernel panic left and the pxe live cd boot worked :D
Sekm
 
Posts: 1
Joined: 2014/04/15 01:49:30


Return to CentOS 6 - General Support

Who is online

Users browsing this forum: emmr.rida and 10 guests