Make a DHCP server using Fedora - Help
Bill Davidsen
davidsen at tmr.com
Mon Nov 17 20:03:06 UTC 2008
Antonio Olivares wrote:
> --- On Sun, 11/16/08, Marko Vojinovic <vvmarko at panet.rs> wrote:
>
>> ###########################
>> default-lease-time 21600; #600
>> max-lease-time 43200; #7200
>> ddns-update-style none;
>> authoritative;
...snip...
>> Save, do a "service dhcpd restart" (it should say
>> OK), then
>> "tail -f /var/log/messages" and watch what is
>> going on. Restart the clients
>> (one by one if you wish to examine /var/log/messages after
>> each client,
>> otherwise you may restart them all simultaneously :-)...).
>>
>> [[ N.B. I suppose you have configured the clients to use
>> dhcp and not have
>> anything statically assigned... ]]
>>
>> What should be going on is that the clients in the
>> classroom ask for IP
>> configuration (dhcp request), then dhcpd replies with the
>> data above (dhcp
>> offer) and then each client accepts this offer. If all goes
>> well, up to this
>> point each client should have a 192.168.0.* IP assigned
>> dynamically, and be
>> able to ping any other client with such address, as well as
>> the server,
>> 192.168.0.1. If this doesn't happen, tell us what does
>> happen.
...snip...
>
> I did as you suggested and I still cannot connect the machines to the new server :(
>
Before even trying to connect, after you reload the dhcpd, do "netstat -ta" and
look to see if the server is listening (state LISTEN) on the dhcp port.
Also "ifconfig eth1" and "netstat -rn" so we can be sure you did what people
intended you to do.
> /etc/dhcpd.conf
>
> default-lease-time 21600; #600
> max-lease-time 43200; #7200
> ddns-update-style none;
> authoritative;
>
> subnet 10.154.19.0 netmask 255.255.255.0 {
> } # this means don't do anything with the big network
>
> subnet 192.168.0.0 netmask 255.255.255.0 {
> option routers 192.168.0.1; # your server is the router for classroom
> option subnet-mask 255.255.255.0; # the mask given to classroom
> option domain-name-servers 10.154.16.130, 10.128.0.4; # dns servers
> range 192.168.0.2 192.168.0.254; # the pool of addresses for classroom
> }
>
>
> [root at localhost ~]# service dhcpd restart
> Starting dhcpd: [FAILED]
> [root at localhost ~]# service dhcpd stop
> [root at localhost ~]# service dhcpd stop
> [root at localhost ~]# service dhcpd restart
> Starting dhcpd: [ OK ]
> [root at localhost ~]#
> It starts up but no leases show up, I am trying to ping computer from windows 2000 machine and from another machine running rawhide
>
> tail -f /var/log/messages show:
>
> Nov 16 18:51:13 localhost ntpd[2004]: kernel time sync status change 4001
> Nov 16 18:54:24 localhost dhcpd: DHCPREQUEST for 10.154.19.129 from 00:06:5b:4f:d7:d2 via eth0: unknown lease 10.154.19.129.
> Nov 16 18:56:32 localhost dhcpd: Internet Systems Consortium DHCP Server 4.0.0
> Nov 16 18:56:32 localhost dhcpd: Copyright 2004-2007 Internet Systems Consortium.
> Nov 16 18:56:32 localhost dhcpd: All rights reserved.
> Nov 16 18:56:32 localhost dhcpd: For info, please visit http://www.isc.org/sw/dhcp/
> Nov 16 18:56:32 localhost dhcpd: Not searching LDAP since ldap-server, ldap-port and ldap-base-dn were not specified in the config file
> Nov 16 18:56:32 localhost dhcpd: Wrote 0 leases to leases file.
> Nov 16 18:56:32 localhost dhcpd: Listening on LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
> Nov 16 18:56:32 localhost dhcpd: Sending on LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
> Nov 16 18:56:32 localhost dhcpd: Sending on Socket/fallback/fallback-net
> Nov 16 18:56:40 localhost dhcpd: Internet Systems Consortium DHCP Server 4.0.0
> Nov 16 18:56:40 localhost dhcpd: Copyright 2004-2007 Internet Systems Consortium.
> Nov 16 18:56:40 localhost dhcpd: All rights reserved.
> Nov 16 18:56:40 localhost dhcpd: For info, please visit http://www.isc.org/sw/dhcp/
> Nov 16 18:56:40 localhost dhcpd: Not searching LDAP since ldap-server, ldap-port and ldap-base-dn were not specified in the config file
> Nov 16 18:56:40 localhost dhcpd: Wrote 0 leases to leases file.
> Nov 16 18:56:40 localhost dhcpd: Listening on LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
> Nov 16 18:56:40 localhost dhcpd: Sending on LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
> Nov 16 18:56:40 localhost dhcpd: Sending on Socket/fallback/fallback-net
> Nov 16 19:06:27 localhost dhcpd: DHCPINFORM from 10.154.19.33 via eth0
> Nov 16 19:06:27 localhost dhcpd: DHCPACK to 10.154.19.33 (00:0f:1f:86:fc:70) via eth0
> Nov 16 19:06:30 localhost dhcpd: DHCPINFORM from 10.154.19.33 via eth0
> Nov 16 19:06:30 localhost dhcpd: DHCPACK to 10.154.19.33 (00:0f:1f:86:fc:70) via eth0
> Nov 16 19:12:24 localhost dhcpd: DHCPINFORM from 10.154.19.94 via eth0
> Nov 16 19:12:24 localhost dhcpd: DHCPACK to 10.154.19.94 (00:40:f4:ea:ee:d3) via eth0
> Nov 16 19:12:27 localhost dhcpd: DHCPINFORM from 10.154.19.94 via eth0
> Nov 16 19:12:27 localhost dhcpd: DHCPACK to 10.154.19.94 (00:40:f4:ea:ee:d3) via eth0
> Nov 16 19:12:57 localhost dhcpd: DHCPINFORM from 10.154.19.227 via eth0
> Nov 16 19:12:57 localhost dhcpd: DHCPACK to 10.154.19.227 (00:19:b9:2a:19:37) via eth0
> Nov 16 19:13:01 localhost dhcpd: DHCPINFORM from 10.154.19.227 via eth0
> Nov 16 19:13:01 localhost dhcpd: DHCPACK to 10.154.19.227 (00:19:b9:2a:19:37) via eth0
>
>
> Thank you all for helping me. I appreciate all your help and advice.
>
> Regards,
>
>
> Antonio
>
>
>
>
--
Bill Davidsen <davidsen at tmr.com>
"We have more to fear from the bungling of the incompetent than from
the machinations of the wicked." - from Slashdot
More information about the fedora-list
mailing list