32.3. The DHCP Server Module

This module can be used to set up your system as a DHCP server so that clients on your LAN can be automatically assigned IP addresses, DNS servers, and other information. If there is already a server on your network, setting up another one is a bad idea as they may interfere with each other. If you just want to configure your system to obtain its own IP address via DHCP, then there is no need to set up a server. Instead, see Section 16.3 “Adding a Network Interface”.

The DHCP Server module can be found in Webmin under the Servers category. Clicking on its icon will take you to the main page, which lists all existing subnet, shared network, host, and group configurations. Figure 32.2 shows an example. If this is the first time that you have used the module, however, and the server has not been configured manually, then the page will probably be almost empty.

Figure 32.2. The DHCP Server module.


At the bottom of the page are buttons for editing global settings and displaying current dynamic address leases. Below them is the Start Server or Apply Changes button, which either starts the server if it is not running or restarts it to force a reload of the configuration if it is running. You cannot, however, start the server until at least one valid subnet has been defined.

If the ISC DHCP server is not installed on your system, the main page will display an error message notifying you that the dhcpd program could not be found. All Linux distributions include a DHCP server package on their CD or website, which you will need to install before you can use the module. Make sure that the package you add is called dhcpd or dhcp-server, as there is often a separate package for the DHCP client programs.

The same error can also appear if the server is installed, but in a location other than the one that the module expects. This can happen if you have compiled and installed it yourself from the source code, rather than using your distribution's standard package. If so, you will need to adjust some of the paths explained in Section 32.11 “Configuring the DHCP Server Module”.

Because this module only supports the configuration of ISC DHCP server versions 2 and 3, the main page will also display an error message if it detects that version 1 of the server is installed. Unfortunately, this older release uses a totally different configuration file format and so cannot be managed by the module. Some operating systems (such as Solaris) include this older version by default, but it can be replaced by the latest one.

The ISC DHCP server is also available for several other UNIX operating systems in addition to Linux. Because it works the same on all of those systems, the behavior of this module is identical as well. The only differences are the default paths that it uses for the server configuration files and programs.

On some operating systems and Linux distributions, the DHCP server package includes a sample configuration file that defines several hosts and subnets. These are not going to be of much use for your network and will probably prevent the server from working at all as they do not match its actual network interfaces. For this reason, it is best to simply delete them before setting up your own configuration.

Once a few entries have been added to the server configuration, the main page displays a table of icons networks under the heading Subnets and Shared Networks. Each icon represents either a subnet (shown with its network address under it) or a shared network (shown with its name). By default, subnets are listed first, followed by shared networks, and both lists are in the order that they appear in the configuration file. If you have a complex DHCP configuration, you can change this by clicking on one of the following links next to Display nets and subnets by:

Assignment The default sorting mode. Subnets are shown before shared networks and both are listed in the order in which they appear in the configuration file.

File structure Subnets are listed after the shared networks of which they are part, which are sorted by their order in the configuration file.

Name/IP address Subnets are listed, sorted by IP address, followed by shared networks sorted by name.

In the bottom part of the page is a table of icons with the heading Hosts and Host Groups. An icon is shown for each host or host group, with the name or number of members displayed beneath it. Because many servers have a large number of hosts, you can control the order that they are displayed in by clicking on one of the following links next to Display hosts and groups by:

Assignment Hosts are listed before groups and both are in the same order in which they appear in the configuration file.

File structure Hosts are listed after the groups of which they are part, which are sorted by their order in the configuration file.

Name Hosts are listed, sorted by name, followed by groups in the order in which they appear in the configuration file.

Hardware address Hosts are listed, sorted by MAC addresses, followed by all groups.

IP address Hosts are listed, sorted by their fixed IP address, followed by all groups.

Changes to the sorting modes will be remembered by the module, so that they will be used every time you visit the main page from now on.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.12.146.87