Lighttpd vs apache

vps

#1

Okay, so I Have a VPS on free trial at the moment, but I can’t really afford a ton of RAM, but I’ve definitely outgrown my shared plan, so I’m wondering about whether I should try lighttpd as an alternative.

I’ve used it before as a testing environment on my local machine, but I wouldn’t exactly say I’m used to it (I just use it to run a single PHP process for testing scripts), so I have a few questions:

[list][]How Smooth is the Transition? - I know some things may not work such as .htacess, but otherwise how smooth will the transition be for a website that mostly sees a lot of PHP traffic? I’ll likely make the change during my next scheduled downtime as I assume it requires a restart, but will the server just immediately pick up where apache left off and continue running my PHP site? Does it simply use the same PHP module?
[
]How Much RAM Does it Save? - Is it really worth switching to? Currently my site can have as many as 20 PHP processes running; I’m hoping to restrict that a little, but is it really the case that Lighttpd keeps PHP instances running at all times? Is it possible to reconfigure it’s behaviour for that?
[*]Can I still do .htacess style things? - Currently I have .htaccess setup to do a few simple things such as redirect requests (with query string) to /forum to go to /forums, to send root to index.html for CloudFlare support and so-on. What kind of rules can I still use via lighttpd itself (if any)? I can easily enough use PHP instead for some of them I think, but it’d be nice to avoid it.
[/list]


#2

If you’re using a lot of PHP you might want to take a peek at nginx + php-fpm too.