0

I've installed a new Cobbler server and configured it as a DHCP /TFTP server. I've configured the /etc/dhcp/dhcpd.conf like so:

[root@centolel ~]# cat /etc/dhcp/dhcpd.conf 
ddns-update-style interim;
allow booting;
allow bootp;

ignore client-updates;
set vendorclass = option vendor-class-identifier;
option boot-server code 66 = string;
option option-66 code 66 = text;
option pxe-system-type code 93 = unsigned integer 16;
authorative;
subnet 10.13.0.0 netmask 255.255.255.0 {
     option routers             10.13.0.138;
     option domain-name-servers 10.13.0.1;
     option subnet-mask         255.255.255.0;
     range dynamic-bootp        10.13.0.20 10.13.0.150;
     default-lease-time         3600;
     max-lease-time             3600;
     next-server                10.13.0.1;
     class "pxeclients" {
          match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";
          if option pxe-system-type = 00:02 {
                  filename "ia64/elilo.efi";
          } else if option pxe-system-type = 00:06 {
                  filename "grub/grub-x86.efi";
          } else if option pxe-system-type = 00:07 {
                  filename "grub/grub-x86_64.efi";
          } else {
                  filename "pxelinux.0";
          }
     }

}

I've created a new virtual machine and configured it to boot from network.

The idea is that cobbler (dhcp) will offer an IP address to the newly created virtual machine and will issue the installation of CentOS 6.

When I reboot the newly created virtual machine, I see the following lines:

gPXE 0.9.7 -- Open Source Boot Firmware....
net0: 52:54:00:41:a7:91 on PCI00:03.0 (open)
  [Link:up, TX:0 TXE:0 RX:0 RXE:0]
Waiting for link-up on net0... ok
DHCP (net0 52:54:00:41:a7:91)... ok
net0: 10.13.0.19/255.255.255.0 gw 10.13.0.138
No filename or root path specified
No more network devices

Booting from Hard Disk...
Boot failed: not a bootable disk
.
.
.

As you can see it receives an IP which is not included in the "dynamic-bootp" range... 10.13.0.19 while the range begins at 10.13.0.20.

While looking at /var/log/messages of the Cobbler server just after rebooting the virtual machine, I see this:

Jun 29 18:52:07 localhost dhcpd: DHCPDISCOVER from 52:54:00:41:a7:91 via br0
Jun 29 18:52:08 localhost dhcpd: DHCPOFFER on 10.13.0.101 to 52:54:00:41:a7:91 via br0
Jun 29 18:52:08 localhost dhcpd: DHCPDISCOVER from 52:54:00:41:a7:91 via br0
Jun 29 18:52:08 localhost dhcpd: DHCPOFFER on 10.13.0.101 to 52:54:00:41:a7:91 via br0
Jun 29 18:52:10 localhost dhcpd: DHCPREQUEST for 10.13.0.19 (10.13.0.138) from 52:54:00:41:a7:91 via br0: unknown lease 10.13.0.19.
Jun 29 18:52:13 localhost kernel: br0: port 2(vnet0) entering forwarding state

The contents of /var/lib/tftpboot:

[root@centolel ~]# ll /var/lib/tftpboot/
total 332
drwxr-xr-x  3 root root   4096 2015-06-29 18:38 boot
drwxr-xr-x  2 root root   4096 2015-06-22 21:08 etc
drwxr-xr-x  2 root root   4096 2015-06-29 18:38 grub
drwxr-xr-x  4 root root   4096 2015-06-29 18:38 images
drwxr-xr-x  2 root root   4096 2015-06-22 21:08 images2
-rw-r--r--. 2 root root  24988 2014-04-15 17:36 memdisk
-rw-r--r--  2 root root  54964 2015-06-14 14:25 menu.c32
drwxr-xr-x  2 root root   4096 2015-06-22 21:08 ppc
-rw-r--r--  2 root root  16794 2015-06-14 14:25 pxelinux.0
drwxr-xr-x  2 root root   4096 2015-06-29 18:43 pxelinux.cfg
drwxr-xr-x  2 root root   4096 2015-06-29 18:38 s390x
-rw-r--r--  2 root root 198236 2015-06-14 14:25 yaboot

Running the command cobbler sync finishes with notice "TASK COMPLETED!!".

So I wonder why is it that the server is specifically requesting for this address which is not part of the range and I also wonder why it can't find the images... any ideas?

Itai Ganot
  • 10,424
  • 27
  • 88
  • 143

1 Answers1

1

You might have some other competing DHCP server in your net. Running a traffic capture with Wireshark can help you pinpointing this problem.

BTW

range dynamic-bootp        10.13.0.20 10.13.0.150;
option routers             10.13.0.138;

the router's IP is within the assignation range; not good.

Pat
  • 3,339
  • 2
  • 16
  • 17