mod_proxy_balancer question

Here's the problem, I want to start running more mongrels on a 2nd
server, but I want it so that any file uploads still go to the 1st
server.

Anyone know how I can do this?

Hi David,

Here's the problem, I want to start running more mongrels on a 2nd
server, but I want it so that any file uploads still go to the 1st
server.

You'll need some sort of Layer 7 rules engine to configure that, which
mod_proxy_balancer doesn't have. Alternatively you could look into using
some sort of shared storage such as NFS, Samba or GFS.

You can definitely change which mongrels you balance to based on the
url. I wouldn't be surprised if you could rewrite based on the content-
type header (and all file uploads will have the multipart etc content
type.

Fred

You can definitely change which mongrels you balance to based on the
url. I wouldn't be surprised if you could rewrite based on the content-
type header (and all file uploads will have the multipart etc content
type.

Fred

Yeah the URL would be enough, there's only one action that handles file
uploads. Can you give me any pointers on this, what would I need to
write in the conf file?

our vhost has got something like

RewriteRule ^/admin/.*$ balancer://admin_cluster%{REQUEST_URI}
[P,QSA,L]
RewriteRule ^/report/.*$ balancer://admin_cluster%{REQUEST_URI}
[P,QSA,L]

# All other URLs should be served by the texpert cluster
RewriteRule ^/.*$ balancer://main_cluster%{REQUEST_URI} [P,QSA,L]

urls starting with /admin and /report go the the admin_cluster, and
the others to the main_cluster.

Fred

our vhost has got something like

RewriteRule ^/admin/.*$ balancer://admin_cluster%{REQUEST_URI}
[P,QSA,L]
RewriteRule ^/report/.*$ balancer://admin_cluster%{REQUEST_URI}
[P,QSA,L]

# All other URLs should be served by the texpert cluster
RewriteRule ^/.*$ balancer://main_cluster%{REQUEST_URI} [P,QSA,L]

urls starting with /admin and /report go the the admin_cluster, and
the others to the main_cluster.

Fred

That looks perfect, I'll give it a go.

Thanks Fred!