Quick HOWTO : Ch. Configuring the DHCP Server. Introduction. Normally if you have a cable modem or DSL, you get your home PC's IP address dynamically assigned from your service provider. If you install a home cable/DSL router between your modem and home network, your PC will most likely get its IP address at boot time from the home router instead. You can choose to disable the DHCP server feature on your home router and set up a Linux box as the DHCP server. This chapter covers only the configuration of a DHCP server that provides IP addresses. The configuration of a Linux DHCP client that gets its IP address from a DHCP server is covered in Chapter 3, "Linux Networking", on Linux Networking. Download and Install the DHCP Package. Most Red. Hat and Fedora Linux software product packages are available in the RPM format, whereas Debian and Ubuntu Linux use DEB format installation files. When searching for these packages, remember that the filename usually starts with the software package name and is followed by a version number, as in dhcp- 3. For help on downloading and installing the package, see Chapter 6, "Installing Linux Software".). Managing the DHCP Server. Managing the DHCP daemon is easy to do, but the procedure differs between Linux distributions.
Install the repository configuration package. This package contains yum configuration files. Zabbix 2.2 for RHEL5, Oracle Linux 5, CentOS 5: # rpm -ivh http://repo. Here are some things to keep in mind. Firstly, different Linux distributions use different daemon management systems. Each system has its own set of commands to do similar operations. The most commonly used daemon management systems are Sys. V and Systemd. Secondly, the daemon name needs to be known. In this case the name of the daemon is dhcpd. Armed with this information you can know how to. Start your daemons automatically on booting. Stop, start and restart them later on during troubleshooting or when a configuration file change needs to be applied. For more details on this, please take a look at the "Managing Daemons" section of Chapter 6 "Installing Linux Software". Note: If you modify your daemon configuration file remember that the changes won't take effect till you restart the daemon. Note: Remember to configure your daemon to start automatically upon your next reboot. File. You can define your server configuration parameters in the dhcpd.Linux. Note: The skeleton dhcp.In Ubuntu / Debian, the skeleton dhcpd. . In Fedora / Red. Hat / Cent.OS an extensive sample is also created with activated commands.It is found in the following location which you can always use as a guide. Update My Garmin Streetpilot C530 Gps . Note: The dhcpd. conf configuration file formats in Debian / Ubuntu and Redhat / Fedora are identical.Here is a quick explanation of the dhcpd.Most importantly, there must be a subnet section for each interface on your Linux box. The range of IP addresses the server. DHCP enabled PC clients. Set the amount of time in seconds that. IP address. default- lease- time 8. Set the default gateway to be used by. PC clients. option routers 1. Don't forward DHCP requests from this. NIC interface to any other NIC. Set the broadcast address and subnet mask. DHCP clients. option broadcast- address 1. Set the NTP server to be used by the. DHCP clients. option ntp- servers 1. Set the DNS server to be used by the. DHCP clients. option domain- name- servers 1. If you specify a WINS server for your Windows clients. You can also assign specific IP addresses based on the clients'. MAC address as follows (Host's name is "laser- printer". List an unused interface here. There are many more options statements you can use to configure DHCP. These include telling the DHCP clients where to go for services such as finger and IRC. Check the dhcp- options man page after you do your install. Note: The host statement seen in the sample dhcpd. Some devices such as network printers default to getting their IP addresses using DHCP, but users need to access them by a fixed IP address to print their documents. This statement can be used to always provide specific IP address to DHCP queries from a predefined a NIC MAC address. This can help to reduce systems administration overhead. DHCP Servers with Multiple NICs. DHCP servers with multiple interfaces pose two configuration challenges. The first is setting up the correct routing and the second is making sure only the required interfaces are listening to serve DHCP. Don’t worry, both will be discussed next. Routing. When a DHCP configured PC boots, it requests its IP address from the DHCP server. It does this by sending a standardized DHCP broadcast request packet to the DHCP server with a source IP address of 2. If your DHCP server has more than one interface, you have to add a route for this 2. In both of the next two examples, we assume that DHCP requests will be coming in on interface eth. Note: More information on adding Linux routes and routing may be found in Chapter 3, "Linux Networking". Note: You can't run your DHCP sever on multiple interfaces because you can only have one route to network 2. If you try to do it, you'll discover that DHCP serving working on only one interface. Temporary Solution. You can temporarily add a route to 2. If you want this routing state to be maintained after a reboot, then use the permanent solution that's discussed next. Permanent Solution. Create a permanent route to 2. This will vary according to your version of Linux. Fedora / Red. Hat / Cent. OS: Add the route to your /etc/sysconfig/network- scripts/route- eth. File /etc/sysconfig/network- scripts/route- eth. Ubuntu / Debian: Add the route to your /etc/network/interfaces file. In this case the route is added to the eth. File: /etc/network/interfaces. Simple Linux routing is covered in Chapter 3, "Linux Networking" and will add more clarity to adding permanent static routes. Listening. Once you have defined the interface for your DHCP routing you should also ensure that your DHCP server only listens on that interface and no others. This methodology to do this varies depending on your versión of Linux. Fedora / Red. Hat / Cent. OS: The /etc/sysconfig/dhcpd file must be edited and the DHCPDARGS variable edited to include the preferred interface. In this example interface eth. File: /etc/sysconfig/dhcpd. Debian / Ubuntu: The /etc/default/dhcp. INTERFACES variable edited to include the preferred interface. In this example interface eth. File: /etc/default/dhcp. INTERFACES="eth. 0". You will be able to verify success in one of two ways. First the netstat command using the –au options will give the list of interfaces listening on the bootp (DHCP) UDP port. Secondly, your /var/log/messages file will also reveal the defined interfaces used when the DHCPd daemon was restarted. Jan 8 1. 7: 2. 2: 4. Listening on LPF/eth. Jan 8 1. 7: 2. 2: 4. Sending on LPF/eth. Success! You can go back to lunch! Configuring Linux Clients to Use DHCPA Linux NIC interface can be configured to obtain its IP address using DHCP with the examples outlined in , "Chapter 3, Linux Networking". Please refer to this chapter if you need a quick refresher on how to configure a Linux DHCP client. Configuring Windows Clients to Use DHCPFortunately Windows defaults to using DHCP for all its NIC cards so you don't have to worry about doing any reconfiguration. Using a Single DHCP Server to Serve Multiple Networks. As stated before, DHCP clients send their requests for IP addresses to a broadcast address which is limited to the local LAN. This would imply that a DHCP server is required on each subnet. Not so. It is possible to configure routers to forward DHCP requests to a DHCP server many hops away. This is done by inserting the IP address of the router's interface on the DHCP client's network into the forwarded packet. To the DHCP server, the non- blank router IP address field takes precedence over the broadcast address and it uses this value to provide a DHCP address that is meaningful to the client. The DHCP server replies with a broadcast packet, and the router, which has kept track of the initial forwarded request, forwards it back towards the client. You can configure this feature on Cisco devices by using the ip helper- address command on all the interfaces on which DHCP clients reside. Here is a configuration sample that points to a DHCP server with the IP address 1. Fast. Ethernet 2/1. Simple DHCP Troubleshooting. The most common problems with DHCP usually aren't related to the server; after the server is configured correctly there is no need to change any settings and it therefore runs reliably. The problems usually occur at the DHCP client's end for a variety of reasons. How to fix /lib/ld- linux. ELF interpreter: No such file or directory. Hello,I encountered several days ago this error on a fresh installed Cent. OS 6 – 6. 4 bit machine while installing some game redirection software from Cs. Servers. ro. This will happen only on 6. So if you encounter this error /lib/ld- linux. ELF interpreter: No such file or directory this is how you can fix it: On any RPM based distribution (Cent. OS/Red. Hat/Fedora/Suse/Mandriva): yum - y install glibc. On any DEB based distribution (Debian/Ubuntu/Mint/Crunchbang): apt- get update.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
October 2017
Categories |