
2nd April 2009, 10:07
|
|
Moderator
|
|
Join Date: Dec 2005
Location: The Netherlands
Posts: 2,010
Thanks: 254
Thanked 134 Times in 120 Posts
|
|
What "PHP" option to use? Fast-CGI, CGI, Mod-PHP or SuPHP.
I'm just about ready to install WordPress on my ISPconfig 3 production server for a client, and now I need to know what PHP option is the best to use.
I've tested WordPress on a test server with Fast-CGI, and it looked like all was working fine.
As it's for a client (who has no clue on what he is doing), I was wondering if Fast-CGI is the best option to select?
I've got the following options: Fast-CGI, CGI, Mod-PHP or SuPHP
__________________
Never execute code written on a Friday or a Monday.
|

2nd April 2009, 10:42
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,883
Thanks: 691
Thanked 4,188 Times in 3,205 Posts
|
|
The php option depends on traffic that you expect for the site and if the site e.g. uploads or creates images or files on the server.
mod_php:
- fast
- runs not under admin user of the site
- well suited for low and high traffic sites, but not for cms systems like joomla.
suphp:
- not so fast
- script runs under web admin
- secure
- well suited for low traffic sites
fastcgi
- fast
- script runs under web admin
- secure
- well suited for high traffic sites
so basicalley the decision is, if a site is low traffic, use suphp. suphp spawns a new cgi process for every page request, but it does not use resources when no pages are requested. On the opposite fastcgi, the php processes are running permanently even if no page is requested, this is faster and fine for a high traffic site but for a small homepage with 100 pageviews per hour you would waste resources.
|
|
The Following 11 Users Say Thank You to till For This Useful Post:
|
007007 (12th July 2010),
BorderAmigos (12th July 2010),
bswinnerton (4th March 2010),
danielborene (16th June 2009),
edge (2nd April 2009),
lusso64 (6th May 2011),
mesut (15th July 2010),
NWO (30th September 2010),
planet_fox (2nd May 2009),
rukus77 (30th April 2009),
sirrus (12th May 2009)
|

2nd April 2009, 11:10
|
|
Moderator
|
|
Join Date: Dec 2005
Location: The Netherlands
Posts: 2,010
Thanks: 254
Thanked 134 Times in 120 Posts
|
|
Interesting information!
Thank you
__________________
Never execute code written on a Friday or a Monday.
|

2nd April 2009, 11:16
|
|
Moderator
|
|
Join Date: Dec 2005
Location: The Netherlands
Posts: 2,010
Thanks: 254
Thanked 134 Times in 120 Posts
|
|
Looks like WordPress does work fine with "mod_php", and as it's not running under admin I will stick with this sertting!
Once again thank you for the info.
__________________
Never execute code written on a Friday or a Monday.
|

30th April 2009, 11:07
|
|
Senior Member
|
|
Join Date: Sep 2005
Posts: 1,186
Thanks: 60
Thanked 13 Times in 11 Posts
|
|
ok, very good info so far, but i.e. wordpress, has a built in update module which means the user or the group that the web server runs as needs write access to vertain paths.
which one would I chose now? shall I chose a version where apache runs as the webadmin? I guess that is right? if it is a low traffic site, I shall chose suPhp but do I also have to check the box for suexec or isn't that needed?
|

30th April 2009, 14:39
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,883
Thanks: 691
Thanked 4,188 Times in 3,205 Posts
|
|
Quote:
|
ok, very good info so far, but i.e. wordpress, has a built in update module which means the user or the group that the web server runs as needs write access to vertain paths.
|
The wordpress update module can also connect to the site with ftp, so all of them will work.
But you should use either suphp or fastcgi with suexec.
|

30th April 2009, 16:21
|
|
Senior Member
|
|
Join Date: Sep 2005
Posts: 1,186
Thanks: 60
Thanked 13 Times in 11 Posts
|
|
well, if its a site for a client, its easier if he doesn't have to enter any ftp credentials, it jsut confuses people.
besides, if I edit a website, in the optiosn tab I see: Linux User web1
Linux Group client1 - so apache would run when using suPhp as web1 right? but what if the user uploads stuff with his ftp userlogin? which seems to differ from the linux user? I mean the files will be owned by the ftp user then :-(
|

3rd May 2009, 15:11
|
|
Senior Member
|
|
Join Date: Sep 2005
Posts: 1,186
Thanks: 60
Thanked 13 Times in 11 Posts
|
|
ok, now I was looking for a php accelerator and usually I use eaccelerator.
BUT I foudn this statement on their website:
Quote:
|
eAccelerator only works with mod_php or php in fastcgi mode. It can't be used in cgi or cli because eAccelerator needs to set up shared memory, and this can only be done when all php instances that need to access it are forks of the first process.
|
If I read that right, I can only use eaccelerator with mod_php and fastcgi with suexec but NOT with suPhp, right?
Is any of the other accelerators, i.e. x-cache able to work with all three?
|

3rd May 2009, 17:09
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,883
Thanks: 691
Thanked 4,188 Times in 3,205 Posts
|
|
Quote:
|
Is any of the other accelerators, i.e. x-cache able to work with all three?
|
No, there is no accelerator that works for cgi based setups like suphp.
|

3rd May 2009, 18:31
|
|
Senior Member
|
|
Join Date: Sep 2005
Posts: 1,186
Thanks: 60
Thanked 13 Times in 11 Posts
|
|
k, thx. found out x-cache in the lenny repository is actually up to date, so I installed that one, changed the config a bit and all seems good...
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT +2. The time now is 09:52.
|
Recent comments
7 hours 28 min ago
12 hours 26 min ago
13 hours 53 min ago
14 hours 46 min ago
16 hours 29 min ago
20 hours 52 min ago
21 hours 44 min ago
23 hours 58 min ago
1 day 13 hours ago
1 day 14 hours ago