Let me post you some relevant excerpts of my "nginx-php-fpm-php-apc-postgres"-tutorial, hopefully that will help you.
At first install the required packages:
apt-get install nginx php5-fpm php5-pgsql php5-gd php5-curl php-apc postgresql imagemagick
I assume that you have the relevant packages, such as php5-fpm, installed.
Now configure the "vhost":
vim /etc/nginx/sites-available/www.domain.tld
The following will show you my example configuration:
server {
listen 80;
server_name domain.tld www.domain.tld;
access_log /var/log/nginx/domain.access_log;
error_log /var/log/nginx/domain.error_log;
root /var/www/www.domain.tld;
index index.php index.htm index.html;
location ~ .php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /var/www/www.domain.tld$fastcgi_script_name;
include fastcgi_params;
try_files $uri =404;
}
}
Make sure that the right processes are running afterwards:
/etc/init.d/php5-fpm restart
/etc/init.d/nginx start
See the full tutorial here:
http://www.xenuser.org/2011/08/28/running-phpbb3-on-a-high-performance-monster-or-how-nginx-php-fpm-php-apc-postgres-will-serve-you-well/
I guess your configuration file for the vhost is missing some of the parts I posted above or php5-fpm is not running.