Best web server when resources are not limited?

vpsnewb

New Member
Let's say you're not limited by resources and you purely want the best performance and security from your web server. On a small VPS you may be restricted to utilizing Nginx, for example, as it's more lightweight than Apache out of the box. But, can Apache perform just as well when given proper time and resources? What about lighttpd and litespeed? Hell, does anyone use Cherokee anymore? (It's actually kind of neat)

So, imagine you aren't constrained on resources and you're setting up a server to host a busy site. Which web server do you choose, and why?
 

Mun

Never Forget
Depends on your application and what you are doing.

Youtubes front end is lighttpd, and its backend for PHP is apache. In many cases still today apache can handle php faster and quicker then any other application as it is built into the process.

I for one couldn't beat my friends load times on his apache setup even though I had a heavily tuned php-fpm/nginx and he had apache. (We were doing php files)
 

TruvisT

Server Management Specialist
Verified Provider
Depends on your application and what you are doing.

Youtubes front end is lighttpd, and its backend for PHP is apache. In many cases still today apache can handle php faster and quicker then any other application as it is built into the process.

I for one couldn't beat my friends load times on his apache setup even though I had a heavily tuned php-fpm/nginx and he had apache. (We were doing php files)
Was the hardware specs the same?
 

drmike

100% Tier-1 Gogent
Cherokee is awesome, but the head developer went to work for a big corporation and the project has idled. Unsure if I'd deploy it heavily at this point.

Nginx is the defacto standard at this point for more 'knowledgeable' folks.  Really solid piece of software with tons of features.  

Would be great to Cherokee-like admin for Nginx.  That would be purrrrfect.
 

SeriesN

New Member
Verified Provider
But why not apache? Given the condition above, Apache can beat anything. I am loving me some apache 2.4 right now.
 

NodeBytes

Dedi Addict
I'm using apache. It's super quick! My personal site www.brendancarlson.me is hosted on a dedicated server with apache and it loads really fast.
 

MannDude

Just a dude
vpsBoard Founder
Moderator
Cherokee is awesome, but the head developer went to work for a big corporation and the project has idled. Unsure if I'd deploy it heavily at this point.

Nginx is the defacto standard at this point for more 'knowledgeable' folks.  Really solid piece of software with tons of features.  

Would be great to Cherokee-like admin for Nginx.  That would be purrrrfect.
Cherokee was pretty slick when I decided to give it a go. Didn't use it for anything production, just wanted to use it. If Nginx has a similar admin/backend/GUI like Cherokee did, my god. That'd be awesome.

I like Apache because of how well documented it is. Still the most used webserver, but I do prefer Nginx over it as I've made myself more familiar with it over the past year or so. My experience with lighttpd isn't that great, although lighttpd is powering vpsBoard at this current time. I did use Litespeed in the past, but I found Apache + Varnish Cache out performed Litespeed, so I can rule out Litespeed.

TL;DR: I don't know.
 
Last edited by a moderator:

drmike

100% Tier-1 Gogent
I missed the last line, about large RAM and what would you use...

Nginx is what I use.  Still use other servers though behind Nginx :)  Lots of Apache stuff that just works and porting it to Nginx isn't quick and easy to translate, rules, etc.

Larger sites I'd do:  Varnish ---> Nginx ---> whatever server.  But this is where good amount of static or media content.

Apache is always capable and perhaps competitive with tweaking, but I've always hated the config style of Apache.
 

drmike

100% Tier-1 Gogent
If you have a fairly large amount of money, my understanding is that LiteSpeed and its caching product (when properly tweaked) can run circles around nginx or Apache.

http://vbtechsupport.com/litespeed/benchmarks/vbjan26/vbindex_ls_ngx_apachevarnish_jan28updated.png
Problem is those numbers are old --- 2011 :)

The top speed is Lite + Xcache --- assuming they are serving the same document every time.  So entirely out of the cache/RAM on every request after the first.

They test Apache fronted by Varnish and it didn't lag Lite + Xcache a whole heck of a lot considering.

Oddly they didn't test Nginx fronted by Varnish.

Whole bunch of data missing from the tests too.

When you have the luxury of serving the same document a gazillion times from cache, it is hard to beat plain old Varnish.
 

wlanboy

Content Contributer
My preference is lighttpd. I use it for small php sites and as a front end proxy for my thin/rails apps.

Proxy setup is quite easy:

Code:
$HTTP["host"]=~ "domain.com|domain2.com"  {
        proxy.balance = "fair"
        proxy.server =  ("" =>
                        (( "host" => "127.0.0.1", "port" => 4001 ))
                        )
}
 

drmike

100% Tier-1 Gogent
My preference is lighttpd. I use it for small php sites and as a front end proxy for my thin/rails apps.

Proxy setup is quite easy:


$HTTP["host"]=~ "domain.com|domain2.com" {
proxy.balance = "fair"
proxy.server = ("" =>
(( "host" => "127.0.0.1", "port" => 4001 ))
)
}
That's simple as it possibly can get....  Bunch of other crud for the config file though?  Or will lighthttpd run with literally just that?

Have to love front end proxy feature.  It is what I use most --- with Nginx.
 

wlanboy

Content Contributer
The configuration of lighttpd is quite simple. You have one lighttpd.conf in /etc/lighttpd

and some additional module config files:


/etc/lighttpd/conf-enabled$ ls -al
total 8
drwxr-xr-x 2 root root 4096 Apr 19 09:15 .
drwxr-xr-x 4 root root 4096 Apr 10 12:23 ..
lrwxrwxrwx 1 root root 30 Apr 10 12:12 05-auth.conf -> ../conf-available/05-auth.conf
lrwxrwxrwx 1 root root 35 Apr 10 12:12 10-accesslog.conf -> ../conf-available/10-accesslog.conf
lrwxrwxrwx 1 root root 29 Apr 10 12:12 10-cgi.conf -> ../conf-available/10-cgi.conf
lrwxrwxrwx 1 root root 33 Apr 10 12:12 10-fastcgi.conf -> ../conf-available/10-fastcgi.conf
lrwxrwxrwx 1 root root 31 Apr 10 12:12 10-proxy.conf -> ../conf-available/10-proxy.conf
lrwxrwxrwx 1 root root 29 Apr 10 12:12 10-ssl.conf -> ../conf-available/10-ssl.conf
lrwxrwxrwx 1 root root 32 Apr 19 09:15 10-status.conf -> ../conf-available/10-status.conf
lrwxrwxrwx 1 root root 37 Apr 10 12:25 15-fastcgi-php.conf -> ../conf-available/15-fastcgi-php.conf

B.t.w. I do like the linking to /conf-enabled and /conf-disabled.

That is my whole lighttpd.conf: (so leaving https, auth and php config to the files in /conf-enabled)


server.modules = (
"mod_access",
"mod_alias",
"mod_compress",
"mod_redirect",
"mod_rewrite"
)

server.document-root = "/var/www"
server.upload-dirs = ( "/var/cache/lighttpd/uploads" )
server.errorlog = "/var/log/lighttpd/error.log"
server.pid-file = "/var/run/lighttpd.pid"
server.username = "www-data"
server.groupname = "www-data"
index-file.names = ( "index.php", "index.html" )
url.access-deny = ( "~", ".inc" )
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )

dir-listing.encoding = "utf-8"
server.dir-listing = "disable"

compress.cache-dir = "/var/cache/lighttpd/compress/"
compress.filetype = ( "application/x-javascript", "text/css", "text/html", "text/plain" )

include_shell "/usr/share/lighttpd/create-mime.assign.pl"
include_shell "/usr/share/lighttpd/include-conf-enabled.pl"

$HTTP["host"] =~ "^domain\.net$" {
url.redirect = ( "^/(.*)" => "http://www.domain.net/$1" )
}

$HTTP["host"]=~ "domain1|domain2" {
proxy.balance = "fair"
proxy.server = ("" =>
(
( "host" => "127.0.0.1", "port" => 4001 )
))
}

$HTTP["remoteip"] =~ "127.0.0.1" {
alias.url += ("/munin/" => "/var/cache/munin/www/")
}

$HTTP["host"]=~ "domain.org" {
server.document-root = "/var/www-org"
}

So what I really like about lighttpd is the fact that based on some rules you can override quite every single server parameter.

Alias, rewrites, Proxy, document-root, just everthing can be configured based on hosts, ips, etc.
 
Last edited by a moderator:
Top