1.DHCP服务
(1)安装dhcp软件包
yum -y install dhcp
(2)修改配置文件
vim /etc/dhcp/dhcpd.conf
(3)添加以下配置
subnet 172.25.0.0 netmask 255.255.255.0 {
range 172.25.0.100 172.25.0.200;
default-lease-time 600;
max-lease-time 11200;
next-server 172.25.0.11;
filename "pxelinux.0";
}
1.png
(4)重启服务并设置服务开机自启
systemctl restart dhcpd
systemctl enable dhcpd
(5)新建空白虚拟机,简单验证
创建完虚拟机后开机
2.png
网友评论