DHCP服务器的架设
一、准备
Linux企业4为服务器,红帽子9和xp为客户端
二、配置DHCP服务器
1、打开终端
2、设ip地址 netconfig
ip address 192.168.10.10
子网掩码:255.255.255.0
网关: 192.168.10.10
DNS服务器:192.168.10.10
3、重启网络服务 service network restart
4、查询dhcp是否安装
rmp -qa | grep dhcp
5、挂载企业4光盘
插入光盘
卸载光盘:umount /dev/cdrom
挂载光盘:mount /dev/cdrom /media/cdrom
查看是否挂载上:cd /media/cdrom/RedHat/RPMS
ll *dhcp*
安装dhcp软件包:rpm -ivh dhcp-3.0.1-12—EL.i386.rpm
rpm -ivh dhcp-devel-3.0.1-12—EL.i386.rpm
查看dhcp软件包的文件列表:rpm -ql dhcp
拷贝模板配置文件到/etc目录下为dhcp.conf
cp /usr/share/doc/dhcp_3.0.1/dhcp.comf.sample /etc/dhcp.conf
修改dhcp.conf文件内容
vi /etc/dhcp.conf
subnet 192.168.10.0
option routes 192.168.10.10
option subnet-mask 255.255.255.0
option domain "benet.com"
option domain-name-servers 192.168.10.10
range dynamic-bootp 192.168.10.100 192.168.10.200
hardware ethernet 00:0c:29:c2:9b:5f;(xp的mac地址)
fixed-address 192.168.10.88(给xp的固定ip地址)
按Esc键 :wq 退出
重启服务 service dhcpd restart
nesysv 选择dhcpd 按“空格键” 点“ok”
查看是否启用
ps -e
netstat -ln | grep 67
tail /car/log/messages