DHCP服务器

(1)

安装dhcp3-server:apt-get install dhcp3-server

(2)

a、gedit /etc/default/dhcp3-server

INTERFACES="eth1"

b、gedit /etc/dhcp3/dhcpd.conf

subnet 192.168.0.0 netmask 255.255.255.0 {
range 192.168.0.2 192.168.0.254;
option domain-name-servers 192.168.0.1,202.117.112.3;
option subnet-mask 255.255.255.0;
option routers 192.168.0.1;
option broadcast-address 192.168.0.255;
default-lease-time 86400;
max-lease-time 172800;
}

host WorkStation{
        hardware ethernet 2c:41:38:94:51:90;
        fixed-address 192.168.0.30;
}

注:主机名任意,若客户端手动配置,以客户端配置为准。

(3)

/etc/init.d/dhcp3-server start

你可能感兴趣的:(DHCP)