First step is to install Lighttpd server. Install it using following command:
$ apt-get install lighttpd
This should install lighttpd on your system. All the lighttpd related configurations can be found at /etc/lighttpd/
Next step is to start Lighttpd server:
$ /etc/init.d/lighttpd start
As per default configuration ( at /etc/lighttpd/lighttpd.conf ), lighttpd will be started at port 80. Point the server to:
This should display Lighttpd Welcome Page.
To make PHP work with Lighttpd we have to install PHP with CGI. To install it:
$ apt-get install php5-cgi
This will install PHP with CGI.
Now goto /etc/lighttpd/conf-available directory. Here you will get a file called 10-fastcgi.conf. This is the configuration file for setting up PHP to work with Lighttpd. You can change the configuration as per your requirements.
You can either copy this file to /etc/lighttpd/conf-enabled/ or create a symbolic link to it:
ln -s /etc/lighttpd/conf-available/10-fastcgi.conf /etc/lighttpd/conf-enabled/10-fastcgi.conf