-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a --verbose or --debug flag to resolvectl #17330
Comments
|
|
|
That is indeed a way to do it, as a workaround. It involves changing a config file, restarting a service, isolating the query in the log, then reverting the changes to the system. |
|
for example, it would be nice if Similarish to how systemct status prints logs for the unit from journal too. |
Log level can already be dynamically tweaked with the LogControl1 API. Dunno, maybe resolved could add a journal metadata field that would tag the queries it performs with some "source" identifier, similarly to how postfix or exim4 tag all messages related to a specific message using the identifier of that message. So resolvectl could specify a UUID when performing the query, and then resolved would include REQUESTED_BY=uuid in messages, and the logs could be queried with this metadata. This could be useful, but it not a trivial project.
Well, it's one thing to support that for a tool that does stuff locally, and completely another thing to make that work in something that tells a server to do stuff. |
|
Every DNS query has 16-bit id (id: in dig ->>HEADER<<-). It is not proved to be unique, but should be sufficient to pair each request to its reply. Should work to pair with dependent queries, like DNSKEY or DS records. |
|
I think resolvectl could just allow increasing and decreasing verbosity level without sending d-bus messages. |
This would be so nice! |
|
So how can we currently debug DNS issues? Completely useless In I want to find out at which level/where it failed. |
|
Why do you think it failed? It may be just vague terminology. But I assume this message is result of status: NXDOMAIN dns query, which just means that name does not exist. It is not error, it is just negative response. There is relatively new extension EDE, which can provide reasons for SERVFAIL status in response. Which would be good to be provided by UI if specified. But in this case just error message should be corrected. It is not error or failure. It just tells you 'some.domain' name does not exist. It should be presented as such, not as a failure. |
|
I think not found is just wrong. It may make difference between name does not exist (NXDOMAIN status) and record type does not exist (NOERROR status but no answer). But it should not say not found, at least not for DNS. Because it was found no such name exist and that is definitive answer. It may be different on multicast protocols, where it does mean nobody answered for such name. But unicast DNS makes clear difference between failure (SERVFAIL, REFUSED or just timeout) and negative answer. |
|
I think this is going off topic / should be discussed in it's own issue. Edit: I see you just created a new issue for this sub-problem, thanks! 👍 I'd like to second the need for a --verbose / --debug flag, that's why I upvoted and subscribed here some time ago. In my case there are spurious resolve issues every few weeks which are gone after a reload, i.e. restarting resolved in debug mode doesn't help as the issue is not reproducible any more. Getting some more information through resolvectl would certainly help in these cases. |
|
I admit it would be great if It may increase log level or verbosity level and return it back when the command is finished. Somehow more difficult would be to include messages done by systemd-resolved daemon in the command output. But maybe that part is not so important. |
Because issue is with something related with Didn't realize there's |
|
+1. Just being able to see what server the query went to and the response from that server with a --verbose flag would be useful. |
|
+1 |
Resolvectl is a very useful tool for testing the dns resolution of systemd-resolved.
When investigating name resolution issues (if it resolves fine with
dig @server domain.to.testbut not with systemd-resolved), you can useresolvectl statusto view the active configuration with the link related parameters, OR useresolvectl query domain.to.testto test the resolution (but you have no details, just either a result, or a simple "not found" message).It would really help a lot to have either a --verbose or a --debug flag, to see which server is queried, why, which domains are actually sent in the query (based on the search domains), was the cache used,...
Thanks!
The text was updated successfully, but these errors were encountered: