These forums are locked and archived, but all topics have been migrated to the new forum. You can search for this topic on the new forum: Search for Apache modes on the new forum.
This website is deprecated, and remains online only for historic access to old issues and docs for historic versions of Virtualmin. It has been unmaintained for several years, and should not be relied on for up-to-date information. Please visit www.virtualmin.com instead.
FCGID and CGI each come with the security advantage of running all scripts as the domain owner's userid, rather than that of the Apache user. That's a big security win.
FCGID also happens to have the benefit of caching scripts in memory, offering performance similar to mod_php.
FCGID is used as the default because it offers a blend of both improved security and good speed.
Yes but it's effectiveness is questionable. In benchmarking it showed a marked improvement (66% drop with APC) but I don't know how it would perform in real world conditions. I personally had installed eAccelerator since it can also do a proper file cache.
I have installed eaccelerator and xcache on my migrated server but neither appear to work. I am using the "CGI wrapper" php execution mode on my server because for some reason FCGId does not work(my sites were originally created using Virtualmin GPL in 2007 and migration to the new version didn't work 100%).
Should caching apps like eaccelerator and xcache with with CGI-wrapper?
If not, is FCGId the preferred execution mode? If so, what do I need to do to make my sites work in FCGId ?
I have a problem with this feature. I just installed new version of virtualmin GPL on a new machine, and tried to restore previously backed up virtual server from previous machine. Earlier I had fcgid configured manually as posted on forums and it worked. But as now it can be easily set in Virtualmin, I wanted to use this feature. Unfortunately apache runs as www-data and not as domain owner, despite the fact that FCGID is chosen. What should I check?
I can only find the "Automatically add appropriate SuExec directive" option and it is set to Yes. Also the command didn't help.
I also created new virtual server (not restored) and put simple PHP file, and unfortunately there was no process spawned under proper owner (only www-data). So this is not related to my old backups probably. What can I do / check more?
[EDIT] Finally found out what's wrong - I had php5 module active in apache, so disabling it (a2dismod php5) helped. Same problem as here: http://www.virtualmin.com/node/15168
FCGID and CGI each come with the security advantage of running all scripts as the domain owner's userid, rather than that of the Apache user. That's a big security win.
FCGID also happens to have the benefit of caching scripts in memory, offering performance similar to mod_php.
FCGID is used as the default because it offers a blend of both improved security and good speed.
-Eric
Ok, thanks. I have to try it :) Do i need to do anything else than change that setting from "Website Options"?
nothing more would be required
Is it safe to use APC accelator with FCGID?
Yes but it's effectiveness is questionable. In benchmarking it showed a marked improvement (66% drop with APC) but I don't know how it would perform in real world conditions. I personally had installed eAccelerator since it can also do a proper file cache.
I have installed eaccelerator and xcache on my migrated server but neither appear to work. I am using the "CGI wrapper" php execution mode on my server because for some reason FCGId does not work(my sites were originally created using Virtualmin GPL in 2007 and migration to the new version didn't work 100%).
Should caching apps like eaccelerator and xcache with with CGI-wrapper?
If not, is FCGId the preferred execution mode? If so, what do I need to do to make my sites work in FCGId ?
Thanks
Yeah, I suspect those caching apps should work just fine using the CGI wrapper.
-Eric
Nope only in mod_php, or at least not in PHP-CGI or FCGId since the latter two run php scripts in their own process separately...something like that.
I managed to manually edit httpd.conf to get my sites to run under mod_php and now eAccelerator runs properly.
I have a problem with this feature. I just installed new version of virtualmin GPL on a new machine, and tried to restore previously backed up virtual server from previous machine. Earlier I had fcgid configured manually as posted on forums and it worked. But as now it can be easily set in Virtualmin, I wanted to use this feature. Unfortunately apache runs as www-data and not as domain owner, despite the fact that FCGID is chosen. What should I check?
You can enable whether suexec is used for new Virtual Servers in System Settings -> Server Templates -> Default -> Apache Website.
For existing sites, I'm not aware of a way to do that in the Virtualmin GUI, but it can be done from the command line using:
virtualmin modify-web --domain DOMAIN --suexec
I can only find the "Automatically add appropriate SuExec directive" option and it is set to Yes. Also the command didn't help.
I also created new virtual server (not restored) and put simple PHP file, and unfortunately there was no process spawned under proper owner (only www-data). So this is not related to my old backups probably. What can I do / check more?
[EDIT] Finally found out what's wrong - I had php5 module active in apache, so disabling it (a2dismod php5) helped. Same problem as here: http://www.virtualmin.com/node/15168