From Wikipidia :
The Domain Name System (DNS) is a hierarchical naming system built on a distributed database for computers, services, or any resource connected to the Internet or a private network. It associates various information with domain names assigned to each of the participating entities.
Atau secara sederhana DNS adalah mentranslasikan bentuk IP ADDRESS ke dalam bentuk penamaan yang lebih manusiawi atau lebih mudah diingingat.
Contoh kali ini menggunakan ubuntu 10.04 LTS
- dns contoh mempunyai domain yang yaitu coba.net
- DNS primary 10.10.10.1 , DNS secondary 10.10.10.2
–INSTALLING DNS TO PRIMARY–
Setup BIND9 :
sudo apt-get install bind9
Setelah proses setup selesai dan tidak terdapat eror edit file /etc/resolv.conf
search coba.net nameserver 10.10.10.1
Edit konfigurasi di /etc/bind/named.conf.local
nano /etc/bind/named.conf.local
//This file contains all local and changable info.
//Begin File - by creating the following entry:
//----------- Begin coba.net ------------
zone "kartbuilding.net" {
type master;
file "/etc/bind/coba.net";
allow-transfer { 10.10.10.2; }; ; Note this line is only for
;a secondary nameserver, allowing for zone transfer.
};
//The next is the reverse DNS entry.
zone "10.10.10.in-addr.arpa" {
type master;
file "/etc/bind/10.db";
};
//------------ End of coba.net ----------
membuat file zone coba.net
sudo nano /etc/bind/coba.net //Begin file -------------------------------- $TTL 3h @ IN SOA ns.coba.net. root.coba.net. ( 2010102501 ; counter/ Serial ; in the format YYYYMMDDCC where CC - counter 1 to 99 15m ; refresh 15m ; Retry Interval 1w ; Expire 1h ) ; Negative Cache TTL IN NS ns.coba.net. ; dns utama atau primary IN NS ns1.coba.net.; dns secodary ns IN A 10.10.10.1 ns1 IN A 10.10.10.2 @ IN A 10.10.10.1 ; @ digunakan untuk nama tanpa www. //End file ------------------------------------
Membuat reserve zone DNS
sudo nano /etc/bind/10.db
//Start of file -------------------------
@ IN SOA ns.coba.net. root.coba.net. (
2010102501 ; counter/ Serial
15m ; refresh
15m ; Retry Interval
1w ; Expire
1h ) ; Negative Cache TTL
IN NS ns.coba.net.
IN NS ns1.coba.net.
1 IN PTR ns.coba.net.
2 IN PTR ns1.coba.net.
//End of file ---------------------------
Setting DNS secondary dengan alamat IP 10.10.10.2
edit atau tambahkan konfigurasi file
nano /etc/bind/named.conf.local
//add the following lines:
zone "coba.net" {
type slave;
file "/etc/bind/slaves/coba.net";
masters { 10.10.10.1; };
allow-transfer { 10.10.10.1; };
};
// buat direktori /etc/bind/slaves dan rubah owner ke user bind
sudo mkdir /etc/bind/slaves sudo chown bind:bind /etc/bind/slaves
setelah selesai semua konfigurasi baik primary maupun secondary restart konfigurasi bind
di kedua server
sudo /etc/init.d/bind9 restart
untuk mengecek apakah semua konfigurasi telah benar pastikan setelah reload tidak eror message yang
tampil.. –END–

