Jump to content

CGI, FAST CGI or MOD APACHE?


Recommended Posts

Hello all, my question is the title.

 

I'm getting issues importing +6000 products and 500 internal server errors executings my cronjobs for automatic update product/categories and reindexing the search motor. The issue only appear when the website is running under Fast CGI.

 

I changed it to CGI and no more 500 internal server error, but the web site is much more slower than when was running under fast cgi.

 

I didn't taste the web site as MOD APACHE because I don't know if Prestashop is working well with it, and my experience with mod apache and CMS is so bad because permissions problems.

 

I hope you can help me!

Link to comment
Share on other sites

Fast CGI has it own time out, raise it up and you should be fine. 

 

You mean max_execution time? I set it to unlimited and still takes timeout importing 6000 products with my VPS at 20% cpu and 10% ram using.

Link to comment
Share on other sites

No, fast cgi has specific limits for it. More than likely the FcgidIOTimeout

 

I only can change this value for all my VPS. So I won't increase the value, I will use CGI even if my prestashop site is slower.

 

If you know how to increase this value to only 1 web site just tell me please. I'm using Parallels Plesk under Ubuntu Server 12.02.

 

Thanks !

Link to comment
Share on other sites

posting a 500 error, well doesn't tell us what the real issue is.

 

please turn on prestashop debug mode or look at php error log from hosting account.

 

doing anything else without this information, leaves us all to taking a guess, just like changing to cgi from Fast CGI (preferred by me, others may like mod/cgi)

Link to comment
Share on other sites

posting a 500 error, well doesn't tell us what the real issue is.

 

please turn on prestashop debug mode or look at php error log from hosting account.

 

doing anything else without this information, leaves us all to taking a guess, just like changing to cgi from Fast CGI (preferred by me, others may like mod/cgi)

 

The problem is the "FcgidIOTimeout", but i only can change it at all my VPS, not at one web site ...

Link to comment
Share on other sites

The problem is the "FcgidIOTimeout", but i only can change it at all my VPS, not at one web site ...

 

 

sorry if I missed the actual reason for 500 from error log above.

 

it is probably easier to just fix the code to give up control such that it's timer is reset (by hook or crook)

 

websites are 'horrible' at interrupt process, no defer/delay/wait cpu priorities, make one want to join a cult.

 

adding something like this to code, and when server lets us change it, not all do

       

set_time_limit(0);        

 

in the loop will work let your script keep going...there are most sophisticated ways, but cpu loop is pretty much lifo.

 

Link to comment
Share on other sites

Why are you worried about changing it globally? If you have your thread count manageable and memory set correctly it should not be an issue on the spawning of new processes. 

 

Not working, I'm under Parallels Plesk / Ubuntu 12.

 

Tried yo change /etc/apache2/mod-available/fcgif.conf setting FcgidIOTimeout = 0. With the php conf as max_execution_time 0, and memory limit to 512m and still getting 500 internal server error when try to execute my weight scripts.

 

With CGI is working perfect, slower, but no errors.

Link to comment
Share on other sites

  • 9 months later...

You have a time out or a memory issue somewhere, the apache error log, or fcgi error log will have information on what is happening. 

my error log shows this:

 

[sat May 23 11:17:07.754988 2015] [fcgid:warn] [pid 26020] (104)Connection reset by peer: [client  mod_fcgid: error reading data from FastCGI server, referer: http://www.mysite/index.php?controller=AdminImages&token=

[sat May 23 11:17:07.755042 2015] [core:error] [pid 26020] [client] End of script output before headers: index.php, referer: http://wwwmysite/index.php?controller=AdminImages&token=

 

Note: in that text I removed some ip and my wbsite url for security reasons. I left all the error text....

 

What might be the problem???

Link to comment
Share on other sites

×
×
  • Create New...