+40 745 232 788

Online Solutions Development Blog   |  

RSS

suPHP vs mod_php – pros and cons

posted by ,
Categories: PHP
Taggs ,

Somebody asked me in the past what are the differences between suPHP and mod_php and which one is the best so I will try to list the pros and cons between those two:

Performance related mod_php and by far the winner since it is about 30% faster than suPHP.

How do they work:

suPHP

  • – for each request the web server opens a new thread on behalf of that user

mod_php

  • – every request is processed on web server behalf

Pros:

suPHP

  • – the web server can be … threaded safe, and it is separated from php
  • – can be isolated based on user/environment

mod_php

  • – you can use php_value and other php settings right from .htaccess
  • – it is way faster than suPHP

Cons:

suPHP

  • – you can’t use php_value and other php settings from .htaccess
  • – slower
  • – higher response time
  • – higher CPU load

mod_php

  • – PHP safe mode it is not quite safe
  • – higher memory consumption than suPHP
  • – can’t be isolated based on user/environment

If you liked this post
you can buy me a beer

Add a Comment

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

Also, if you want to display source code you can enclose it between [html] and [/html], [js] and [/js], [php] and [/php] etc