Unnecessary DNS lookup errors in logs #24030
-
"On a K8s deployment, when pulsar client is used from a namespace different from pulsar broker/proxy namespace we see unnecessary errors in logs which is misleading. Pulsar client is appending all the DNS search domains causing connection errors. This happens even post a valid name is identified for connecting to server." When we upgraded the netty to 118 in pulsar 3.0.X we are seeing a different behavior. in older version it used to resolve to one dns name and fail or pass the connection . but with 118 its trying to resolve the next dns in some interval and printing the below warn messages : |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 14 replies
-
To locate the possible source of the error logs, it would be helpful to provide some examples. Appending a trailing dot to the FQDN is a standard way to prevent using configured search domains. This is a not-so-well-known detail of the original DNS RFC 1034 written in 1987. Absolute DNS names end with a dot, and relative names don't have a trailing dot. I haven't tested whether this solution works with the Pulsar client. For example, using If this doesn't work, please file an issue at https://github.com/apache/pulsar/issues. Excessive error logging could be a separate issue. |
Beta Was this translation helpful? Give feedback.
-
@sindhushreem25 You should use |
Beta Was this translation helpful? Give feedback.
@sindhushreem25 You should use
pulsar+ssl://pulsar-proxy.op.svc.cluster.local.:6651
as theserviceUrl
in your client to avoid this issue. That will prevent all unnecessary DNS lookups on the client side. I hope that helps.I haven't found any change on Netty side triggering this behavior. Using an absolute FQDN name will fix the issue. An absolute FQDN name is one that ends in the root domain, which is represented by the trailing dot. You can find more information about FQDN and the trailing dot here.