Difference between revisions of "Raspbian: install DHCP server"
Jump to navigation
Jump to search
Onnowpurbo (talk | contribs) (Created page with "Instalasi sudo su apt update apt install isc-dhcp-server Edit default vi /etc/default/isc-dhcp-server INTERFACESv4="eth0" Konfigurasi vi /etc/dhcp/dhcpd.conf Pa...") |
Onnowpurbo (talk | contribs) |
||
(3 intermediate revisions by the same user not shown) | |||
Line 10: | Line 10: | ||
vi /etc/default/isc-dhcp-server | vi /etc/default/isc-dhcp-server | ||
− | INTERFACESv4="eth0" | + | INTERFACESv4="eth0 wlan0" |
Konfigurasi | Konfigurasi | ||
Line 17: | Line 17: | ||
Parameter | Parameter | ||
+ | |||
+ | ddns-updates on; | ||
+ | ddns-update-style interim; | ||
+ | ddns-domainname "mydomain.home"; | ||
+ | ddns-rev-domainname "0.1.10.in-addr.arpa"; | ||
+ | ignore client-updates; | ||
+ | # If you have fixed-address entries you want to use dynamic dns | ||
+ | update-static-leases on; | ||
+ | |||
+ | # option definitions common to all supported networks... | ||
+ | option domain-name "mydomain.home"; | ||
+ | option domain-name-servers 192.168.11.10, 192.168.4.10; | ||
+ | option ntp-servers 0.pool.ntp.org, 1.pool.ntp.org, 2.pool.ntp.org, 3.pool.ntp.org; | ||
+ | |||
+ | default-lease-time 600; | ||
+ | max-lease-time 7200; | ||
+ | |||
+ | ping-check true; | ||
+ | ping-timeout 2; | ||
authoritative; | authoritative; | ||
# A slightly different configuration for an internal subnet. | # A slightly different configuration for an internal subnet. | ||
− | subnet | + | subnet 192.168.11.0 netmask 255.255.255.0 { |
− | range | + | range 192.168.11.100 192.168.11.200; |
− | option domain-name-servers | + | option domain-name-servers 192.168.11.10, 192.168.11.10; |
option domain-name "sekolah.sch.id"; | option domain-name "sekolah.sch.id"; | ||
− | option routers | + | option routers 192.168.11.10; |
− | option broadcast-address | + | option broadcast-address 192.168.11.255; |
default-lease-time 600; | default-lease-time 600; | ||
max-lease-time 7200; | max-lease-time 7200; | ||
} | } | ||
+ | |||
+ | # A slightly different configuration for an internal subnet. | ||
+ | subnet 192.168.4.0 netmask 255.255.255.0 { | ||
+ | range 192.168.4.100 192.168.4.200; | ||
+ | option domain-name-servers 192.168.4.10, 192.168.4.10; | ||
+ | option domain-name "sekolah.sch.id"; | ||
+ | option routers 192.168.4.10; | ||
+ | option broadcast-address 192.168.4.255; | ||
+ | default-lease-time 600; | ||
+ | max-lease-time 7200; | ||
+ | } | ||
Latest revision as of 19:46, 18 October 2018
Instalasi
sudo su apt update apt install isc-dhcp-server
Edit default
vi /etc/default/isc-dhcp-server
INTERFACESv4="eth0 wlan0"
Konfigurasi
vi /etc/dhcp/dhcpd.conf
Parameter
ddns-updates on; ddns-update-style interim; ddns-domainname "mydomain.home"; ddns-rev-domainname "0.1.10.in-addr.arpa"; ignore client-updates; # If you have fixed-address entries you want to use dynamic dns update-static-leases on;
# option definitions common to all supported networks... option domain-name "mydomain.home"; option domain-name-servers 192.168.11.10, 192.168.4.10; option ntp-servers 0.pool.ntp.org, 1.pool.ntp.org, 2.pool.ntp.org, 3.pool.ntp.org; default-lease-time 600; max-lease-time 7200; ping-check true; ping-timeout 2;
authoritative; # A slightly different configuration for an internal subnet. subnet 192.168.11.0 netmask 255.255.255.0 { range 192.168.11.100 192.168.11.200; option domain-name-servers 192.168.11.10, 192.168.11.10; option domain-name "sekolah.sch.id"; option routers 192.168.11.10; option broadcast-address 192.168.11.255; default-lease-time 600; max-lease-time 7200; }
# A slightly different configuration for an internal subnet. subnet 192.168.4.0 netmask 255.255.255.0 { range 192.168.4.100 192.168.4.200; option domain-name-servers 192.168.4.10, 192.168.4.10; option domain-name "sekolah.sch.id"; option routers 192.168.4.10; option broadcast-address 192.168.4.255; default-lease-time 600; max-lease-time 7200; }