Hewson |
01-10-2008 02:21 PM |
DHCPD: how to get deamon to respond to relay agents, but not locally
CentOS 5
Code:
----- -----
|DHCPD| |DHCPD|
| 1 | | 2 |
----- -----
| | NETWORK A
--------------------------
|
----------
|RelayAgent|
| \ Router |
----------
| NETWORK B
------------------------
|
------
| DHCP |
|client|
------
So here is my problem. I have a dhcp server (DHCPD 2) on one network (NETWORK A) that I need to respond to requests coming from the relay agent (RelayAgent \ Router), but I do not want it to respond to requests on its own network (NETWORK A). There is a separate dhcp server for this network (DHCPD 1). That dhcp server (DHCPD 1) needs to only serve its directly connected network (NETWORK A).
I only want the DHCPD 2 machine to hand out leases via the interface on NETWORK A, it has other interfaces on which it must not be handing out dhcp leases. I configured DHCPD 2 with the leases for subnet of NETWORK B and set /etc/sysconfig/dhcpd's 'DHCPDARGS' to the interface on NETWORK A.
When i start the dhcpd service on DHCPD 2, it fails. /var/log/messages says:
Code:
Jan 10 11:21:50 localhost Installed: dhcp.i386 12:3.0.5-7.el5
Jan 10 12:00:12 localhost dhcpd: Internet Systems Consortium DHCP Server V3.0.5-RedHat
Jan 10 12:00:12 localhost dhcpd: Copyright 2004-2006 Internet Systems Consortium.
Jan 10 12:00:12 localhost dhcpd: All rights reserved.
Jan 10 12:00:12 localhost dhcpd: For info, please visit http://www.isc.org/sw/dhcp/
Jan 10 12:00:12 localhost dhcpd: Wrote 0 leases to leases file.
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd: No subnet declaration for eth0 (192.168.14.1).
Jan 10 12:00:12 localhost dhcpd: ** Ignoring requests on eth0. If this is not what
Jan 10 12:00:12 localhost dhcpd: you want, please write a subnet declaration
Jan 10 12:00:12 localhost dhcpd: in your dhcpd.conf file for the network segment
Jan 10 12:00:12 localhost dhcpd: to which interface eth0 is attached. **
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd: Not configured to listen on any interfaces!
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd: If you did not get this software from ftp.isc.org, please
Jan 10 12:00:12 localhost dhcpd: get the latest from ftp.isc.org and install that before
Jan 10 12:00:12 localhost dhcpd: requesting help.
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd: If you did get this software from ftp.isc.org and have not
Jan 10 12:00:12 localhost dhcpd: yet read the README, please read it before requesting help.
Jan 10 12:00:12 localhost dhcpd: If you intend to request help from the dhcp-server@isc.org
Jan 10 12:00:12 localhost dhcpd: mailing list, please read the section on the README about
Jan 10 12:00:12 localhost dhcpd: submitting bug reports and requests for help.
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd: Please do not under any circumstances send requests for
Jan 10 12:00:12 localhost dhcpd: help directly to the authors of this software - please
Jan 10 12:00:12 localhost dhcpd: send them to the appropriate mailing list as described in
Jan 10 12:00:12 localhost dhcpd: the README file.
Jan 10 12:00:12 localhost dhcpd:
Jan 10 12:00:12 localhost dhcpd: exiting.
Jan 10 12:00:12 localhost dhcpd: dhcpd startup failed
How can I get this to work?
I can get it to start up if i add an empty lease for the local network a.k.a.
subnet 192.168.8.0 netmask 255.255.248.0 {
}
But will DHCPD start serving leases for 192.168.8.0/21 with some sort of default settings?
|