Skip to content
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

ngx_http_upstream_jdomain_module: resolver failed, "xxxxx.web.com" (110: Operation timed out) #92

Closed
zhongcy opened this issue Feb 11, 2025 · 5 comments

Comments

@zhongcy
Copy link

zhongcy commented Feb 11, 2025

ERROR:

2025/02/11 17:33:42 [error] 205#0: ngx_http_upstream_jdomain_module: resolver failed, "xxxxx.web.com" (110: Operation timed out)
2025/02/11 17:33:42 [error] 207#0: unexpected DNS response for xxxxx.web.com
2025/02/11 17:33:43 [error] 207#0: unexpected DNS response for xxxxx.web.com
2025/02/11 17:33:44 [error] 207#0: unexpected DNS response for xxxxx.web.com

conf:
use default resolver_timeout :
`Default: | resolver_timeout 30s;

upstream xxx {jdomain xxxxx.web.com interval=60; keepalive 8;}

`

jdomain code :
logic is in :

/* Determine if there was an error and if so, should we mark the instance as down or not */

/* Determine if there was an error and if so, should we mark the instance as down or not */
	if (ctx->state || ctx->naddrs == 0) {
		instance->state.data.server->down =
		  exists_alt_server && (instance->conf.strict || ctx->state == NGX_RESOLVE_FORMERR || ctx->state == NGX_RESOLVE_NXDOMAIN);
		ngx_log_error((instance->state.data.server->down ? NGX_LOG_WARN : NGX_LOG_ERR),
		              ctx->resolver->log,
		              0,
		              "ngx_http_upstream_jdomain_module: resolver failed, \"%V\" (%i: %s)",
		              &ctx->name,
		              ctx->state,
		              ngx_resolver_strerror(ctx->state));
		if (!instance->state.data.server->down) {
			goto end;
		}
	}

why jdomain have this error?

@zhongcy
Copy link
Author

zhongcy commented Feb 11, 2025

https://github.com/nginx/nginx/blob/master/src/core/ngx_resolver.c

"unexpected DNS response for" error

@zhongcy
Copy link
Author

zhongcy commented Feb 11, 2025

@nicholaschiasson can you check it?

@nicholaschiasson
Copy link
Owner

Hi @zhongcy , can you provide a bit more well formatted details?

  • Can you show a more complete nginx config, not just the upstream block and resolver_timeout?
    • What are you using for resolver for example?
  • You have made sure your xxxxx.web.com resolves through the resolver you have configured on the host you're testing?
  • Are you able to run a debug build and provide log output? Even without a debug build, log output might still be helpful here.

Also note that some time in the coming year, I will be archiving this repo since the (better) feature is coming to nginx stable release. See #88

@zhongcy
Copy link
Author

zhongcy commented Feb 13, 2025

OK, thanks for share this infos,
I think about to use new nginx stable release later

@nicholaschiasson
Copy link
Owner

I will close this issue then. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants