CentOS DNS Kurulumu

RedBytes

Guest
New
Activity

0%

Longevity

86%

LV
1
 
Joined
Apr 22, 2020
Messages
17
Reaction score
5
Time online
1h 17m
Awards
1
Warez Point
101.0
Offline
  • Sunucu ismi : dns1.abc.com
  • Sunucu ip’si : 192.168.100.20/24
Gerekli paketleri yükleyelim;
Code:
# yum -y install bind bind-libs bind-utils
Başlangıçta servisin otomatik çalışması için;
Code:
# chkconfig –-level 35 named on
Servisin başlangıçta standart config dosyasını oluşturması için;
Code:
# service named start
Oluşturulmuş olan config dosyasını aşağıdaki kod ile editlersek;

Code:
//
// named.conf
//
// Provided by Red Hat bind package to configure the ISC BIND named(8) DNS
// server as a caching only nameserver (as a localhost DNS resolver only).
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
options
        directory       “/var/named”;
        dump-file       “/var/named/data/cache_dump.db”;
        statistics-file “/var/named/data/named_stats.txt”;
        memstatistics-file “/var/named/data/named_mem_stats.txt”;
        recursion yes;
        dnssec-enable yes;
        dnssec-validation yes;
        dnssec-lookaside auto;
        /* Path to ISC DLV key */
        bindkeys-file “/etc/named.iscdlv.key”;
;
logging
        channel default_debug
                file “data/named.run”;
                severity dynamic;
        ;
;
zone “.” IN
        type hint;
        file “named.ca”;
;
zone “abc.com”
        type master;
        file “abc.com.fwd”;
;
zone “0.168.192.in-addr.arpa”
        type master;
        file “abc.com.rev”;
;
include “/etc/named.rfc1912.zones”;
named.conf dosyasında isimleri girdiğimizde;
cd /var/named
# vi abc.com.fwd
$ORIGIN abc.com.
$TTL 3D
@SOA     dns.abc.com.     root.abc.com. (12 4h 1h 1w 1h)
@IN      NS      dns.abc.com.
dns.abc.com.     IN      A       192.168.100.20
www              IN      A       192.168.100.20
# vi abc.com.rev
$ORIGIN 0.168.192.in-addr.arpa.
$TTL 3D
@       SOA     dns.abc.com.     root.abc.com. (12 4h 1h 1w 1h)
@       IN      NS      dns.abc.com.
211     IN      PTR     dns.abc.com.

Reset
Code:
# service named restart

Test
Code:
# cat /etc/resolve.conf
search abc.com
nameserver 192.168.100.20
# nslookup www.abc.com
Server:         192.168.100.20
Address:        192.168.100.20#53
Name:   www.abc.com
Address: 192.168.100.20
 

SinanSS

Friend
New
Activity

0%

Longevity

88%

LV
1
 
Joined
Apr 5, 2020
Messages
41
Reaction score
0
Time online
8h 45m
Awards
1
Warez Point
44.0
Offline
yararlı konu teşekkürler
 

real

Guest
New
Activity

0%

Longevity

3%

LV
1
 
Joined
Nov 11, 2021
Messages
10
Reaction score
0
Time online
1h 15m
Awards
1
Warez Point
0.0
Offline

hacker0088

Guest
Sülük
New
Activity

0%

Longevity

4%

LV
1
 
Joined
Nov 5, 2021
Messages
5
Reaction score
0
Time online
19m
Awards
1
Warez Point
5.0
Offline

unique

Guest
New
Activity

0%

Longevity

7%

LV
1
 
Joined
Oct 16, 2021
Messages
7
Resources
6
Reaction score
12
Time online
1h 49m
Awards
1
Warez Point
51.0
Offline
Thanks for share
 

msd43msd

Guest
New
Activity

0%

Longevity

21%

LV
1
 
Joined
Jul 6, 2021
Messages
10
Reaction score
0
Time online
5h 26m
Awards
1
Website
msdmedyam.com
Warez Point
1.0
Offline
  • Sunucu ismi : dns1.abc.com
  • Sunucu ip’si : 192.168.100.20/24
Gerekli paketleri yükleyelim;
Code:
# yum -y install bind bind-libs bind-utils
Başlangıçta servisin otomatik çalışması için;
Code:
# chkconfig –-level 35 named on
Servisin başlangıçta standart config dosyasını oluşturması için;
Code:
# service named start
Oluşturulmuş olan config dosyasını aşağıdaki kod ile editlersek;

Code:
//
// named.conf
//
// Provided by Red Hat bind package to configure the ISC BIND named(8) DNS
// server as a caching only nameserver (as a localhost DNS resolver only).
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
options
        directory       “/var/named”;
        dump-file       “/var/named/data/cache_dump.db”;
        statistics-file “/var/named/data/named_stats.txt”;
        memstatistics-file “/var/named/data/named_mem_stats.txt”;
        recursion yes;
        dnssec-enable yes;
        dnssec-validation yes;
        dnssec-lookaside auto;
        /* Path to ISC DLV key */
        bindkeys-file “/etc/named.iscdlv.key”;
;
logging
        channel default_debug
                file “data/named.run”;
                severity dynamic;
        ;
;
zone “.” IN
        type hint;
        file “named.ca”;
;
zone “abc.com”
        type master;
        file “abc.com.fwd”;
;
zone “0.168.192.in-addr.arpa”
        type master;
        file “abc.com.rev”;
;
include “/etc/named.rfc1912.zones”;
named.conf dosyasında isimleri girdiğimizde;
cd /var/named
# vi abc.com.fwd
$ORIGIN abc.com.
$TTL 3D
@SOA     dns.abc.com.     root.abc.com. (12 4h 1h 1w 1h)
@IN      NS      dns.abc.com.
dns.abc.com.     IN      A       192.168.100.20
www              IN      A       192.168.100.20
# vi abc.com.rev
$ORIGIN 0.168.192.in-addr.arpa.
$TTL 3D
@       SOA     dns.abc.com.     root.abc.com. (12 4h 1h 1w 1h)
@       IN      NS      dns.abc.com.
211     IN      PTR     dns.abc.com.

Reset
Code:
# service named restart

Test
Code:
# cat /etc/resolve.conf
search abc.com
nameserver 192.168.100.20
# nslookup www.abc.com
Server:         192.168.100.20
Address:        192.168.100.20#53
Name:   www.abc.com
Address: 192.168.100.20
yararlı içerik teşekkürler
 

DMCA & Contact


Any DMCA takedown notice should be sent to this contact email: [email protected] We only respond and take action to plaintext e-mails. Do not send PDF or any other files.
Top
AdBlock Detected

We get it, advertisements are annoying!

Sure, ad-blocking software does a great job at blocking ads, but it also blocks useful features of our website. For the best site experience please disable your AdBlocker.

I've Disabled AdBlock