BIND 9 configuration method

Source: Internet
Author: User
Tags bind ftp

Bind 9 configuration method

/Etc/named. conf

Options {
Directory "/var/named ";

};

# Named. root is available at ftp://ftp.internic.net/domain/named.root

Zone "." in {
Type hint;
File "named. root ";
};

# Here is zone for domain ustrem.org

Zone "ustrem.org" in {
Type master;
File "ustrem.org ";
Allow-transfer {none ;};
Allow-update {none ;};

};

# Here is reverse zone for net 192.168.2.0/255.255.255.0

Zone "limit 192.in-addr. arpa "{
Type master;
File "loc ";
Allow-update {none ;};
};

----------------------------------------------------

Here is ustrem.org's zone file

-----------------------------

/Var/named/ustrem.org

$ Origin.
$ Ttl 86400; 1 day
Ustrem.org in soa pns.ustrem.org. onzi.ustrem.org .(

# Onzi.ustrem.org is email for contacts (onzi_at_ustrem_dot_org)


2006083102; serial

# This is stamp for date and time and number of day change


3600; refresh (8 hours)
1800; retry (4 hours)
86400; expire (5 weeks 6 days 16 hours)
3600; minimum (1 day)
                                )
Ns pns.ustrem.org.
Ns ns1.xname.org.

# Ns records for domain


A 213.240.243.12

# This line shows "ustrem.org" is with ip 213.240.243.12


Mx 10 mail.ustrem.org.

# Here is smtp server which received mails for ustrem.org


Txt "v = spf1 mx a: mail.b-trust.org a: mailrelay.bsbg.net-all"

# This is text record for prevent from spammers and spoofers. here is smtp-s which sends emails from ustrem.org

$ Origin ustrem.org.

* A 213.240.243.12

# Some-does-not-described.ustrem.org is with ip 213.240.243.12


Bobi a 213.240.227.125
Pns a 213.240.243.12

*. Bobi cname bobi.ustrem.org.

Boiko a 84.238.128.65
George a 213.240.242.107

 

Laptoper4e a 192.168.2.18
Mitkosipc a 192.168.2.4
Pi-server a 192.168.2.15
Pz a 217.10.245.249
Router a 192.168.2.24

----------------------------------------------------------------------------------

Here is reverse resolv

---------------------------------------------

/Var/named/loc

$ Origin.
$ Ttl 86400; 1 day
2017192.in-addr. arpa in soa pns.ustrem.org. onzi.ustrem.org .(
2006080302; serial
28800; refresh (8 hours)
14400; retry (4 hours)
3600000; expire (5 weeks 6 days 16 hours)
86400; minimum (1 day)
                                )
Ns pns.ustrem.org.
Ns sns.ustrem.org.

$ Origin limit 192.in-addr. arpa.
4 ptr mitkosipc.ustrem.org.
18 ptr laptoper4e.ustrem.org.
15 ptr pi-server.ustrem.org.
24 ptr router.ustrem.org.


 

---------------------------------------------

This is enougt for bind9 to work.

Now you can start and test it ....

# Dig ustrem.org @ 127.0.0.1

; Question section:
; Ustrem.org. in

; Answer section:
Ustrem.org. 86400 in a 213.240.243.12

# Dig ustrem.org @ 127.0.0.1 mx

; Question section:
; Ustrem.org. in mx

; Answer section:
Ustrem.org. 86400 in mx 10 mail.ustrem.org.

# Dig-x 192.168.2.4 @ 127.0.0.1

; Question section:
; 4.20.192.in-addr. arpa. in ptr

; Answer section:
4.20.192.in-addr. arpa. 86400 in ptr mitkosipc.ustrem.org.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.