Do a Google search for 'nginx Apache mod_wsgi proxy'. Various people have documented it.
On Dec 10, 3:55 am, Alex Fanjul <[email protected]> wrote: > Hi Graham, > I have configured an Apache+web2py corretcly in VPS hosting, but I'd > like to give a try to Nginx (I tried to set it up but without success), > could you give us an example configuration of Nginx+Apache+web2py? My > Apache conf (now) its the typical one with the DaemonProcess, > ProcessGroup and ScriptAlias... > > Thanks > Alex F > > El 09/11/2009 22:58, Graham Dumpleton escribi : > > > > > > > > > On Nov 10, 3:10 am, Thadeus Burgess<[email protected]> wrote: > > >> I use apache on virtualhost at slicehost running multiple web2py > >> virtualhosts. > > >> With one web2py instance, my server stands at around 90MB average for > >> memory, it *might* spike up to 115MB if I start some ram caching, however > >> my > >> reports have never reported anything higher. I am running apache with > >> mod_wsgi. Also I havn't seen anything faster :) I would say it's a toss up > >> between "Just Working" and "A couple more microseconds". > > > The important thing is to use daemon mode of mod_wsgi on memory > > constrained systems and not embedded mode. Although Apache is slower > > at serving static files than nginx or Cherokee, if configured > > correctly you wouldn't expect to see much difference for your actual > > web2py application requests. This is because the underlying web server > > isn't going to be the bottleneck. Instead the performance bottleneck > > is going to be your web2py code and the database access. > > > FWIW, a good middle ground is to use nginx as front end to Apache/ > > mod_wsgi (daemon mode). The nginx server will serve static files and > > proxy everything else to Apache. This gives benefit of fast static > > file serving from nginx and nginx will also isolate Apache from slow > > HTTP clients due to how nginx buffers request/responses. This means > > that Apache is only bothered for absolute minimum time required to > > handle request and thus can do more with less Apache processes/threads > > and thus less memory. > > > Graham > > >> On Mon, Nov 9, 2009 at 5:45 AM, David<[email protected]> wrote: > > >>> I recently setup a VPS host over at Santrex.net for testing web2py. > >>> It took me about two shifts to get Cherokee installed and running with > >>> Web2Py. What a pain. For those others that seemed to miss > >>> "libcherokee-mod-libssl" that was a painful lesson that could have > >>> been remarked elsewhere and saved a lot of time. > > >>> One of the things I noticed was that while working on the server that > >>> sometimes I could get the HTML source output starting with a "0" > >>> followed by the headers and then the page content. Ultimately this > >>> would cause an error and the page would fail to load. I noticed this > >>> happened about every 10th request or sooner depending on the speed at > >>> which I was moving through the site. > > >>> Fed up with this problem, I decided to install Apache server and > >>> configure a VirtualHost. This installation took about 20 minutes > >>> including apt-get, ssl gen, and virtualhost setup etc. It also works > >>> flawlessly even though it is a touch slower for what I am working on > >>> right now. > > >>> Do any other people here use Cherokee? Is it worth my time to chase > >>> down this page display problem? The only drawbacks for Apache with me > >>> are the default memory configuration issues (it's a pig out of the box > >>> on a vps and limited if your memory is limited) and that it happens to > >>> be the slowest, as far as I can see, based on performance reports. > >>> That being said it's still rock solid when it comes to working with > >>> Web2Py. > > > --~--~---------~--~----~------------~-------~--~----~ > > You received this message because you are subscribed to the Google Groups > > "web2py-users" group. > > To post to this group, send email to [email protected] > > To unsubscribe from this group, send email to > > [email protected] > > For more options, visit this group > > athttp://groups.google.com/group/web2py?hl=en > > -~----------~----~----~----~------~----~------~--~--- > > -- > Alejandro Fanjul Fdez. > [email protected] -- You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/web2py?hl=en.

