Turn on or enable BIND DNS server logging to see all queries or for troubleshooting problem
Q. How do I turn on DNS server logging so that I can see all the queries on my CentOS 4.0 server?
A. You can use rndc command which controls the operation of a name server. It supersedes the ndc utility that was provided in old BIND releases. If rndc is invoked with no command line options or arguments, it prints a short summary of the supported commands and the available options and their arguments.
rndc communicates with the name server over a TCP connection, sending commands authenticated with digital signatures. In the current versions of rndc and named named the only supported authentication algorithm is HMAC-MD5, which uses a shared secret on each end of the connection. This provides TSIG-style authentication for the command request and the name server\u2019s response. All commands sent over the channel must be signed by a key_id known to the server.
Task: Turn on logging
Type the following command as root to toggle query logging:
# rndc querylog
Task: View bind sever query log
Once this is done, you can view all logged queries usimg /var/log/messages file. To view those queries, type:
# tail -f /var/log/messages
Task: Turn off logging
Type the following command as root to toggle query logging:
# rndc querylog
Subscribe to our free e-mail newsletter or RSS feed to get all updates.
You can Email this page to a friend.
Related Other Helpful FAQs:
- -bash: enable: PrinterName: not a shell builtin Error and Solution
- Apache Log POST Data To A Log File
- Howto: Linux set up the X Window System to allow remote X sessions via the XDMCP
- How do I Logging in remotely from my Desktop into Linux server?
- Where is my Linux GNU C or gcc compiler installed?
Leave a Reply
We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!
Tags: bind, dns_server, fedora, Linux, server_logging, Troubleshooting, UNIX



Recent Comments
Today ~ 32 Comments
Yesterday ~ 1 Comment
Yesterday ~ 3 Comments
Yesterday ~ 2 Comments
Yesterday ~ 3 Comments