GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Description: The fair load balancer module for nginx
Homepage: http://nginx.localdomain.pl
Clone URL: git://github.com/gnosek/nginx-upstream-fair.git
gnosek (author)
Tue Jun 17 23:02:50 -0700 2008
commit  46667a1b273af41ed7d72d6bd3683834e4661e54
tree    caa8f860ff87d0524d55ddc672bb84730bb3bef8
parent  823ca755d3a0ffce28d45d73b9f433e69fec127e
100644 49 lines (32 sloc) 1.212 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
Nginx Upstream Fair Proxy Load Balancer
--
 
Description:
--
 
The Nginx fair proxy balancer enhances the standard round-robin load balancer provided
with Nginx so that it will track busy back end servers (e.g. Thin, Ebb, Mongrel)
and balance the load to non-busy server processes.
 
Ezra Zygmuntowicz has a good writeup of the fair proxy load balancer and how to use it here:
http://brainspl.at/articles/2007/11/09/a-fair-proxy-balancer-for-nginx-and-mongrel
 
 
Installation:
--
 
You'll need to re-compile Nginx from source to include this module.
Modify your compile of Nginx by adding the following directive
(modified to suit your path of course):
 
./configure --with-http_ssl_module --add-module=/absolute/path/to/nginx-upstream-fair
make
make install
 
 
Usage:
--
 
Change your Nginx config file's upstream block to include the 'fair' directive:
 
upstream mongrel {
    fair;
    server 127.0.0.1:5000;
    server 127.0.0.1:5001;
    server 127.0.0.1:5002;
  }
 
 
Contributing:
--
 
Git source repositories:
http://github.com/gnosek/nginx-upstream-fair/tree/master
http://git.localdomain.pl/?p=nginx-upstream-fair.git;a=summary
 
Please feel free to fork the project at GitHub and submit pull requests or patches.