DHCP Server Configuration Part-3HARDWARE NETWORKING LINUX SOFTWAREIt Tech Technology

It Tech Technology

COMPUTER HARDWARE NETWORKING

Breaking

Home Top Ad

Post Top Ad

Wednesday, November 25, 2015

DHCP Server Configuration Part-3




Step-6:   Client Configuration for using DHCP.

Linux Client

[root@dhcp ~]# vi /etc/sysconfig/network-scripts/ifcfg-eth0

#Broadcom Corporation Net link BCM57875 Gigabyte Ethernet PCI Express
DEVICE=eth0
BOOTPROTO=dhcp
HWADDR=00:0C:29: EB: B2: CA
ONBOOT=yes
TYPE=Ethernet

Windows Client

From NIC Properties =>> set Obtain an IP Address Automatically

Step-7:   Renewing IP Address

Renew an IP Address in Linux

The -r flag explicitly releases the current lease, and once the lease has been released, the client exits. For example, open terminal and type the command:

[root@dhcp ~]# dhclient –r

Now obtain fresh IP:

[root@client1 ~]# dhclient

Or you can put the two commands on a single line:

[rnbsp; oot@client1 ~]# dhclient -r; dhclient

There is no need to restart network service. Above command should work with any Linux distro such as RHEL, Fedora, and others. On a related note you can also try out the following commands:

[root@client1 ~]# ifdown eth0
[root@client1 ~]# ifup eth0
[root@client1 ~]# /etc/init.d/network restart

Renew an IP Address in Windows

Open Command Prompt → Then Type The following command

C:\Documents and Settings\Administrator> Ipconfig  /release
C:\Documents and Settings\Administrator> Ipconfig  /renew

C:\Documents and Settings\Administrator> Ipconfig  /all

Post Bottom Ad