Monday, August 08, 2011

Install and Setting DHCP Server

Install DHCP Server
#  apt-get install dhcp3-server












After install DHCP Server, setting DHCP3 Server, example with asumsion network at eth1 range IP 192.168.0.100-192.168.0.200 netmask 255.255.255.0. Edit file conf DHCP 3 is /etc/dhcp3/dhcp.conf.
# pico /etc/dhcp3/dhcp.conf
change with
ddns-update-style none;

subnet 192.168.0.0 netmask 255.255.255.0 { option broadcast-address 192.168.0.255; option subnet-mask 255.255.255.0;
option domain-name-servers 192.168.0.1;
option domain-name "local.domain"; #sesuaikan keinginan
option routers 192.168.0.1;
option netbios-name-servers 192.168.0.1;

default-lease-time 600;
max-lease-time 604800;

log-facility local7;

range 192.168.0.100 192.168.0.200;
}
Note:
for option-name-servers you can change with DNS ISP
option netbios-name-servers  you can  delete if not create WINS Server

Edit file /etc/default/dhcp3-server and settinh DHCPdefault interfaces.
# pico /etc/default/dhcp3-server
change name interface"INTERFACES= eth1"

Restart DHCP3-server
# /etc/init.d/dhcp-server restart
 Starting DHCP server dhcp3              [    OK   ]


DHCP you can create same ad MAC Filter, we note all MAC-ADDRESS from all hardware Ethernet wifi or client when give  IP change  /etc/dhcp3/dhcp.conf, example configuration with MAC FIltering:


ddns-update-style none;

subnet 192.168.0.0 netmask 255.255.255.0 { option broadcast-address 192.168.0.255; option subnet-mask 255.255.255.0;
option domain-name-servers 192.168.0.1;
option domain-name "local.domain"; #sesuaikan keinginan
option routers 192.168.0.1;
option netbios-name-servers 192.168.0.1;

default-lease-time 600;
max-lease-time 604800;

log-facility local7;

host opikdesign {
hardware ethernet 00:22:15:3C:14:A1;
fixed-address 192.168.0.100;
}

host dhani {
hardware ethernet 00:11:5B:78:D3:E8;
fixed-address 192.168.0.101;
}

host farah {
hardware ethernet 00:16:EC:1E:2F:9E;
fixed-address 192.168.0.102;
}

host siti {
hardware ethernet 00:13:D4:CB:69:0F;
fixed-address 192.168.0.103;
}
}
 

0 comments:

Post a Comment