DHCP
Server Configuration
Step-1:
To check dhcp rpm package is
installed or not by following this command:
(if installed then it will show dhcp
packages)
[root@dhcp ~]# rpm
-qa | grep –i dhcp* or
[root@dhcp ~]#
rpm –qa dhcp*
dhcp-3.0.5-21.el5
dhcp-devel-3.0.5-21.el5
libdhcp-devel-1.20-10.el5
dhcpv6-client-1.0.10-17.el5
libdhcp-1.20-10.el5
libdhcp4client-3.0.5-21.el5
libdhcp6client-devel-1.0.10-17.el5
libdhcp4client-devel-3.0.5-21.el5
dhclient-3.0.5-21.el5
If not installed, then installed the packages using Yum command:
[root@dhcp ~]# Yum Install dhcp* lib*
Step-2:
Check and Configure the Network
Card:
[root@dhcp ~]# vi
/etc/sysconfig/network-scripts/ifcfg-eth0
(Original File):
#Broadcom Corporation Net link BCM57875
Gigabyte Ethernet PCI Express
DEVICE=eth0
BOOTPROTO=dhcp
HWADDR=00:0C:29: EB: B2: CA
ONBOOT=yes
BOOTPROTO=dhcp
HWADDR=00:0C:29: EB: B2: CA
ONBOOT=yes
(Modified File):
#Broadcom Corporation Net link BCM57875
Gigabyte Ethernet PCI Express
DEVICE=eth0
BOOTPROTO=static
HWADDR=00:0C:29: EB: B2: CA
ONBOOT=yes
TYPE=Ethernet
PEERDNS=no
USERCTL=no
IPV6INIT=no
IPADDR=210.207.201.4
NETMASK=255.255.255.0
NETWORK=210.207.201.0
BROADCAST=210.207.201.255
Press
Esc → Shift + : → x! → Enter (For Save and Exit the Vi Editor).
After changing you have to
reload/restart the NIC(eth0) card by following command:
[root@dhcp ~]# ifdown
eth0
[root@dhcp ~]# ifup eth0
[root@dhcp ~]# service
network restart
Step-3: DHCP Server Configuration