Nginx isn't as fast as i expect

Brice Figureau brice+nginx at daysofwonder.com
Thu Aug 16 15:20:39 MSD 2007


On Thu, 2007-08-16 at 12:16 +0200, somebody nobody wrote:
> user  nobody nogroup;
> worker_processes  10;

uh 10 ?
That sounds like a lot to me.
I think you should not use more than 1 worker_process per processor or
core.

>     sendfile        off;

I don't know if solaris has sendfile but usually sendfile is faster (or
more resource friendly) than using read/write combinations.

>         location ~ \.php$ { 
>             include /nginx/conf/fcgi.conf;      
>             fastcgi_pass unix:/tmp/fastcgi.socket;
>             fastcgi_index index.php;
>         }    

Are you sure Apache is using the same FastCGI settings as nginx ones?
How are you spawning your fastcgi process?
If you are using lighttpd's spawn-cgi make sure you have the same number
of PHP processes as what you are using with Apache.
Did you try a tcp socket instead of a unix one ?

Can you give us the ab parameters you used, especially the concurrency ?
-- 
Brice Figureau <brice+nginx at daysofwonder.com>






More information about the nginx mailing list