Wednesday, February 20, 2013

Cara Install DNS dan Konfigurasi DNS di Debian

Pertama install bind9 dengan perintah seperti berikut


# apt-get install bind9 bind9-doc dnsutils



Lalu edit file konfigurasi di /etc/bind/named.conf.local dengan menambahkan baris berikut.

# nano /etc/bind/named.conf.local


zone "smeksa.edu" {
 type master;
 file "/etc/bind/db.smeksa";
};
zone "1.168.192.in-addr.arpa" {
 type master;
 file "/etc/bind/db.192.168.1";
};



Buat file dengan nama db.smeksa di /etc/bind/ dan tambahkan baris berikut

# nano /etc/bind/db.smeksa


 ; BIND data file for smeksa.edu
$TTL 604800
@ IN  SOA smeksa.edu. root.smeksa.edu. (
   1                 ; Serial
   604800         ; Refresh
   86400         ; Retry
   2419200 ; Expire (28 hari)
   604800        ); Negative Cache TTL (1 Minggu)
;
  NS  ns.smeksa.edu.
  NS  ns1.internux.net.id.
  NS  ns2.internux.net.id.
;
  MX 10  mail.smeksa.edu.
;
smeksa.edu A 192.168.1.3
www  A 192.168.1.3
ftp          A      192.168.1.3
debian  A 192.168.1.3
mail  A 192.168.1.3
ldap  A 192.168.1.3
proxy  A 192.168.1.3
ns          A 192.168.1.3
smeksa.edu.  TXT "v=spf1 a mx ~all"
debian.smeksa.edu. TXT "v=spf1 a -all"
 

lalu tambahkan juga pada file db.

# nano /etc/bind/db.192.168.1

; BIND reverse data file for smeksa.edu
$TTL 604800
@  IN  SOA  smeksa.edu. root.smeksa.edu. (
   1              ; Serial Number 
   604800      ; Refresh timeout
   86400      ; Retry timeout
   2419200     ; Expire
   604800      ); Negative Cache TTL
;
  NS ns.smeksa.edu.
  NS ns2.internux.net.id.
  NS ns3.internux.net.id.
;
;
3  PTR www.smeksa.edu.
3  PTR ftp.smeksa.edu.
3  PTR debian.smeksa.edu.
3  PTR mail.smeksa.edu.
3  PTR ldap.smeksa.edu.
3  PTR proxy.smeksa.edu.
3  PTR ns.smeksa.edu.

tambahkan nameserver pada file konfigurasi /etc/resolv.conf.



# nano /etc/resolv.conf


nameserver 192.168.1.3
nameserver 202.62.16.35





















Next
This is the most recent post.
Older Post

0 comments:

Post a Comment