PXEBoot/Diskless Client NFS Issue

Home » CentOS » PXEBoot/Diskless Client NFS Issue
CentOS 2 Comments

Hey CentOS list!

I’ve got an oddity with a diskless client setup that I suspect is the result of the initrd.img I’m using, or some parameter I’m unaware — or I
need to build my own initrd image (and could use some assistance on what has to be done in that department)

Testbed is defined as:

VM A:
ip: 192.168.250.10 with dhcp server, TFTP server, nfs server VM B:
pxeboot VM, with no local disk, bios set to pxe, same internal network as VM A
Early on in the boot cycle, it grabs a DHCP address of 192.168.250.100, with correct mask, gw etc from VM A

When I start the testbed setup:

On the master VM I see log messages with the NIC of the client getting an address, and successfully loading pxelinux.0, pxelinux.cfg/default, vmlinuz and initrd.img.

The PXE client on VM B boots up, downloads all the above images, unpacks and executes the inird image. I see drivers load and normal device registration for the nics just fine.

After the PXE client VM shows the nic has its link up, this is where things go wrong…

* The PXE client (that properly got an address in the 250 space to get its images) sends out a DHCP discover message as would be expected.
* VM A responds with an offer of the same 192.168.250.100 address that was used to load
* The PXE client comes back with a DHCPREQUEST for 192.168.85.128
* The DHCP server sends a DHCPNAK to the client, and offers the 250 address again.
* The client never responds and the image seems to ignore the NAK/OFFER
* Eventually the diskless client comes back with a dracut-initqueue message that (as a lease was not ACKed correctly reports) mount.nfs: Network is unreachable

IF however, I run the identical configuration I mention above changing the addresses from 192.168.250.x to the 192.168.85.x space to match the initrd image request, everything works fine and the diskless client boots up normally and I get a command prompt. This would seem to indicate that I’ve got an otherwise working setup.

The images I’ve always used for diskless boot are the ones prebuilt and posted on the CentOS mirrors site

2 thoughts on - PXEBoot/Diskless Client NFS Issue

  • John Cole wrote:

    If your diskless client has 2 NICs – could that be confusing things?

    You could try adding the line:

    IPAPPEND 2

    to your PXE config file – this will append the MAC address of the PXEboot NIC as an option to the boot cmdline to be used by dhclient when the OS boots

    No idea if this is the issue here …

    James Pearson

  • Thanks for the suggestion I did eliminate the second nic altogether and it didn’t seem to make a difference

    I’m guessing this is easily replicated for others… what I’m most unsure of is why the dhcp conversation isn’t “normal” — is it a NetworkManager conversation in the shipping image or an ISC client that runs? I’m just not experienced with how the in-memory image is built… I can investigate there if somebody can give me a clue on the image generation…

    Appreciate it!