ispCP - Board - Support
Cannot Fix Internal Server Error 500 - Printable Version

+- ispCP - Board - Support (http://www.isp-control.net/forum)
+-- Forum: ispCP Omega Support Area (/forum-30.html)
+--- Forum: Usage (/forum-34.html)
+--- Thread: Cannot Fix Internal Server Error 500 (/thread-5313.html)



Cannot Fix Internal Server Error 500 - wilxp - 01-02-2009 01:54 PM

My problems are as such.

First installation attempt:
-Got the error when i use the filemanager in ispcp on a remote machine.

Second installation attempt:
-Got the error when i uploaded postnuke CMS, but works fine when i upload Wordpress.
-Filemanager still got error

Third installation attempt:
-All php scripts seem to be in error.
-Filemanager still got error

I am using Ubuntu 8.10. I intend to do a complete removal and re-installation again. Any thing that i need to take note of?

When i do setup, do i choose the default "admin.{serverhost}" or simply use {serverhost}? Do i choose fcgi or fastcgi? Are they the same?

Thank you.


RE: Cannot Fix Internal Server Error 500 - blocker - 01-02-2009 05:52 PM

fcgi & fastcgi is using the same program which is php-cgi but different method, both have + and -, better read which one you prefer. It will be helpful for community to help you if you can provide info about what kind of error you encounter. Right know i can only guess for 2nd installation probably becouse php restriction ( php.ini configuration which control security )


RE: Cannot Fix Internal Server Error 500 - sci2tech - 01-02-2009 11:08 PM

You must use last trunk. In RC7 there is no support for Ubuntu 8.10.


RE: Cannot Fix Internal Server Error 500 - balistof - 01-03-2009 02:14 AM

Altough this is an old thread I also get 500 internal server error message.

The IspCP works fine but calling php files on domains and subdomains leads to 500 internal server error messages.

I checked apache logs and logs of the domain but nothing there. Any ideas or suggestions where to start looking what's going wrong?

thanks for your help!


RE: Cannot Fix Internal Server Error 500 - c0urier - 01-03-2009 02:34 AM

This is a never ending problem.
I have several pages running into the Internal server Error 500.

Ex. at http://www.n3xt-gaming.com - When I activate:
$autoresize=1;

if($autoresize==1) {

preg_match_all("|(\[img\])(.*)(\[\/img\])|i", $content, $imgtags, PREG_SET_ORDER);
foreach($imgtags as $teil) {
$content = str_replace('[IMG]', '[img]', $content);
$content = str_replace('[/IMG]', '[/img]', $content);
$picinfo = getimagesize($teil[2]);
switch($picinfo[2]) {
case 1: $format = "gif"; break;
case 2: $format = "jpeg"; break;
}
if(!$picsize_l) $size_l = "9999"; else $size_l=$picsize_l;
if(!$picsize_h) $size_h = "9999"; else $size_h=$picsize_h;
if($picinfo[0] > $size_l OR $picinfo[1] > $size_h) $content = str_replace('[img]'.$teil[2].'[/img]', '[url='.$teil[2].']<img src="'.$teil[2].'" b$
elseif($picinfo[0] > (2*$size_l) OR $picinfo[1] > (2*$size_h)) $content = str_replace('[img]'.$teil[2].'[/img]', '[url='.$teil[2].'][b]Large pict$
else {
$content = str_replace('[img]'.$teil[2].'[/img]', '<img src="'.$teil[2].'" border="0">', $content);
}
}
}
else $content = preg_replace("#\[img\](.*?)\[/img\]#si", "<img src=\"\\1\" border=\"0\">", $content);

return $content;

}

The page is not able to load and causes the internal server error 500.

When I set $autoresize=1; to $autoresize=0; the page works fine - The function is very important to that community, since else their users will be able to post very large images which causes the page to look weird.

Apache error:
[Fri Jan 02 17:13:15 2009] [notice] mod_fcgid: call /var/www/virtual/n3xt-gaming.com/htdocs/index.php with wrapper /var/www/fcgi/n3xt-gaming.com/php5-fcgi-starter
[Fri Jan 02 17:13:40 2009] [notice] mod_fcgid: call /var/www/virtual/n3xt-gaming.com/htdocs/index.php with wrapper /var/www/fcgi/n3xt-gaming.com/php5-fcgi-starter
[Fri Jan 02 17:14:01 2009] [notice] mod_fcgid: process /var/www/virtual/n3xt-gaming.com/htdocs/index.php(3527) exit(communication error), terminated by calling exit(), return code: 0
[Fri Jan 02 17:14:43 2009] [notice] mod_fcgid: process /var/www/virtual/n3xt-gaming.com/htdocs/index.php(3536) exit(communication error), terminated by calling exit(), return code: 0
[Fri Jan 02 17:15:04 2009] [notice] mod_fcgid: call /var/www/virtual/n3xt-gaming.com/htdocs/index.php with wrapper /var/www/fcgi/n3xt-gaming.com/php5-fcgi-starter
[Fri Jan 02 17:15:54 2009] [notice] mod_fcgid: process /var/www/virtual/n3xt-gaming.com/htdocs/index.php(3551) exit(communication error), terminated by calling exit(), return code: 0
[Fri Jan 02 17:21:16 2009] [notice] mod_fcgid: call /var/www/virtual/n3xt-gaming.com/htdocs/index.php with wrapper /var/www/fcgi/n3xt-gaming.com/php5-fcgi-starter
[Fri Jan 02 17:24:40 2009] [notice] mod_fcgid: call /var/www/virtual/n3xt-gaming.com/htdocs/index.php with wrapper /var/www/fcgi/n3xt-gaming.com/php5-fcgi-starter
[Fri Jan 02 17:25:43 2009] [notice] mod_fcgid: process /var/www/virtual/n3xt-gaming.com/htdocs/index.php(3745) exit(communication error), terminated by calling exit(), return code: 0
[Fri Jan 02 17:25:45 2009] [notice] mod_fcgid: call /var/www/virtual/n3xt-gaming.com/htdocs/index.php with wrapper /var/www/fcgi/n3xt-gaming.com/php5-fcgi-starter


Same as at my own blog running wordpress, the page only loads after you retry a few times.


RE: Cannot Fix Internal Server Error 500 - balistof - 01-03-2009 03:01 AM

it just found following warning/error log entry in "/var/log/apache2/users/default-error.log"

[Fri Jan 02 17:47:58 2009] [warn] (104)Connection reset by peer: mod_fcgid: read data from fastcgi server error.
[Fri Jan 02 17:47:58 2009] [error] [client 192.168.2.100] Premature end of script headers: phpinfo.php

any ideas? I have constantly the "500 internal server problem" and was never able to run a php script


RE: Cannot Fix Internal Server Error 500 - sci2tech - 01-03-2009 04:39 AM

Possible cause:
php version <=5.2.0 (default for etch. Solution update php)
Mismatch between associated uid/gid for script, containing folder or /var/www/fcgi/domain.tld folder or content. Solution: correct uid/gid.
If limited resources or script take time to execute, increase for fcgid IPCConnectTimeout value (in /etc/apache2/mods-available/fcgid_ispcp.conf). Try switch to ispcp_fastcgi/ispcp_fcgid and see if problem persist.
Test if your configuration file template against trunk (maybe problem was corrected).


RE: Cannot Fix Internal Server Error 500 - c0urier - 01-03-2009 05:47 AM

(01-03-2009 04:39 AM)sci2tech Wrote:  Possible cause:
php version <=5.2.0 (default for etch. Solution update php)
Mismatch between associated uid/gid for script, containing folder or /var/www/fcgi/domain.tld folder or content. Solution: correct uid/gid.
If limited resources or script take time to execute, increase for fcgid IPCConnectTimeout value (in /etc/apache2/mods-available/fcgid_ispcp.conf). Try switch to ispcp_fastcgi/ispcp_fcgid and see if problem persist.
Test if your configuration file template against trunk (maybe problem was corrected).

My Settings:

Installation:
Debian Lenny - Fully updated
Latest Trunk

------------------

sci2tech: php version <=5.2.0 (default for etch. Solution update php)

Answer: Installed php:
php5_5.2.6-5_all.deb
php5-adodb_5.04-3_amd64.deb
php5-cgi_5.2.6-5_amd64.deb
php5-cli_5.2.6-5_amd64.deb
php5-common_5.2.6-5_amd64.deb
php5-gd_5.2.6-5_amd64.deb
php5-mcrypt_5.2.6-5_amd64.deb
php5-mhash_5.2.6-5_amd64.deb
php5-mysql_5.2.6-5_amd64.deb
php-pear_5.2.6-5_all.deb
libapache2-mod-fastcgi_2.4.6-1_amd64.deb
libapache2-mod-fcgid_1%3a2.2-1_amd64.deb

------------------

sci2tech:Mismatch between associated uid/gid for script, containing folder or /var/www/fcgi/domain.tld folder or content. Solution: correct uid/gid.

Answer: All uid/gid's are correct, else you'll get the internal server error 500 permanent

------------------

sci2tech:If limited resources or script take time to execute, increase for fcgid IPCConnectTimeout value (in /etc/apache2/mods-available/fcgid_ispcp.conf). Try switch to ispcp_fastcgi/ispcp_fcgid and see if problem persist.

<IfModule mod_fcgid.c>
AddHandler fcgid-script .php .php5
SocketPath /var/lib/apache2/fcgid/sock
IPCConnectTimeout 600
</IfModule>


And since it's already the latest trunk, it's probably not fixed. <-- That sentense is not meant bad Smile


RE: Cannot Fix Internal Server Error 500 - c0urier - 01-04-2009 06:02 AM

Well mine certainly worked after the nightly backup? Strange stuff - No more 500 errors!