| From | Sent On | Attachments |
|---|---|---|
| Rt Ibmer | Apr 28, 2008 8:44 am | |
| Cliff Wells | Apr 28, 2008 10:20 am | |
| mike | Apr 28, 2008 11:53 am | |
| Rt Ibmer | Apr 28, 2008 2:02 pm | |
| Cliff Wells | Apr 28, 2008 2:18 pm | |
| Manlio Perillo | Apr 28, 2008 2:37 pm | |
| Rt Ibmer | Apr 28, 2008 6:10 pm | |
| Rt Ibmer | Apr 28, 2008 6:19 pm | |
| Manlio Perillo | Apr 29, 2008 1:18 am | |
| Manlio Perillo | Apr 29, 2008 1:25 am | |
| Rt Ibmer | Apr 29, 2008 8:11 am | |
| François Battail | Apr 29, 2008 10:46 am | |
| Rt Ibmer | Apr 29, 2008 1:41 pm | |
| Manlio Perillo | Apr 29, 2008 1:57 pm | |
| François Battail | Apr 29, 2008 2:27 pm | |
| Aleksandar Lazic | Apr 29, 2008 2:36 pm | |
| François Battail | Apr 29, 2008 11:20 pm | |
| Mansoor Peerbhoy | Apr 30, 2008 1:46 am | |
| Manlio Perillo | Apr 30, 2008 2:36 am | |
| François Battail | Apr 30, 2008 3:54 am | |
| Mansoor Peerbhoy | Apr 30, 2008 5:03 am | |
| Grzegorz Nosek | Apr 30, 2008 5:18 am | |
| Cliff Wells | Apr 30, 2008 10:40 am | |
| Manlio Perillo | Apr 30, 2008 12:16 pm | |
| Manlio Perillo | May 1, 2008 2:42 am | |
| Grzegorz Nosek | May 1, 2008 11:28 am | |
| Manlio Perillo | May 1, 2008 12:02 pm |
| Subject: | Re: Feature request: Run a script when upstream detected down/up | |
|---|---|---|
| From: | François Battail (fb-f...@public.gmane.org) | |
| Date: | Apr 29, 2008 2:27:05 pm | |
| List: | ru.sysoev.nginx | |
Rt Ibmer <rtibmx@...> writes:
if (fork() == 0) execl("/bin/sh","/path/to/upstream_down.sh","ID of down upsteam goes here", NULL);
It's not as easy to do.
At a high level, what am I missing / oversimplifying?
The problem is not at high level but at low level: you cannot put code like this on a server, it's not a matter of writing two lines but to test potential errors, to have clean configuration parameters and to maintain the software...
Perhaps instead, a simpler and more efficient approach may be for me to write
to a log when nginx stops routing requests to an upstream box. I cannot use the events it logs current, because it doesn't differentiate between a failed attempt vs. enough failed attempts based on max_fails and fail_timeout.
Yes, it could be a solution but not good engineering: log is mostly for post-mortem investigations not for processing live events. It's dangerous to rely on string patterns.
Perfect! I just need the hook.
Some input from the list will be appreciated, I believe that such a module will add value to Nginx but some time is needed in order to fully evaluate the implications and the best implementation.
Thank you for your consideration and I hope these discussions help make in
incredible product even more robust.
;)





