ubuntu18.04 搭建DHCP(isc-dhcp-server)

DHCP config

1.install DHCP server

sudo apt-get install isc-dhcp-server

 

There are two main configuration files for DHCP: /etc/default/isc-dhcp-server and /etc/dhcp/dhcpd.conf

2.configuration DHCP server

ifconfig

get network card name: for example

ubuntu18.04 搭建DHCP(isc-dhcp-server)_第1张图片

 

next configuration /etc/default/isc-dhcp-server file

 

sudo vim /etc/default/isc-dhcp-server

 ubuntu18.04 搭建DHCP(isc-dhcp-server)_第2张图片

mofify INTERFACES="eno1"

 

sudo vim /etc/dhcp/dhcpd.conf

 ubuntu18.04 搭建DHCP(isc-dhcp-server)_第3张图片

ubuntu18.04 搭建DHCP(isc-dhcp-server)_第4张图片

add subnet information above

 

3.configuration Wired Network

modify wired network configuration, as follow:

ubuntu18.04 搭建DHCP(isc-dhcp-server)_第5张图片

 

4.Run

sudo service isc-dhcp-server restart

sudo service isc-dhcp-server status

ubuntu18.04 搭建DHCP(isc-dhcp-server)_第6张图片

Successful running as above

 

你可能感兴趣的:(ubuntu,linux)