Hosting is cheaper than virtual server or dedicated machine on a network. This fact is true because resources are shared between many customers and one can place hundreds of accounts on one physical server. Adding too much accounts leads to slowing server responses and to instability in general. It’s called overselling. Do you know how to check if your hosting account is overselled?
The Fighters
I’m comparing three hosting providers here:
- DreamHost.com – popular host provider from USA
- Kei.pl – good hosting, 24/7 administration from Poland
- Linuxpl.com – Polish company, servers in Germany, cheap hosting with SSH option
I’m using separate Linux box located in Poland to reach analysed servers with few tools (awk, cron, bash).
(more…)
CGI is a standard protocol to run dynamic web-apps using HTTP protocol. It’s advantage: standard, available everywhere, disadvantages: it’s slow (a process is created for every HTTP request). To overcome this limitations FastCGI has been created (one process serves many HTTP requests). But not everywhere FastCGI is supported. I’ll show how to use special bridge to use FastCGI on CGI-only environment.
First, we have to download current FastCGI development kit then compile cgi-fcgi binary usging the same architecture as our hosting provider uses. Then copy compiled binary to server and create small script to run our bridge, lets name it app.bridge:
#! ./cgi-fcgi -f
-connect app.sock app.fcgi 1
Here “1″ means: create one process, multiple requests will be handled by internal thread manager in application. If your application is not multi threaded you can pass higher number here.
The bridge file must have correct permissions and the following fragment must be added to .htaccess to allow to call this bridge script:
Options +ExecCGI
AddHandler cgi-script .bridge
That’s all, folks!