Welcome, Guest
Please Login or Register.
Lost Password?
Virtualmin mod_fcgi documentation? (1 viewing)
Post Reply

TOPIC: Virtualmin mod_fcgi documentation?

#15824
larryish (User)
Posts: 14
graphgraph
Virtualmin mod_fcgi documentation? 2008/08/22 11:50  
Hi folks, newbie here.

Just purchased a 10 server license and I am trying to conf mod_fcgi.

Debian 4.0, Webmin and Virtualmin are all updated as of today.

php-cgi is installed, as is apache2-mod-fastcgi

Can someone please point me to any documentation concerning first-time configuration on mod_fcgi?

Thank you.
  The administrator has disabled public write access.
#15826
Joe (Admin)
Posts: 4117
graph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 13:17  
apache2-mod-fastcgi

Do not want! ;-)

mod_fastcgi is broken in several annoying ways under Apache 2. Even with patches found in the Debian build, it's a bit of a mess.

You want mod_fcgid. The two cannot coexist in the same Apache (though both can installed--you can't load them both into the same process).

The Virtualmin install script should have handled everything for you...though it only sets up for PHP apps, by default.

You can double check to be sure your box is setup to use FastCGI in the Server Templates under the Apache Website section. The option is labeled "Default PHP execution mode". For existing virtual servers, you'll need to look in "Server Configuration:Website Options" for the specific server.

What, specifically, are you wanting to run with FastCGI? And what trouble are you running into?
  The administrator has disabled public write access.
#15830
larryish (User)
Posts: 14
graphgraph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 13:44  
I'm not particularly interested in fastcgi, was under the impression that it was the same as fcgid, which is what I am after.

The reason I went ahead and upgraded to VM pro 10 is to be able to run Apache2 as the UNIX user instead of www-data.

Upgraded via the Virtualmin dialog, everything went smoothly, but when I set my test domain to use mod_fcgid it stopped loading at all.

Apparently it is because mod-fcgid was not installed. Hehhehhe I'm dumb.

Removed the package apache2-mod-fastcgi, installing apache2-mod-fcgid now.

Thanks for the tip.
  The administrator has disabled public write access.
#15831
larryish (User)
Posts: 14
graphgraph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 13:53  
O.k., I did not have it set to fcgid, I was trying to set the CGI wrapper option.

Now that apache2-mod-fcgid is installed, in the Website and PHP Options dialog the option "FCGId (run as virtual server owner)" is presented.

So I set it for the domain in question, saved the settings, reloaded apache2, and now it gives the following error:

Code:

Service Temporarily Unavailable The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later. Apache/2.2.3 (Debian) mod_python/3.2.10 Python/2.4.4 PHP/5.2.0-8+etch11 mod_ssl/2.2.3 OpenSSL/0.9.8c mod_perl/2.0.2 Perl/v5.8.8 Server at www.mydomain.com Port 80



Other domains on the same server that run as www-data still function normally.

Any suggestions? I have looked for documentation but have not found any so far.
  The administrator has disabled public write access.
#15832
Joe (Admin)
Posts: 4117
graph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 14:13  
Two things to check:

/usr/libexec/apache2/suexec -V

Is DOCROOT set to /home? If not, you need to install our Apache package (this should also have been done by the install script, but I've been getting the feeling that lately that isn't working for some reason). Try upgrading your system with apt-get, or just:

apt-get install apache2

And see if it'll get our version.

The other possibility is permissions. Folks often get a little silly when presented with a "it won't run" situation, and they'll set permissions to 777 or similar. When using suexec, this just guarantees that it won't run. Files to be run under suexec must meet the following conditions:

Owned by the user that owns the virtual server

Not group or world writable (thus, definitely not 777)

Within the DOCROOT discussed above

If any of those aren't true, then things won't work.
  The administrator has disabled public write access.
#15833
larryish (User)
Posts: 14
graphgraph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 14:41  
O.k., getting warmer... :)

Code:

sv01:/home/nukesylo13/public_html# a2enmod suexec This module is already enabled! sv01:/home/nukesylo13/public_html# /usr/lib/apache2/suexec -V -D AP_DOC_ROOT="/var/www" -D AP_GID_MIN=100 -D AP_HTTPD_USER="www-data" -D AP_LOG_EXEC="/var/log/apache2/suexec.log" -D AP_SAFE_PATH="/usr/local/bin:/usr/bin:/bin" -D AP_UID_MIN=100 -D AP_USERDIR_SUFFIX="public_html" sv01:/home/nukesylo13/public_html# apt-get install apache2 Reading package lists... Done Building dependency tree... Done apache2 is already the newest version.



DOC_ROOT is set to /var/www

Going to cast around now for a Virtualmin apache2 package, I think that is what you were hinting at above.
  The administrator has disabled public write access.
#15834
larryish (User)
Posts: 14
graphgraph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 14:56  
Where are the Virtualmin Repos?

The docs on virtualmin.com mention the installer updating the repos but I don't see it.

Code:

sv01:/etc/apache2# cat /etc/apt/sources.list # # deb cdrom:[Debian GNU/Linux 4.0 r0 _Etch_ - Official i386 CD Binary-1 20070407-11:55]/ etch contrib main deb http://ftp.debian.org/debian/ etch main contrib non-free deb-src http://ftp.debian.org/debian/ etch main contrib non-free deb http://security.debian.org/ etch/updates main contrib non-free deb-src http:



Sorry for bugging you to death about this. Not used to not knowing, been running Debian since hamm and this Virtualmin upgrade is being a pain.
  The administrator has disabled public write access.
#15835
Joe (Admin)
Posts: 4117
graph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 14:59  
Egads...This is all wrong. ("Gromit! These are the wrong trousers, Gromit...and they're all wrong!")

Obviously our upgrade from GPL to Professional process has been drinking the Fail-Aid.

I'm guessing that you installed initially using the wbm modules, rather than using the install script for Virtualmin GPL? I think that's the way to end up with the upgrade not enabling the Virtualmin Professional apt repository and such.

So, you probably want to get the apt repo setup. The virtualmin repo line looks like:

deb http://SERIAL:KEY@software.virtualmin.com/debian/ virtualmin-etch main

Where SERIAL and KEY must be replaced with your serial number and license key (found on http://www.virtualmin.com/serial/ )

Then you can try upgrading Apache again. (You may also want to move your install over to a deb-based one, and use the Virtualmin Package updates module to help you stay on top of updates. Once apt is configured, you can get it via "apt-get install webmin-security-updates".)
  The administrator has disabled public write access.
#15836
larryish (User)
Posts: 14
graphgraph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 15:08  
Awesome, that sounds like the ticket.

Installed Virtualmin via wbm and then upgraded from GPL to Pro from within Virtualmin.

Going to add the repo now.

Sorry to hear about your trousers. :D
  The administrator has disabled public write access.
#15837
larryish (User)
Posts: 14
graphgraph
Re:Virtualmin mod_fcgi documentation? 2008/08/22 15:22  
Got the repo added, apache2-and-friends install went well, already had the webmin security 3.1 update.

Still no go, the site hangs and then times out with the error message from an earlier post.

Here is a tail of the apache2 error log:

Code:

sv01:/var/log/apache2# tail error.log [Fri Aug 22 20:17:04 2008] [notice] mod_fcgid: call /home/myusername/public_html/index.php with wrapper /home/myusername/fcgi-bin/php5.fcgi [Fri Aug 22 20:17:04 2008] [notice] mod_fcgid: server /home/myusername/public_html/index.php(11981) started [Fri Aug 22 20:17:04 2008] [notice] mod_fcgid: process /home/myusername/public_html/index.php(11979) exit(server exited), terminated by calling exit(), return code: 0 [Fri Aug 22 20:17:04 2008] [notice] mod_fcgid: process /home/myusername/public_html/index.php(11975) exit(communication error), terminated by calling exit(), return code: 0



Time for vodka. :)
  The administrator has disabled public write access.
Post Reply
get the latest posts directly to your desktop

Talk and Get Help

Support
Forums
Bugs and Issues

Get Virtualmin

OS Support
Buy Online
Download
Copyright 2005-2007 Virtualmin, Inc. All rights reserved.