基于Linux的DHCP服务器配置
摘 要
随着互联网的普及,人们的工作、学习和生活与网络联系越来越紧密,搭建了许多不同的网络,如企业网、校园网和城区网等。网络管理是大型计算机网络成功的关键因素,利用DHCP服务已经显得相当流行。动态主机分配协议(DHCP)的运用也显得越来越重要。在实际的操作过程中,构建DHCP服务器也越来越常见。而采用DHCP技术动态地为主机配置参数,可以有效解决目前IP地址资源不足和用户的移动性等问题,并能极大地减轻大型网络管理员的工作量,减少手工网络配置的错误,有利于快速地搭建一个大型网络或修改其网络配置。构建DHCP服务器需要一个稳定的操作系统和服务器软件。在操作系统的竞争之中,Linux以“免费、高效率、稳定性、跨平台”的特点,加上功能强大,对硬件配置需求低等优势,迅速地占领了一些其它商业操作系统市场,而且还在持续蔓延和发展。而Red hat Linux操作系统经过一段时间的发展已经成为一个主要的Linux发行版本,越来越多的企业和个人开始采用它来进行工作,学习和娱乐。同时,Red Hat Linux中附带的DHCP服务也是目前Internet上最受欢迎的动态IP地址分配服务器。本文以企业网的DHCP服务器为基础,一步步地描述了DHCP服务器的构建过程。 关键词:企业网;Linux;DHCP
I
基于Linux的DHCP服务器的配置
Abstract
With the popularity of the Internet, people's work, study and living increasingly close ties with the network, set up a number of different networks, such as enterprise networks, campus networks and urban networks, etc.. Network management is a large computer networks, a key factor in the success of the use of DHCP service has become very popular. Dynamic Host Allocation Protocol (DHCP) use has become increasingly important. In the actual operation, building a DHCP server is also becoming more common. Technological developments and the use of DHCP for host configuration parameters, can effectively address the current shortage of IP address resources and user mobility issues, and can greatly reduce the workload of a large network administrators to reduce errors in manual network configuration is conducive to rapid to build a large network or modify their network configuration. DHCP server needs to build a stable operating system and server software. Among the competition in the operating system, Linux in order to \high efficiency, stability, cross-platform\features, combined with powerful advantages of low hardware requirements and quickly occupied a number of other commercial operating system market, but also also continued to spread and development. The Red hat Linux operating system, after a period of development has become a major Linux distribution, more and more businesses and individuals began to use it for work, study and recreation. At the same time, Red Hat Linux for DHCP services are also included in the current Internet, the most popular dynamic IP address allocation server. In this paper, enterprise network DHCP server, based on a step by step description of the DHCP server build process.
Keywords: Enterprise networks; Linux; DHCP
II
目 录
第1章 企业网络环境分析 ............................................... 1 1.1企业网络环境介绍 ................................................. 1 1.2企业网络IP的规划 ................................................ 2 第2章 DHCP服务概述 .................................................. 3 2.1企业网搭建DHCP服务器的意义 ...................................... 3 2.2 DHCP服务器的工作原理 ............................................ 3 2.2.1 DHCP的优缺点 ................................................ 3 2.2.2 DHCP服务器的工作原理 ........................................ 4 第3章 LINUX 系统的安装 ............................................... 8 3.1 RED HAT LINUX 简介 ................................................ 8 3.2 RED HAT LINUX 的安装 .............................................. 9 第4章 DHCP服务器的搭建 ............................................. 12 4.1安装DHCP服务器 ................................................. 12 4.2 DHCP服务器配置文件介绍 ......................................... 12 4.3建立DHCP服务器配置文件 ......................................... 14 4.4启动和检查DHCP服务器 ........................................... 15 4.5 DHCP中继代理配置 ............................................... 16 4.6配置DHCP客户端 ................................................. 17 第5章 管理和维护DHCP服务器 ......................................... 19 5.1 DHCP服务器常见故障排除 ......................................... 19 5.2 DHCP服务器的安全 ............................................... 20 总 结 ............................................................ 24 致 谢 ............................................................ 25 参考文献 ............................................................ 26
III
第1章 企业网络环境分析
1.1企业网络环境介绍
Benet公司是一家新型IT企业,有两栋写字楼,楼宇之间通过三层交换机连接。公司有6个部门,为了安全起见各部门都通VLAN分开。合计有100多台电脑,由于电脑数目较多,并且分布在不同的区域,手工配置非常复杂,而且容易输入错误等缺点。为了方便网络管理,和提高网络的安全性、稳定性、跨平台的特点。公司内部网采用一台基于Linux系统的DHCP服务器来管理整个网络中的IP地址资源。它能够动态地向网络中每台设备分配独一无二的IP地址,并提供安全、可靠且简单的TCP/IP网络配置,确保不发生地址冲突,帮助维护IP地址的使用。其客户端都采用windows系统,便于员工的操作。以下为公司网络拓扑图:
图 1. 1公司内部网拓扑图
1