Langkah-langkahnya :
apt-get update
apt-get install bind9
apt-get update
apt-get install bind9
root@ubuntu:/home/ab# cd /etc/bind
root@ubuntu:/etc/bind# ls
bind.keys db.empty named.conf.default-zones zones.rfc1918
db.0 db.local named.conf.local
db.127 db.root named.conf.options
db.255 named.conf rnd
root@ubuntu:/etc/bind# ls
bind.keys db.empty named.conf.default-zones zones.rfc1918
db.0 db.local named.conf.local
db.127 db.root named.conf.options
db.255 named.conf rnd
root@ubuntu:/etc/bind# cp db.127 db.254
root@ubuntu:/etc/bind# cp db.local db.kusnadi
root@ubuntu:/etc/bind# cp named.conf.default-zones named.conf.default-zones2
root@ubuntu:/etc/bind# ls
bind.keys db.255 db.root named.conf.local
db.0 db.empty named.conf named.conf.options
db.127 db.kusnadi named.conf.default-zones rndc.key
db.254 db.local named.conf.default-zones2 zones.rfc1918
root@ubuntu:/etc/bind#
root@ubuntu:/etc/bind# cp db.local db.kusnadi
root@ubuntu:/etc/bind# cp named.conf.default-zones named.conf.default-zones2
root@ubuntu:/etc/bind# ls
bind.keys db.255 db.root named.conf.local
db.0 db.empty named.conf named.conf.options
db.127 db.kusnadi named.conf.default-zones rndc.key
db.254 db.local named.conf.default-zones2 zones.rfc1918
root@ubuntu:/etc/bind#
nano db.254
;
; BIND reverse data file for local loopback interface
;
$TTL 604800
@ IN SOA kusnadi.com. root.kusnadi.com. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS kusnadi.com.
1 IN PTR kusnadi.com.
1 IN PTR http://www.kusnadi.com.
1 IN PTR ftp.kusnadi.com.
1 IN PTR mail.kusnadi.com.
nano db.kusnadi
;
; BIND data file for local loopback interface
;
$TTL 604800
@ IN SOA kusnadi.com. root.kusnadi.com. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS kusnadi.com.
@ IN A 172.16.10.1
@ IN AAAA ::1
www IN A 172.16.10.1
ftp IN A 172.16.10.1
mail IN A 172.16.10.1
;
; BIND reverse data file for local loopback interface
;
$TTL 604800
@ IN SOA kusnadi.com. root.kusnadi.com. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS kusnadi.com.
1 IN PTR kusnadi.com.
1 IN PTR http://www.kusnadi.com.
1 IN PTR ftp.kusnadi.com.
1 IN PTR mail.kusnadi.com.
nano db.kusnadi
;
; BIND data file for local loopback interface
;
$TTL 604800
@ IN SOA kusnadi.com. root.kusnadi.com. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS kusnadi.com.
@ IN A 172.16.10.1
@ IN AAAA ::1
www IN A 172.16.10.1
ftp IN A 172.16.10.1
mail IN A 172.16.10.1
#nano named.conf.default-zones
// prime the server with knowledge of the root servers
zone “.” {
type hint;
file “/etc/bind/db.kusnadi”;
};
zone “.” {
type hint;
file “/etc/bind/db.kusnadi”;
};
// be authoritative for the localhost forward and reverse zones, and for
// broadcast zones as per RFC 1912
// broadcast zones as per RFC 1912
zone “kusnadi.com” {
type master;
file “/etc/bind/db.kusnadi”;
};
type master;
file “/etc/bind/db.kusnadi”;
};
zone “10.16.172.in-addr.arpa” {
type master;
file “/etc/bind/db.254”;
};
type master;
file “/etc/bind/db.254”;
};
nano /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND — YOUR CHANGES WILL BE OVERWRITTEN
nameserver 172.16.10.1
# DO NOT EDIT THIS FILE BY HAND — YOUR CHANGES WILL BE OVERWRITTEN
nameserver 172.16.10.1
Hasil verifikasi
root@ubuntu:/etc/bind# nslookup 172.16.10.1
Server: 172.16.10.1
Address: 172.16.10.1#53
Server: 172.16.10.1
Address: 172.16.10.1#53
1.10.16.172.in-addr.arpa name = mail.kusnadi.com.
1.10.16.172.in-addr.arpa name = kusnadi.com.
1.10.16.172.in-addr.arpa name = ftp.kusnadi.com.
1.10.16.172.in-addr.arpa name = http://www.kusnadi.com.
1.10.16.172.in-addr.arpa name = kusnadi.com.
1.10.16.172.in-addr.arpa name = ftp.kusnadi.com.
1.10.16.172.in-addr.arpa name = http://www.kusnadi.com.
root@ubuntu:/etc/bind# nslookup kusnadi.com
Server: 172.16.10.1
Address: 172.16.10.1#53
Server: 172.16.10.1
Address: 172.16.10.1#53
Name: kusnadi.com
Address: 172.16.10.1
Address: 172.16.10.1
Name: http://www.kusnadi.com
Address: 172.16.10.1
Address: 172.16.10.1
root@ubuntu:/etc/bind# nslookup mail.kusnadi.com
Server: 172.16.10.1
Address: 172.16.10.1#53
Server: 172.16.10.1
Address: 172.16.10.1#53
Name: mail.kusnadi.com
Address: 172.16.10.1
Address: 172.16.10.1
root@ubuntu:/etc/bind# nslookup ftp.kusnadi.com
Server: 172.16.10.1
Address: 172.16.10.1#53
Server: 172.16.10.1
Address: 172.16.10.1#53
Name: ftp.kusnadi.com
Address: 172.16.10.1
Address: 172.16.10.1
selesai…
0 komentar:
Posting Komentar