Hi!

I am having hard time getting dhcpd with synchronisation to work. What i have is two OpenBSD v. 5.0 working in the same subnet as test dhcp servers and third as dhcp client. Each computer has actually two network interfaces, one for remote access and the other for playing with dhcp. They are vmware esx guests and pf is disabled, also they are fresh v. 5.0 installs. Time is the same on all.

To see how dhcp syncronisation works i thought to start with such an aim: servers have simple dhcpd.conf which configures ip address from a range to the client and does so with short lease-time. Then client starts renewing it lease and as a sign on successful sync i expect to see then /var/db/dhcpd.leases files are kept identical on both dhcp servers. (Please comment if this is valid expectation.)

As a result my client gets leases and dhcp servers exchange udp packets but no apparent leases file syncronisation is seen. I would be thankful if you could point me to the right direction.

Dhcp servers have such dhcpd.conf (not digest identical but content identical)

# cat /etc/dhcpd.conf
option domain-name "auul";
option domain-name-servers 10.0.9.4, 10.0.9.5;
max-lease-time 60;
default-lease-time 60;

subnet 10.0.101.0 netmask 255.255.255.0 {

       range 10.0.101.100 10.0.101.149;

}

/var/db/dhcpd.key files are identical

and dhcpd is started like this

host-101-189# dhcpd -d -f -Y 10.0.101.190 -y 10.0.101.189 em1
host-101-190# dhcpd -d -f -Y 10.0.101.189 -y 10.0.101.190 em1

When i start client like

# dhclient -d em1

then i see on the network that both dhcp servers answer and both send one udp packet one to the other port 8067. Afterwards, dhcp client asks renewal directly mostly from one dhcp server and gets a new lease (answering dhcp server sends one udp packet to the other one after that).

Letting it to work for some time i end up with one dhcp server having two leases in dhcpd.leases, the other server has tens of leases in its dhcpd.leases and client has in its leases the first lease from on and the rest from other dhcp server (as indicated with option dhcp-server-identifier).


Imre

PS With netstat -np udp i a see both are 8067 listening.

Reply via email to