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

Nginx fails abruptly #272

Open
dilshat opened this issue Feb 25, 2018 · 4 comments
Open

Nginx fails abruptly #272

dilshat opened this issue Feb 25, 2018 · 4 comments
Assignees
Milestone

Comments

@dilshat
Copy link
Member

dilshat commented Feb 25, 2018

Error log 2018/02/24 18:04:07 [emerg] 2044#2044: host not found in upstream "archive.ubuntu.com" in /snap/subutai-master/current/etc/nginx/nginx.conf:54

Mentioned config excerpt:

53 location /apt/main/dists {
54   proxy_pass              http://archive.ubuntu.com/ubuntu/dists/;
55   proxy_cache             DEBIDX;
56   proxy_cache_valid       5m;
57 }
@happyaron
Copy link
Contributor

This happens like a race condition: when nginx starts, it tries to validate the configuration, but at the same time network might be not ready on certain situations - which makes nginx dies thinking the configured upstream is wrong. We have several ways to make this work:

  1. start nginx after domain name can be resolved, e.g. we started dnsmasq successfully
  2. increase nginx's retries
  3. specify a special resolver to nginx, and let it resolve to something static if failed to get it in upstream

@dilshat
Copy link
Member Author

dilshat commented Mar 1, 2018

@happyaron we need to try to use newer version of nginx to allow the changes described above.
Please conduct tests with newer nginx version and snap,

@happyaron
Copy link
Contributor

Ack

@etursunbaev
Copy link
Contributor

Team Infra also think Nginx should be updated to latest version.

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

No branches or pull requests

3 participants