About DHCP protocol and dhcpd configuration file (1)

Source: Internet
Author: User
Tags what parameter

After learning about the basic content of the DHCP protocol, let's take a look at the related content of its dhcpd configuration file. First, let's take a look at the basic concepts in this regard. Then, analyze its application.

Name

Dhcpd. conf-dhcpd configuration file

Description

The dhcpd. conf file contains the configuration information of the dhcpd of isc dhcp.

The dhcpd. conf file is an ASCII code document in common format, which is interpreted by the built-in recursive parser.

The dhcpd. file may contain many additional tabs, spaces, and empty rows. They are designed to make the file easier to read. The keywords are not case sensitive. The comment statement can be placed anywhere except in quotation marks.) The comment statement starts with #. The comment statement ends naturally at the end of this line.

The file contains a set of statements in a pair of braces, including parameters and declarations.

Parameter statements describe how to do one thing, for example, how long the lease period is), or whether to do one thing. (For example, whether or not dhcpd provides an address for an unknown customer), or what parameter is provided to the customer (for example, use the gateway 220.177.244.7 ).

The Declaration is used to describe the network topology and the customers on the network. It provides the addresses that can be allocated to the client or the group parameter for a client group. In any group parameter, all these group parameters must appear first than statements using these group parameters.

The Network Declaration contains a multi-subnet network. It is difficult to understand the network definition. Here it is called "Multi-subnet network") and the topology Declaration of the subnet. For subnet clients to be dynamically allocated addresses, the subnet declaration must contain a range declaration statement. Each client must use a host declaration statement for Statically assigned addresses or known client installations. If a parameter is applied to a set of declarations that are not only related to a specific subnet, you can define a "group parameter ".

For each subnet to be served, the subnet connected to each dhcp server must have a subnet declaration to tell dhcpd how to handle the address on that subnet. Even if a subnet does not need to be assigned any address, a subnet declaration is required.

In some physical networks, there is not only one IP subnet. For example, if a network requires an eight-bit subnet, but when the business develops, the total number of nodes exceeds 254, you need to add an eight-bit subnet. A new physical network is added. In this case, the subnet Declaration of the two networks must be included in a "Multi-subnet network declaration super scope.

Some network clients not only have one subnet, but may assign some parameters to some clients in the same subnet different from those of other clients. In this way, you can use the host statement to define some parameters. Some parameters can also be defined in the "Group Parameters" Statement, which are called by these clients. For clients that need to obtain different addresses according to different situations, the statements "class Declaration class declarations)" and "condition declaration conditional declarations)" may be used, in this way, the parameters assigned to the client can be determined based on the information sent by the client.

When a client is started, the server first checks whether there is a host statement that matches the client. If not, check whether there is a matched "class Declaration class declarations)" statement, then, check whether there is a "pool" match, "subnet" match with "Multi-subnet network super scope) shared-net-work" match. According to the matching,) the client parameters will be provided to it. Each parameter is not analyzed for 2nd times. If they appear twice or more times, the most accurate location will be used.

Dhcpd first checks whether the client has a host statement containing a fixed IP address. The address must be in the subnet that the client starts or in the "Multi-subnet network". If no corresponding host statement matches, find the non-fixed address statement.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.