TechnitiumSoftware / DnsServer

Technitium DNS Server
https://technitium.com/dns/
GNU General Public License v3.0
3.86k stars 401 forks source link

Feature request: Additional logging options #734

Closed noseshimself closed 8 months ago

noseshimself commented 9 months ago

Right now there is the option to enable logs at all and to log all queries.

"Log all queries" is not logging all queries but only those the server is answering. This is demonstrably only a subset of all queries.

I would recommend to be able to only log events leading to errors (i. e. to be able to select zone updates, zone transfers (and other important subsets of DNS functions like the DNS-over-HTTP(S)) separately). For debugging purposes even tcpdump-like output of packets might be interesting.

An additional option I like in other programs is being able to define a (list of) CIDR addresses I'm interested in and getting maximum debugging output for every incoming or outgoing request of one of these addresses.

ShreyasZare commented 9 months ago

Thanks for the request.

"Log all queries" is not logging all queries but only those the server is answering. This is demonstrably only a subset of all queries.

All queries means the queries the server is answering. Which specific queries are you suggesting that are not logged?

I would recommend to be able to only log events leading to errors (i. e. to be able to select zone updates, zone transfers (and other important subsets of DNS functions like the DNS-over-HTTP(S)) separately).

Thanks for the suggestion. This can be added so that only critical errors get logged while the operational errors caused during name resolution are ignored to keep the log file size to minimum.

For debugging purposes even tcpdump-like output of packets might be interesting.

Writing pcap files is out of scope at the moment since there are too many core DNS features that are planned to be implemeted. I would recommend running tcpdump manually when debugging.

An additional option I like in other programs is being able to define a (list of) CIDR addresses I'm interested in and getting maximum debugging output for every incoming or outgoing request of one of these addresses.

This type of filtering option can be added to the Query Logs (sqlite) app. That will be much better to further search the requests in the UI.

ShreyasZare commented 8 months ago

Technitium DNS Server v11.5.2 is now available that adds option to ignore operational resolution errors. Do update and let me know your feedback.

noseshimself commented 8 months ago

For debugging purposes even tcpdump-like output of packets might be interesting.

Writing pcap files is out of scope at the moment since there are too many core DNS features that are planned to be implemented. I would recommend running tcpdump manually when debugging.

The problem was identifying packets coming in on the interface but never being seen by the server for some unknown reason. No filtering necessary, just a stream of whatever is coming in. The problem requiring this has been solved another way....