본문 바로가기

네임서버

DNS 성능 점검(queryperf)

반응형

DNS 성능 점검(queryperf)

  • sample 파일 만들기
find / -name gen-data-queryperf.py
$ find / -name gen-data-queryperf.py
/usr/local/src/bind-9.7.0-P2/contrib/queryperf/utils/gen-data-queryperf.py

 

$ ls -al gen-data-queryperf.py
-rw-rw-r-- 1 10132 wheel 3206 Jun 14  2008 gen-data-queryperf.py

 

chmod 755 gen-data-queryperf.py

 

$ ls -al gen-data-queryperf.py
-rwxr-xr-x 1 10132 wheel 3206 Jun 14  2008 gen-data-queryperf.py

 

python ./gen-data-queryperf.py -n 10 -p 100 -t com > domainquery.txt
  • -n 도메인
  • -p 100%
  • -t tld를 .com
$ cat domainquery.txt
www.82lfh-.com     A
www.ty0mt6.com     A
www.ih0.com     A
www.xvkmpvloa5.com     A
www.g5.com     A
www.fcpan13j.com     A
www.eahj.com     A
www.t2.com     A
www.pk.com     A
www.d10gl6p.com     A

 

  • 테스트 방법
queryperf –s 127.0.0.1 –d domainquery.txt –q 1400
  • -d 테스트 할 파일명
  • -s 네임서버
  • -q Queries per second
728x90

 

  • queryperf 사용법
queryperf -h
$ queryperf -h

DNS Query Performance Testing Tool
Version: $Id: queryperf.c,v 1.12 2007/09/05 07:36:04 marka Exp $

Usage: queryperf [-d datafile] [-s server_addr] [-p port] [-q num_queries]
                 [-b bufsize] [-t timeout] [-n] [-l limit] [-f family] [-1]
                 [-i interval] [-r arraysize] [-u unit] [-H histfile]
                 [-T qps] [-e] [-D] [-c] [-v] [-h]
  -d specifies the input data file (default: stdin)
  -s sets the server to query (default: 127.0.0.1)
  -p sets the port on which to query the server (default: 53)
  -q specifies the maximum number of queries outstanding (default: 20)
  -t specifies the timeout for query completion in seconds (default: 5)
  -n causes configuration changes to be ignored
  -l specifies how a limit for how long to run tests in seconds (no default)
  -1 run through input only once (default: multiple iff limit given)
  -b set input/output buffer size in kilobytes (default: 32 k)
  -i specifies interval of intermediate outputs in seconds (default: 0=none)
  -f specify address family of DNS transport, inet or inet6 (default: any)
  -r set RTT statistics array size (default: 50000)
  -u set RTT statistics time unit in usec (default: 100)
  -H specifies RTT histogram data file (default: none)
  -T specify the target qps (default: 0=unspecified)
  -e enable EDNS 0
  -D set the DNSSEC OK bit (implies EDNS)
  -c print the number of packets with each rcode
  -v verbose: report the RCODE of each response on stdout
  -h print this usage

 

queryperf -s 127.0.0.1 -d domainquery.txt -q 1400
$ queryperf -s 127.0.0.1 -d domainquery.txt -q 1400

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 127.0.0.1)
[Timeout] Query timed out: msg id 10
[Status] Testing complete

Statistics:

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

  Queries sent:         15 queries
  Queries completed:    14 queries
  Queries lost:         1 queries
  Queries delayed(?):   0 queries

  RTT max:              1.760744 sec
  RTT min:              0.962178 sec
  RTT average:          1.290466 sec
  RTT std deviation:    0.232029 sec
  RTT out of range:     0 queries

  Percentage completed:  93.33%
  Percentage lost:        6.67%

  Started at:           Thu Jul 15 15:52:54 2010
  Finished at:          Thu Jul 15 15:52:59 2010
  Ran for:              5.000967 seconds

  Queries per second:   2.799459 qps

 

728x90
반응형