DNS view and log Pressure Test

Source: Internet
Author: User

1. Configure the access control list at the top of the/etc/named. conf file.
ACL innct {
192.168.1.0/24;
127.0.0.0/8;
};
Allow query {innct ;};

2-View
Named. conf

ACL Telecom {
192.168.1.0/24;
127.0.0.8;
};

ACL Unicom {
192.161.14.0/24;
127.0.0.8;
};

Options {
Directory "/var/named ";
Allow-recursion {innet ;};
};
View Telecom {
Match-clients {Telecom ;};
Zone "xingxing.com" in {
Type master;
File "telecom.xingxing.com. Zone ";
};
Zone "xx.com" in {
Type master;
File "xx.com. Zone ";
};
};
View Unicom {
Match-clients {Unicom ;};
Zone "xingxing.com" in {
Type master;
File "unicom.xingxing.com. Zone ";
};
Zone "xx.com" in {
Type master;
File "xx.com. Zone ";
};
};


Vim/var/named/telecom.xingxing.com. Zone

$ TTL 43200
@ In SOA dns.xingxing.com. Root (
2
1 H
10 m
7D
1D)
@ In NS DNS
@ In MX 10 mail
DNS in a 192.168.1.5
Mail in a 192.168.1.5
Na in a 192.168.1.3


Vim/var/named/iunicom/unicom.xingxing.com. Zone
$ TTL 43200
@ In SOA dns.xingxing.com. Root (
2
1 H
10 m
7D
1D)
@ In NS DNS
@ In MX 10 mail
DNS in a 192.168.1.5
Mail in a 192.168.1.5
Na in a 192.161.14.3

3-enable dnslog


Vim/etc/named. conf
Options {
Querylog yes;

}

Test
Dig-t a na.xingxing.com @ 192.168.1.5
6 21:57:37 Nagios named [16147]: client 192.168.1.3 #33698: View Telecom: Query: na.xingxing.com in a + (192.168.1.5)
16 21:58:21 Nagios named [16147]: client 192.161.14.3 #47972: View Unicom: Query: na.xingxing.com in a + (192.161.14.5)
Vim/etc/named. conf

Logging {
Channel querylog {
File "/var/log/named/bind_query.log" versions 5 Size 10 m; // The format is file, the name is log. msgs, three versions are saved, and the size is 10 KB.
Severity dynamic; // Log Level
Print-time Yes; // print time
Print-category Yes; // print type
Print-severity yes; // print level
};
Channel my_syslog {
Syslog local0;
Severity Info;
};
CATEGORY queries {querylog;}; // query logs
CATEGORY xfer-out {my_file;}; // transfer out log dig-T axfs xingxing.com @ 192.168.1.1
CATEGORY update {my_syslog ;};
};

Queryperf: Stress Testing
Tar-zxvf bind-9.11.0.tgz
CD Binary-9.11.0/contrib
./Configure
Make
VI TEST
Ns.xingxing.com
Xingxing.com NS
Nagios.xingxing.com



Queryperf-d test-s 192.168.1.5

DNS query performance testing tool
Version: $ ID: queryperf. C, V 1.12 2007/09/05 07:36:04 Marka exp $

[Status] processing input data
[Status] sending queries (beginning with 192.168.1.5)
[Status] Testing complete

Statistics:

Parse input file: once
Ended due to: reaching end of File

Queries sent: 3 queries
Queries completed: 3 queries
Queries lost: 0 queries
Queries delayed (?) : 0 queries

Rtt max: 0.002752 Sec
RTT min: 0.002543 Sec
RTT average: 0.002648 Sec
Rtt std deviation: 0.000082 Sec
RTT out of range: 0 queries

Percentage completed: 100.00%
Percentage lost: 0.00%

Started at: Sun Oct 16 23:34:52 2016
Finished at: Sun Oct 16 23:34:52 2016
Ran for: 0.002870 seconds

Queries per second: 1045.296167 QPS


Install dnstop
Dnstop-4-Q-r eth0

DNS view and log Pressure Test

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.