DHCP is the abbreviation for Dynamic Host Configuration Protocol Configure Kyoto. A DHCP server allows administrators to centrally assign and specify global and subnet-specific http://www.aliyun.com/zixun/aggregation/29912.html ">TCP/IP parameters (including IP addresses, gateways, DNS servers, etc.) for use throughout the network. DHCP is divided into two parts: one is the server side and the other is the client. Below, small make up to let us introduce how to set up a DHCP server in Redhat Linux environment.
I. Configuring DHCP
Redhat uses the DHCPD process to provide a DHCP service that automatically reads the profile/etc/dhcpd.conf at startup DHCPD. DHCPD stores the customer's lease information in the/var/lib/dhcp/dhcpd.leases file, which is constantly updated and can be traced to IP address assignments.
DHCPD in order to provide services to a subnet, you need to know the network address and netmask of the subnet, and also know the scope of the address assignment, here is a simple dhcpd.conf file:
Subnet 192.168.100.0 netmask 255.255.255.0 {
Range 192.168.100.10 192.168.100.253;}
In this case, DHCPD assigns 192.168.100.10 to 192.168.100.253 IP addresses to the 192.168.100.0 network. The lease time can be from 0 seconds to infinitely long, depending on the need to decide. The default lease duration is one day, or 86,400 seconds. You can define two lease lengths for a host:
Default-lease-time default lease period time;
Max-lease-time the maximum period of time that a user can obtain.
The following configuration sets the default lease time to 10 minutes and the maximum lease time is 1 hours:
Subnet 192.168.100.0 netmask 255.255.255.0 {
Range 192.168.100.10 192.168.100.253;
Default-lease-time 600;
Max-lease-time 3600;
DHCP can also provide customers with additional parameters that can be specified with option, for example:
Subnet 192.168.100.0 netmask 255.255.255.0 {
Range 192.168.100.10 192.168.100.253;
Default-lease-time 600;
Max-lease-time 3600;
Option Subnet-mask 255.255.255.0;
Option routers 192.168.100.254; default route
Option domain-name-servers 202.102.134.68;dns Server}
Now you should have a understanding of DHCP configuration, in fact, the process is so simple.