开启dhcp服务
在虛擬中操作
1.rht-vmctl reset? desktop? ##在主機中
2.vim /etc/sysconfig/network-scripts/ifcfg-eth0 ##編輯網(wǎng)絡(luò)配置
3.systemctl restart network??? ##重啟網(wǎng)絡(luò)配置
4.yum install dncp.x86_64 -y ##安裝dhcp服務(wù)組件
5.cd /etc/dhcp/?
6.ls? ##查看有沒有文件
7.vim dhcpd.conf
8.cp /usr/share/doc/dhcp*/dhcpd.conf.example /etc/dhcp/dhcpd.conf?? ##復(fù)制示例文檔
9. vim dhcpd.conf? ##編輯配置文檔
?? option domain-name-servers 114.114.114.114;
??? # DHCP server to understand the network topology.
???
???
???
???
??? # This is a very basic subnet declaration.
????? subnet 172.25.254.0 netmask 255.255.255.0 {
????? range 172.25.254.200 172.25.254.210;
????? option routers 172.25.254.250;
10.systemctl start dhcpd? ##開啟dhcp服務(wù)
11.systemctl enable dhcpd ##系統(tǒng)啟用
測試:
rht-vmctl? reset? server ##在主機中
rht-vmctl? view? server? ##在主機中
ifconfig
總結(jié)
- 上一篇: To B 业务 vs To C 业务
- 下一篇: Java核心技术·卷二·第一章笔记