一.准备工作
项目名称 | 基础信息 |
---|
操作系统 | Centos7.8 |
IP地址 | 192.168.250.219 |
SElinux | 已关闭 |
防火墙 | 已启用,开放相关端口:UDP/67和UDP/68 |
DHCP地址池 | 192.168.250.2-192.168.250.90 |
二.部署DHCP服务器
1.yum方式安装dhcp服务
[root@dhcp-server ~]# yum -y install dhcp已加载插件:fastestmirror, langpacksLoading mirror speeds from cached hostfile
2.查看dhcpd.conf默认配置文件的内容
默认情况下,dhcpd.conf配置文件在 /etc/dhcp/
目录下,默认的配置内容为空,如下:
[root@dhcp-server ~]# cd /etc/dhcp[root@dhcp-server dhcp]# ll总用量 8drwxr-xr-x. 2 root root 236月 102021 dhclient.ddrwxr-xr-x. 2 root root 284月 1216:09 dhclient-exit-hooks.d-rw-r--r--. 1 root root 1206月 102021 dhcpd6.conf-rw-r--r--. 1 root root 1176月 102021 dhcpd.confdrwxr-x---. 2 root dhcpd 284月 1216:09 scripts[root@dhcp-server dhcp]# cat dhcpd.conf## DHCP Server Configuration file.# see /usr/share/doc/dhcp*/dhcpd.conf.example# see dhcpd.conf(5) man page#[root@dhcp-server dhcp]#