Make a DHCP server using Fedora - Help
Antonio Olivares
olivares14031 at yahoo.com
Wed Nov 19 13:06:12 UTC 2008
--- On Mon, 11/17/08, Marko Vojinovic <vvmarko at panet.co.yu> wrote:
> From: Marko Vojinovic <vvmarko at panet.co.yu>
> Subject: Re: Make a DHCP server using Fedora - Help
> To: olivares14031 at yahoo.com, fedora-list at redhat.com
> Cc: vmarko at phy.bg.ac.yu
> Date: Monday, November 17, 2008, 10:49 AM
> Ok, it seems we are getting somewhere. :-)
>
> > Nov 17 07:27:07 localhost dhcpd: Wrote 0 leases to
> leases file.
> > Nov 17 07:27:07 localhost dhcpd: Listening on
> > LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
> > Nov 17 07:27:07 localhost dhcpd: Sending on
> > LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
> > Nov 17 07:27:07 localhost dhcpd: Sending on
> Socket/fallback/fallback-net
> > Nov 17 07:31:06 localhost dhcpd: DHCPINFORM from
> 10.154.19.25 via eth0
> > Nov 17 07:31:06 localhost dhcpd: DHCPACK to
> 10.154.19.25
> > (00:19:b9:10:16:92) via eth0
>
> This is normal, dhcpd is active and running, listens to all
> devices and
> "does nothing" on eth0, as configured. The eth1
> is a problem, but not
> related to dhcpd.
>
> > [root at localhost ~]# dhcpd -f
>
> There is no need to start it explicitly. The "service
> dhcpd restart"
> should be enough.
>
> > [root at localhost ~]# cat /etc/sysconfig/dhcpd
> > DHCPDARGS=
>
> This is ok.
>
> > [root at localhost ~]# ls
> /etc/sysconfig/network-scripts/ifcfg-eth* -l
> > -rw-r--r-- 3 root root 130 2007-04-03 12:36
> > /etc/sysconfig/network-scripts/ifcfg-eth0
>
> I see. There is no ifcfg-eth1.
>
> > [root at localhost ~]# ifconfig -a
> > eth1 Link encap:Ethernet HWaddr
> 00:60:97:C5:2A:C3
> > BROADCAST MULTICAST MTU:1500 Metric:1
> > RX packets:0 errors:0 dropped:0 overruns:0
> frame:0
> > TX packets:0 errors:0 dropped:0 overruns:0
> carrier:0
> > collisions:0 txqueuelen:1000
> > RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
> > Interrupt:18 Base address:0xdf00
>
> And this tells it all. The eth1 is not configured and
> running.
>
> > I also wonder if I should have a ifcfg-eth1 file in
> >
> > /etc/sysconfig/network-scripts/
>
> Yes, definitely. The "system-config-network" gui
> should create it for you.
> Open it, and see if eth1 is listed in the Devices tab. If
> not, click New
> to create it (follow the wizard). Then click Edit to edit
> its
> configuration:
>
> In the General tab:
> * Activate the device when computer starts --- should be
> the only checked
> option, everything else should be *unchecked*
> * Activate the static IP settings:
> * Address: 192.168.0.1
> * Subnet mask: 255.255.255.0
> * Gateway: leave empty for now
>
> In the Hardware Device tab:
> * Hardware: eth1
> * Device alias --- unchecked
> * Bind to MAC --- checked
> * Hit the "probe" button and make sure the MAC is
> 00:60:97:C5:2A:C3 (don't
> type it yourself, the button should fill it for you).
>
> Click OK to close the window and return to the main one. In
> the File menu
> choose Save to save the new configuration. Close the gui.
>
> Go to /etc/sysconfig/network-scripts/ and verify that there
> exists an
> ifcfg-eth1 file, with the contents like the following:
>
> TYPE=Ethernet
> DNS1=10.154.16.130
> DEVICE=eth1
> BOOTPROTO=none
> NETMASK=255.255.255.0
> IPADDR=192.168.0.1
> DNS2=10.128.0.4
> ONBOOT=yes
> USERCTL=no
> PEERDNS=yes
> IPV6INIT=no
> NM_CONTROLLED=no
>
> If this is ok, do a "service network restart"
> followed by the "service
> dhcpd restart". Post the output of
> "ifconfig" and "tail -f
> /var/log/messages".
>
> This should do it (hopefully), if you have no
> hardware/driver problems
> with the eth1 card.
>
> Also, verify that the cable is connected into eth1, that
> the led light is
> on, that the corresponding light on the switch is also on,
> etc. In other
> words, make sure that the hardware part of the setup is ok.
>
> HTH, :-)
> Marko
I am making the changes and I am seeing new things :)
[root at localhost ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth1
# Ethernet controller: 3Com Corporation 3c905 100BaseTX [Boomerang]
DEVICE=eth1
HWADDR=00:60:97:c5:2a:c3
BOOTPROTO=none
IPADDR=192.168.0.1
ONBOOT=yes
USERCTL=no
PEERDNS=yes
IPV6INIT=no
NM_CONTROLLED=no
TYPE=Ethernet
[root at localhost ~]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:0E:A6:42:59:AF
inet addr:10.154.19.210 Bcast:10.154.19.255 Mask:255.255.255.0
inet6 addr: fe80::20e:a6ff:fe42:59af/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2535 errors:0 dropped:0 overruns:0 frame:0
TX packets:1985 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:1074701 (1.0 MiB) TX bytes:401481 (392.0 KiB)
Interrupt:22 Base address:0x6000
eth1 Link encap:Ethernet HWaddr 00:60:97:C5:2A:C3
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::260:97ff:fec5:2ac3/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:22 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:4077 (3.9 KiB)
Interrupt:18 Base address:0xdf00
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:36 errors:0 dropped:0 overruns:0 frame:0
TX packets:36 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:2064 (2.0 KiB) TX bytes:2064 (2.0 KiB)
pan0 Link encap:Ethernet HWaddr 66:6C:20:72:B7:0E
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
[root at localhost ~]# tail -f /var/log/messages
Nov 19 06:59:27 localhost ntpd_initres[2088]: host name not found: 0.fedora.pool.ntp.org
Nov 19 06:59:27 localhost ntpd_initres[2088]: host name not found: 1.fedora.pool.ntp.org
Nov 19 06:59:27 localhost system-config-network[3202]: chmod 0644 //etc/sysconfig/networking/devices/ifcfg-eth0
Nov 19 06:59:27 localhost nm-system-settings: ifcfg-fedora: updating /etc/sysconfig/network-scripts/ifcfg-eth0
Nov 19 06:59:27 localhost nm-system-settings: ifcfg-fedora: parsing /etc/sysconfig/network-scripts/ifcfg-eth0 ...
Nov 19 06:59:27 localhost ntpd_initres[2088]: host name not found: 2.fedora.pool.ntp.org
Nov 19 06:59:27 localhost nm-system-settings: ifcfg-fedora: read connection 'System eth0'
Nov 19 06:59:27 localhost nm-system-settings: ifcfg-fedora: Ignoring connection 'System eth0' and its device because NM_CONTROLLED was false.
Nov 19 06:59:27 localhost nm-system-settings: ifcfg-fedora: updating /etc/sysconfig/network-scripts/ifcfg-eth0
Nov 19 06:59:27 localhost system-config-network[3202]: chmod 0644 //etc/sysconfig/networking/devices/ifcfg-eth1
Nov 19 07:01:06 localhost dhcpd: Internet Systems Consortium DHCP Server 4.0.0
Nov 19 07:01:06 localhost dhcpd: Copyright 2004-2007 Internet Systems Consortium.
Nov 19 07:01:06 localhost dhcpd: All rights reserved.
Nov 19 07:01:06 localhost dhcpd: For info, please visit http://www.isc.org/sw/dhcp/
Nov 19 07:01:06 localhost dhcpd: Not searching LDAP since ldap-server, ldap-port and ldap-base-dn were not specified in the config file
Nov 19 07:01:06 localhost dhcpd: Wrote 0 leases to leases file.
Nov 19 07:01:06 localhost dhcpd: Listening on LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
Nov 19 07:01:06 localhost dhcpd: Sending on LPF/eth0/00:0e:a6:42:59:af/10.154.19.0/24
Nov 19 07:01:06 localhost dhcpd: Listening on LPF/eth1/00:60:97:c5:2a:c3/192.168.0.0/24
Nov 19 07:01:06 localhost dhcpd: Sending on LPF/eth1/00:60:97:c5:2a:c3/192.168.0.0/24
Nov 19 07:01:06 localhost dhcpd: Sending on Socket/fallback/fallback-net
Nov 19 07:01:58 localhost kernel: npviewer.bin[3360] general protection ip:1168f8c sp:bf96f670 error:0 in libflashplayer.so[dfd000+951000]
Nov 19 07:02:23 localhost dhcpd: DHCPDISCOVER from 00:d0:b7:c1:09:58 via eth1
Nov 19 07:02:24 localhost dhcpd: DHCPOFFER on 192.168.0.2 to 00:d0:b7:c1:09:58 (6355-hthhzebqqx) via eth1
Nov 19 07:02:24 localhost dhcpd: DHCPREQUEST for 192.168.0.2 (192.168.0.1) from 00:d0:b7:c1:09:58 (6355-hthhzebqqx) via eth1
Nov 19 07:02:24 localhost dhcpd: DHCPACK on 192.168.0.2 to 00:d0:b7:c1:09:58 (6355-hthhzebqqx) via eth1
Nov 19 07:02:26 localhost dhcpd: DHCPDISCOVER from 00:11:2f:35:88:2e via eth1
Nov 19 07:02:27 localhost dhcpd: DHCPOFFER on 192.168.0.3 to 00:11:2f:35:88:2e via eth1
Nov 19 07:02:27 localhost dhcpd: DHCPREQUEST for 192.168.0.3 (192.168.0.1) from00:11:2f:35:88:2e via eth1
Nov 19 07:02:27 localhost dhcpd: DHCPACK on 192.168.0.3 to 00:11:2f:35:88:2e via eth1
Nov 19 07:03:16 localhost dhcpd: DHCPINFORM from 192.168.0.2 via eth1
Nov 19 07:03:16 localhost dhcpd: DHCPACK to 192.168.0.2 (00:d0:b7:c1:09:58) viaeth1
Nov 19 07:03:21 localhost dhcpd: DHCPINFORM from 192.168.0.2 via eth1
Nov 19 07:03:21 localhost dhcpd: DHCPACK to 192.168.0.2 (00:d0:b7:c1:09:58) viaeth1
Nov 19 07:04:53 localhost dhcpd: DHCPINFORM from 192.168.0.2 via eth1
Nov 19 07:04:53 localhost dhcpd: DHCPACK to 192.168.0.2 (00:d0:b7:c1:09:58) viaeth1
Nov 19 07:04:57 localhost dhcpd: DHCPINFORM from 192.168.0.2 via eth1
Nov 19 07:04:57 localhost dhcpd: DHCPACK to 192.168.0.2 (00:d0:b7:c1:09:58) viaeth1
The machines apparently picked up an ip, but there is no DNS, I will put in DNS like your example and then get back :)
Thank you very much Marko and all others, Tim, Craig, etc. That have been very helpful.
Regards,
Antonio
More information about the users
mailing list