Nginx's upstream failed, how to recover

Ryan asked:

From the doc: http://wiki.nginx.org/HttpUpstreamModule#server

It said when the upstream reached max_fails within fail_timeout and it will become dead. What if my server is up sometimes after?

In general,

  1. If a upstream server failed, will nginx retry with another server in the pool?

  2. Any variable I can configure so that they will join the pool automatically when they are up?

Thanks.

My answer:


The documentation you linked to states that nginx will try the upstream again after fail_timeout seconds, to see if it has come back up.


View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.