Tag Info

Hot answers tagged

6

PHP-FPM is a patch for PHP to provide some advanced process management features which are useful when used in its FastCGI variant. On a side note, PHP 5.4 will probably include PHP-FPM out of the box (according to Antony Dovgal). Since mod_fcgid doesn't support externally spawned FastCGI servers, you need to use mod_fastcgi or mod_proxy_fcgi. Google found ...


4

Solution: FcgidMaxRequestLen -->This is causing the problem. Before updating to the newest version, it was default set to 1gb. Now it is 128kb. Add the following to the file /etc/apache2/conf.d/fcgid.conf : FcgidMaxRequestLen 1073741824 This wil give you a limit of 1gb. Next, restart your apache.


4

You're using ubuntu. Therefore recompile is pretty simple. Add source repository to your /etc/apt/sources.list . For 12.04 run echo "deb-src http://de.archive.ubuntu.com/ubuntu/ precise main"|sudo tee -a /etc/apt/sources.list change de.archive.ubuntu.com to whatever country you're in. After that update your repository. apt-get update Change dir and ...


3

These are comparing apples and oranges and bananas. First, FastCGI is a protocol for communicating between a persistent application (or application server) and a webserver. A FastCGI-capable application runs on its own and receives requests from the webserver, then returns the responses to the webserver to give to the client. FastCGI was invented because ...


3

<Directory /srv/www/hostname/public> Order allow,deny Allow from all </Directory> That doesn't include /srv/www/hostname/fcgid-bin/; assuming there's no Allow applying to it elsewhere in your config, this is the problem. You'll need to Allow access to this location.


3

Is this common behaviour? It's your specific settings. Solution: Options -MultiViews Apache Manual says (you will have to scroll down a bit): The effect of MultiViews is as follows: if the server receives a request for /some/dir/foo, if /some/dir has MultiViews enabled, and /some/dir/foo does not exist, then the server reads the directory ...


2

'IPCCommTimeout' may be too large. Set the normal limit(60-180) 'IdleTimeout' set to 3600 or higher 'DefaultMaxClassProcessCount' set to (number or CPU core) 'ProcessLifeTime' set to 7200 'MaxProcessCount' set large 'DefaultMaxClassProcessCount'(2*'DefaultMaxClassProcessCount')


2

I doubt you'll find this neatly written up from a reliable source. I think the answer to your headline question is to take a look at suPHP. Unfortunately the documentation is rather sparse. Out of the box suPHP is compiled in paranoid mode which means that you have to set the user and group that you want PHP to run as with the suPHP_UserGroup directive on ...


2

Trac is written in Python and supports running under mod_wsgi (per an item in the FAQ), so I'd drop several of those moving parts and switch to the fantastic mod_wsgi, which supports specifying a user for a script to run as. I use this functionality for another project and it works well. Checking for the official mod_wsgi docs, to point you at how this is ...


2

I'm using the IUS RPMs from Rackspace, and suexec came compiled and configured by default. Here are the pertinent parts of my mod_fcgid config: LoadModule fcgid_module modules/mod_fcgid.so AddHandler fcgid-script fcg fcgi fpl php DefaultInitEnv PHPRC "/etc/" FCGIWrapper /usr/bin/php-cgi .php I suggest removing the "ScriptAliasMatch" Directive and ...


2

We could see your problem as 'not really a problem', as when timeout occurs the php script ends. If it was not ending after the timeout you would get in bigger problems :-). Then to reduce the hangs time you would at least be able to play with the FcgidBusyTimeout & FcgidBusyScanInterval parameters, ...


2

mysqldump by default will write lock the database while it runs so the data isn't altered during the backup, which can cause corruption. Drupal writes to the database on every request, so requests will hang while mysqldump is running, and eventually timeout. If you're using InnoDB (or can convert to it), then you can use Percona XtraBackup to do hot ...


2

Yes this is expected behaviour. It would appear you had 5 copies of ab running at the same time. This resulted in your 150 PHP processes to handle the 30 requests for each of your 5 ab processes. Apache works best when all its threads can run in memory. There will be a load at which the threads will need to be swapped to disk. Response time will ...


2

Or you can apt-get install apache2-suexec-custom after install go to cd /etc/apache2/suexec edit the file vi www-data You can see the first 2 lines, make the changes: replace /var/www with /home esc :wq after, restart apache /etc/init.d/apache2 restart


1

I have had my problem, the error is mainly because the timeout is exceeded mod_fastcgi, put the solution here which to me has solution: Modify this file /etc/httpd/conf.d/fcgid.conf and change, FcgidIOTimeout to FcgidIOTimeout 500 And restart apache: /usr/sbin/apachectl restart Source: ...


1

Your problem is here: No WP Super Cache (nginx does the caching), no XCache. Install APC and W3 Total Cache and watch your CPU usage drop back down to almost nothing. APC alone should give you some breathing room. Note that W3 Total Cache is not fully multi-site aware, and so it has to be configured on each site individually. It can be set up to use ...


1

Judging by the other errors you're seeing, it'd be very surprising if there weren't some poorly thought-out code lurking about - a code review would be the best way to approach troubleshooting. Cannot redeclare class FacebookRestClientException We know that this class was loaded successfully, so I'd start by finding out which external API's the scripts ...


1

This sounds like a DNS issue. When the site becomes unreachable by name you need to first ensure that the name correctly resolves to the IP address of the server. There are many ways to do this, such as performing an nslookup or even just a ping of the name. Only if you are indeed getting the correct address should you start looking at the Apache end of ...


1

This basically means that all the php processes are busy processing requests, and no free php processes are available to handle new incoming requests. This causes the 500 error. Usually this means that the php code that you are running is slow, swamping the php processes. Try enabling your mysql slow log to see if slow queries are the culprit, try php ...


1

As I have seen this issue with the cpanel server only, so I am assuming that you are using the same. For the fix, this is what you need to do: # mv /opt/xml2 /opt/xml2.bak Then re execute EasyApache from WHM > EasyApache (Apache Update) or via shell using the command /scripts/easyapache –force This should fix the problem. This blog explains the same.


1

The default installation of FastCGI through WHM is not ready for use after installation. It's stupid of them, even borderline dangerous, to not tell you this since it seems like it would work automatically like almost everything else you install that way does. The reason is quite simple - there's no FastCGI configuration file created by the WHM install ...


1

Please note that you can also include this in the Post VirtualHost Include of cPanel. This is done via WHM by selecting "Apache Configuration" -> "Include Editor". Then select "All Versions" in the dropdown menu under "Post VirtualHost Include". You should then put your FCGI config like this: <IfModule mod_fcgid.c> FcgidProcessLifeTime 8200 ...


1

Run apachectl -t -D DUMP_MODULES to show the modules in the currently running configuration. Note that mod_fcgid isn't in a standard CentOS 5 package. Instead of compiling it youself, you should enable the karan repo, and install it from there using yum: http://centos.karan.org/ The RPM itself can be found at: ...


1

Ownership of /etc/aliases is usually root:root; this means a normal user cannot update it. Try removing it and then running postalias with the apache user. Also check the notes and configuration mentioned in the manual page for postalias


1

These errors mean, that the scripts were running longer than 31 seconds and thus they were terminated, as your fcgid.conf says so. The standard timeout is 40 seconds btw. You can easily check this behaviour by writing a test.php: <?php sleep(32); ?> This should give you an error 500 and put this error in your logs. You have two possibilities to ...


1

I think what counts in here is the MySQL-config as well as how well you've worked on sending the right caching-headers for static content. In fact your benchmark is telling you not what you were asking for, since it is only focused on the PHP-scripts + MySQL-queries. However a site-request is more. Your benchmark does not include requests for images ...


1

The problem comes down to PHP session locking; for some reason mod_php manages to unlock the session when the request is cancelled, but mod_fcgid doesn't in this case. Calling session_write_close() before readfile() (100% safe, as I'm not going to be doing anything after outputting the file anyway, as it would corrupt it) ensures the session lock is ...


1

This is a known bug in mod_fcgid, but apparently the mod_fcgid architecture makes it difficult to address in a comprehensive way. At the moment, the best you can do is to upgrade to mod_fcgid 2.3.7 (or later); it has enhancements that at least release the memory at some point after the file upload has allocated it. My experience so far has been that it can ...


1

Couple of things I would check off the bat ... First, do you have anything printing out to your Apache Error logs ? You may need to up the log level to "warn" so as to see output from your CGI processes. Though in this case bringing it up to debug may be more beneficial as apache will print out fcgi related logging info. Checking out the access logs might ...


1

While you could debug the fcgid issue, you might find it much easier to deploy using mod_wsgi. The issue you are probably running into is related to debug=true being set in your .ini file which doesn't work in a multi-threaded mode or code that does a print to STDOUT. If you can post more of your config, log lines, etc. it should be relatively easy to see ...



Only top voted, non community-wiki answers of a minimum length are eligible