[SATLUG] diskless ramdisk booting

Borries Demeler demeler at biochem.uthscsa.edu
Thu Jul 21 11:41:50 CDT 2016


On Thu, Jul 21, 2016 at 03:55:03PM +0000, Igor Gueths wrote:
> Hello,
> based on your initial description of the problem, it sounds as though the kernel is panicking because it cannot find the root filesystem. That being said, at a high level diskless booting works something like this (assuming of course you are in fact PXE booting):
> ???BIOS passes control to Eprom on the NIC.
> ???Boot loader on Eprom attempts to get an IP via DHCP, paying special attention to the TFTP-related DHCP options to determine where its TFTP server is.
> ???Kernel is downloaded from TFTP server, decompressed and executed.

Yes, that's exactly how far we get with the pxe boot. 

> I unfortunately do not recall if one has to hardcode NFS mount points and such into the kernel image, or if as part of passing control to the kernel a separate config file gets downloaded from which further boot options are passed to the kernel. That being said, I would check to see what sort of message (s) you are getting at boot time when the failure occurs and go from there. Hope this helps, and good luck.

Our first try is to boot a small self-contained initramfs we built by hand that has a 
init script as well as busybox built into it. The nsf mount points can be put into /etc/fstab
on the ram image and can be loaded as long as the kernel supports nfs. When we boot an
image from, say CentOS installation media, this part works perfectly well, and we can  
access nfs mounted dirs just fine, but our own initramfs doesn't seem to work, or 
maybe it is the init.

-b.


> > On Jul 21, 2016, at 8:53 AM, Borries Demeler <demeler at biochem.uthscsa.edu> wrote:
> > 
> > I am hoping someone on this list can explain how diskless booting works.
> > 
> > I have a bunch of high school kids in my lab this summer and we are
> > trying to build a diskless linux cluster as a summer project. I have a
> > bunch of generic boxes with quad-core processors, on board video and 8
> > GB RAM each. We configured one of the boxes with CentOS 6.8 as a head
> > node. It has dhcpd, tftpd, nfs working fine now.  We can successfully
> > pxe boot various iso images served through the tftp server, the nodes
> > get private IP addresses, tftp boot the kernels and ramdisks on the iso
> > images, and the nodes can mount nfs shared volumes from the head node.
> > All of this works fine.
> > 
> > We now wanted to build our own custom image and wanted to compile a 
> > minimal kernel and build a minimal ramdisk on which we could nfs mount
> > various shares that hold the software and home directories we want to have
> > accessible on the slave nodes.
> > 
> > But we so far have been unable to build a proper kernel or ramdisk that
> > gets past the mounting point where the root ramdisk file system gets 
> > mounted and cannot figure out where we are going wrong. Any help would
> > be appreciated. We tried to follow this guide to the T:
> > 
> > http://eduardo-lago.blogspot.com/2012/06/ram-only-pxe-boot-smallest-diskless.html
> > 
> > and searched the internet for all kinds of other documentation on the topic.
> > But we must be missing something essential, like our init is not getting 
> > executed or the kernel cannot find the root file system.
> > 
> > Any help for these kids would be greatly appreciated! Can someone explain
> > how the boot process works exactly step-by-step so we can see where our
> > newly built image might be failing? THe boot process always fails at the
> > point where the initrd specified ramdisk does not mount root.
> > 
> > Thanks, -Borries
> > -- 
> > _______________________________________________
> > SATLUG mailing list
> > SATLUG at satlug.org
> > http://alamo.satlug.org/mailman/listinfo/satlug to manage/unsubscribe
> > Powered by Rackspace (www.rackspace.com)
> 

> -- 
> _______________________________________________
> SATLUG mailing list
> SATLUG at satlug.org
> http://alamo.satlug.org/mailman/listinfo/satlug to manage/unsubscribe
> Powered by Rackspace (www.rackspace.com)



More information about the SATLUG mailing list