Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a question about the dhcp server on linux

Basically my server has 2 interface cards

  • eth0 : 192.168.2.201/255.255.255.0
  • eth1 : 192.168.4.1/255.255.255.0
  • eth1:0 : 10.1.1.0/24

On this server i am running the dhcpd daemon to hand out leases in the 192.168.4.0/24 subnet.

  • eth0 : connected to my home router to access internet
  • eth1 : connected to a cisco switch (with only default vlan) on port 1 with ip address 10.1.1.10 - this interface is used for communication with the switch for management through telnet

Now when i plug in another computer on any port on the switch i see the following

  • the computer gets 169.254 self assigned ip
  • i see the DHCP server did hand out a lease (/var/lib/dhcpd/dhcpd.leases file)
  • under ethernet status on the client computer i see bytes sent but 0 received

Now my question is

To which interface on the linux server does the dhcpd daemon bound to ? Since i see the lease being assigned it is obviously getting the dhcp request yet the lease it sends out is not reaching the client.

Any help would be much appreciated !

thank you, ankit

share|improve this question
add comment

1 Answer 1

up vote 0 down vote accepted

You can't use 10.1.1.0 as the IP of the NIC, that's a network ID. DHCPd should bind to all interfaces that it has subnet definitions for. So if it has only definitions for the 192.168.4/24 subnet, then it should only bind to eth1. What's the output from DHCPd when it starts? It should mention what interfaces it's listening on.

share|improve this answer
    
my mistake .. the NIC eth1:0 does have the ip address 10.1.1.1. As i mentioned earlier, the DHCP server starts up just fine as i do see it getting the request from the client and handing out a lease. Its just that lease packet never reaches the client ... gets lost in transit. –  ankit Dec 1 '10 at 15:53
    
Found the answer in the man pages ... needed to add DHCPDARGS=eth1; –  ankit Feb 6 '11 at 16:50
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.