DHCP Server Ubuntu
Distro Linux sangat banyak beberapa diantaranya ada Redhat, Mandriva, Fedora, Ubuntu dll.
Instalasi
sudo apt-get install dhcp3-server
Konfigurasi file
/etc/dhcp3/dhcpd.conf
dns-update-style none;
default-lease-time 600;
max-lease-time 7200;
log-facility local7;
subnet 192.168.0.0 netmask 255.255.255.0 {
range 192.168.0.50 192.168.0.253;
option domain-name-servers 192.168.0.254;
option domain-name "example.com";
option routers 192.168.0.254;
option broadcast-address 192.168.0.255;
default-lease-time 600;
max-lease-time 7200;
}
subnet 192.168.4.0 netmask 255.255.255.0 {
range 192.168.4.50 192.168.4.253;
option domain-name-servers 192.168.0.254;
option domain-name "example.com";
option routers 192.168.4.254;
option broadcast-address 192.168.4.255;
default-lease-time 600;
max-lease-time 7200;
}
subnet 192.168.6.0 netmask 255.255.255.0 {
range 192.168.6.50 192.168.6.253;
option domain-name-servers 192.168.0.254;
option domain-name "example.com";
option routers 192.168.6.254;
option broadcast-address 192.168.6.255;
default-lease-time 600;
max-lease-time 7200;
}
Konfigurasi file (interface yang akan diaktifkan dhcp-server)
/etc/default/dhcp3-server
# Defaults for dhcp initscript
# sourced by /etc/init.d/dhcp
# installed at /etc/default/dhcp3-server by the maintainer scripts
#
# This is a POSIX shell fragment
#
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
# Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACES="eth0 eth3 eth5"
Menjalankan service
sudo /etc/init.d/dhcp3-server restart
Distro Linux sangat banyak beberapa diantaranya ada Redhat, Mandriva, Fedora, Ubuntu dll.
Untuk configurasi dhcp server pada beberapa distro kurang lebih sama. Sebagai catatan kecil saya tuliskan konfigurasi dhcp server untuk Ubuntu. Yang secara kebetulan ditempat saya bekerja digunakan distro tersebut, dimana terkada ng saya terlupa beberapa konfigurasi untuk dhcp server ubuntu, karena sebelumnya saya sering menggunakan dhcp server di redhat/fedora.
Instalasi
sudo apt-get install dhcp3-server
Konfigurasi file
/etc/dhcp3/dhcpd.conf
dns-update-style none;
default-lease-time 600;
max-lease-time 7200;
log-facility local7;
subnet 192.168.0.0 netmask 255.255.255.0 {
range 192.168.0.50 192.168.0.253;
option domain-name-servers 192.168.0.254;
option domain-name "example.com";
option routers 192.168.0.254;
option broadcast-address 192.168.0.255;
default-lease-time 600;
max-lease-time 7200;
}
subnet 192.168.4.0 netmask 255.255.255.0 {
range 192.168.4.50 192.168.4.253;
option domain-name-servers 192.168.0.254;
option domain-name "example.com";
option routers 192.168.4.254;
option broadcast-address 192.168.4.255;
default-lease-time 600;
max-lease-time 7200;
}
subnet 192.168.6.0 netmask 255.255.255.0 {
range 192.168.6.50 192.168.6.253;
option domain-name-servers 192.168.0.254;
option domain-name "example.com";
option routers 192.168.6.254;
option broadcast-address 192.168.6.255;
default-lease-time 600;
max-lease-time 7200;
}
Konfigurasi file (interface yang akan diaktifkan dhcp-server)
/etc/default/dhcp3-server
# Defaults for dhcp initscript
# sourced by /etc/init.d/dhcp
# installed at /etc/default/dhcp3-server by the maintainer scripts
#
# This is a POSIX shell fragment
#
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
# Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACES="eth0 eth3 eth5"
Menjalankan service
sudo /etc/init.d/dhcp3-server restart