Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 2 > General

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 19th October 2005, 15:01
Mahir Mahir is offline
Member
 
Join Date: Oct 2005
Location: The Netherlands, Apeldoorn
Posts: 40
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to Mahir Send a message via Yahoo to Mahir
Default Ispconfig cgi hosting

Sorry to make again topic i am trying to setup little hosting server but i got another little problem i can't get solved the problem is CGI scripts based on perl i maked a website gived rights to cgi (with installation on my fc4 machine i used teh suexec directory /var/www) but i can't run a single cgi script i don't know what i am doing wrong every script i wanne run i get the following:

http://www.ulyaoth.com/cgi-bin/users.cgi
(for if url not works error is: 500 error - Internal Server Error!)

I get this error on every cgi script i wanne run the log files say the following:

access_log:
83.98.249.83 - - [19/Oct/2005:14:45:48 +0200] "GET /cgi-bin/users.cgi HTTP/1.1" 500 1215 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; WOW64; SV1; .NET CLR 1.1.4322)"
83.98.249.83 - - [19/Oct/2005:14:46:41 +0200] "GET /cgi-bin/users.cgi HTTP/1.1" 500 1215 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; WOW64; SV1; .NET CLR 1.1.4322)"
83.98.249.83 - - [19/Oct/2005:14:50:26 +0200] "GET /cgi-bin/users.cgi HTTP/1.1" 500 1215 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; WOW64; SV1; .NET CLR 1.1.4322)"

error_log:
[Wed Oct 19 12:18:26 2005] [notice] SIGHUP received. Attempting to restart
[Wed Oct 19 12:18:27 2005] [warn] NameVirtualHost 192.168.2.110:80 has no VirtualHosts
[Wed Oct 19 12:18:27 2005] [notice] Digest: generating secret for digest authentication ...
[Wed Oct 19 12:18:27 2005] [notice] Digest: done
[Wed Oct 19 12:18:27 2005] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Wed Oct 19 12:18:27 2005] [notice] LDAP: SSL support unavailable
[Wed Oct 19 12:18:27 2005] [notice] mod_python: Creating 4 session mutexes based on 256 max processes and 0 max threads.
[Wed Oct 19 12:18:27 2005] [notice] Apache/2.0.54 (Fedora) configured -- resuming normal operations
[Wed Oct 19 12:18:35 2005] [notice] caught SIGTERM, shutting down
[Wed Oct 19 12:18:36 2005] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Wed Oct 19 12:18:36 2005] [notice] Digest: generating secret for digest authentication ...
[Wed Oct 19 12:18:36 2005] [notice] Digest: done
[Wed Oct 19 12:18:36 2005] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Wed Oct 19 12:18:36 2005] [notice] LDAP: SSL support unavailable
[Wed Oct 19 12:18:36 2005] [notice] mod_python: Creating 4 session mutexes based on 256 max processes and 0 max threads.
[Wed Oct 19 12:18:36 2005] [notice] Apache/2.0.54 (Fedora) configured -- resuming normal operations


suexec.log:
[2005-10-18 15:05:34]: uid: (10008/web11_mahir) gid: (10011/10011) cmd: users.cgi
[2005-10-18 15:06:37]: uid: (10008/web11_mahir) gid: (10011/10011) cmd: users.cgi
[2005-10-19 14:45:48]: uid: (10008/web11_mahir) gid: (10011/10011) cmd: users.cgi
[2005-10-19 14:46:41]: uid: (10008/web11_mahir) gid: (10011/10011) cmd: users.cgi
[2005-10-19 14:50:26]: uid: (10008/web11_mahir) gid: (10011/10011) cmd: users.cgi

Wel i don't understand where it goes wrong also in my script nothing wrong on my other server it runs with no problem but it is not that big so i sall post source also:

users.cgi:
#!/usr/bin/perl

use DB_File;

print "Content-type: text/html\n\n";
print "<pre>\n\n";
opendir(USERDIR,"/DIRECTORY PATH/online/users/");
$c = 0;
foreach $user (sort(grep !/^\./, readdir USERDIR)) {
$user =~ s/.db//;
dbmopen(%USER,"/DIRECTORY PATH/online/users/$user.db",0777);
$nik = $USER{'nick'};
$nik =~ s/>(.*)<\/A>//ig;
printf " <b>%-15s</b> %-17s %-20s %-10s\n",$1, $USER{'ip'},$USER{'room'},$USER{'mode'};
dbmclose(%USER);
$c++;
}
print "\n</pre>\n\n";
print "there are total of <b>$c</b> users online.<p>\n";


Directory Path is normally filled in i leaved it out here for private reason

Wel i hope anyone can help me with this problem.

Last edited by Mahir; 19th October 2005 at 15:12.
Reply With Quote
Sponsored Links
  #2  
Old 19th October 2005, 17:07
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,727 Times in 2,565 Posts
Default

Does users.cgi have execute permissions, and does it belong to the right user and group?

BTW, did you use the test scripts I provided? http://www.howtoforge.com/forums/showthread.php?t=171
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 19th October 2005, 17:14
Mahir Mahir is offline
Member
 
Join Date: Oct 2005
Location: The Netherlands, Apeldoorn
Posts: 40
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to Mahir Send a message via Yahoo to Mahir
Default

Will try the test script but maked simulair script only called test.cgi but also not worked i did chmod 755 on all the cgi files and directory's in the cgi-bin folder. maybe problem is that i have to make the file with VI instead of ftping it because that is on my other server also a problem i have to make every file with vi but i gues it is not smart to give everyone ssh access to the server?
Reply With Quote
  #4  
Old 19th October 2005, 17:32
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,727 Times in 2,565 Posts
Default

Quote:
Originally Posted by Mahir
Will try the test script but maked simulair script only called test.cgi but also not worked i did chmod 755 on all the cgi files and directory's in the cgi-bin folder. maybe problem is that i have to make the file with VI instead of ftping it because that is on my other server also a problem i have to make every file with vi but i gues it is not smart to give everyone ssh access to the server?
You should make sure that you save the Perl file with Unix line breaks, not Windows line breaks. Maybe that causes the error.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 19th October 2005, 17:43
Mahir Mahir is offline
Member
 
Join Date: Oct 2005
Location: The Netherlands, Apeldoorn
Posts: 40
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to Mahir Send a message via Yahoo to Mahir
Default

Yeah thank u very much i found the error,

1 i wasn't uploading in right format (very noobies)
2 it was full of windows line breaks.

But it is now working as intended thnx for reply falko
Reply With Quote
  #6  
Old 21st November 2005, 15:29
misterm misterm is offline
Senior Member
 
Join Date: Aug 2005
Posts: 513
Thanks: 13
Thanked 7 Times in 6 Posts
Angry Premature end of script headers

Somebody could give me the exact definition of this "Premature end of script headers", because that prevents me from sleeping, because I would like to have myself, how, I could arrange this problem.


MM
Reply With Quote
  #7  
Old 21st November 2005, 15:40
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,461
Thanks: 813
Thanked 5,240 Times in 4,108 Posts
 
Default

Premature end of script headers means that no HTML headers where send to the browser.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ISPConfig Roadmap till General 34 12th March 2009 11:19
ISPConfig system stoped johnking Installation/Configuration 7 27th October 2005 02:37
Server Hostname and IPSConfig Lil'Brudder Installation/Configuration 2 14th October 2005 12:46
Replicate ISPConfig mphayesuk General 5 12th October 2005 17:24
alternative ispconfig Lord_Garfield Installation/Configuration 2 8th October 2005 12:22


All times are GMT +2. The time now is 18:51.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.