PERL läuft nicht!

Apache, Lighttpd, nginx, Cherokee
Post Reply
ingoros
Posts: 22
Joined: 2005-10-02 22:14
Location: Dortmund
 

PERL läuft nicht!

Post by ingoros »

Hallo!

Auf unserem 1&1-Server mit Confixx bekomme ich Perl nicht laufen.

Das schlichte Script:

#! /usr/bin/perl
print "Hallo Welt!"

will nicht.
Der Pfad zu Perl ist korrekt.

Folgendes läuft:
linux:/home/www/web88/html/cgi-bin # perl test.cgi
Hallo Welt!
linux:/home/www/web88/html/cgi-bin #

In confixx gibt es einen Perl-Debugger und dieser verkündet "syntax OK"

Der VH hat folgende Einträge:

User web88
Group ftponly
ScriptAlias /cgi-bin/ /home/www/web88/html/cgi-bin/

Ein ls -alF ergibt:
total 12
drwxr-xr-x 2 web88 ftponly 4096 Nov 16 10:48 ./
drwxr-xr-x 5 web88 ftponly 4096 Nov 16 09:32 ../
-rwxr-xr-x 1 web88 ftponly 42 Nov 16 10:59 test.cgi*

Der Webserver läuft unter folgender Kennung:
User www
Group www1

Das Perl-Modul wird geladen. Die httpd.conf hat genau jene Einträge, die ein Apache mit Perl haben sollte.

Aber:

http://www.mansfeld-schule-bochum.de/cgi-bin/test.cgi

bringt "500 Internal Server Error" :cry:

Ich weiss nicht mehr weiter.
Hat hier jemand einen Tipp?

Ciao Ingo
killerboy
Posts: 24
Joined: 2005-11-10 13:25
 

Re: PERL läuft nicht!

Post by killerboy »

Hi,

das script muss folgendermassen aussehen:

Code: Select all

#! /usr/bin/perl

print "Content-Type: text/htmlnn";
print "Hallo Welt!";
Siehe auch http://www.httprevealer.com/usage_perl.htm[/quote]
ingoros
Posts: 22
Joined: 2005-10-02 22:14
Location: Dortmund
 

Re: PERL läuft nicht!

Post by ingoros »

Hallo killerboy!

Das hatte ich auch mittlerweile raus. Das ist aber nicht die Lösung.

Ich habe jetzt einen virtuellen Host ohne suexec am laufen, in dem das Skript mit der von angemahnten Ã?nderung läuft.
Dasselbe Skript mit den Einträgen im VH

User web88
Group ftponly

läuft erst nach Löschung dieser Einträge.

Das Problem ist wohl somit suexec.
wgot
Posts: 1675
Joined: 2003-07-06 02:03
 

Re: PERL läuft nicht!

Post by wgot »

suexec -V bzw suexec2 -V
ingoros
Posts: 22
Joined: 2005-10-02 22:14
Location: Dortmund
 

Re: PERL läuft nicht!

Post by ingoros »

gesagt getan:

linux:~ # /usr/sbin/suexec -V
-D DOC_ROOT="/srv/www/htdocs"
-D GID_MID=96
-D HTTPD_USER="www"
-D LOG_EXEC="/var/log/httpd/suexec.log"
-D SAFE_PATH="/bin:/usr/bin"
-D UID_MID=96
-D USERDIR_SUFFIX="public_html"
ingoros
Posts: 22
Joined: 2005-10-02 22:14
Location: Dortmund
 

Re: PERL läuft nicht!

Post by ingoros »

im log steht:

[2005-11-16 22:43:45]: info: (target/actual) uid: (web88/web88) gid: (ftponly/ftponly) cmd: test.cgi
[2005-11-16 22:43:45]: emerg: cannot get docroot information (/srv/www/htdocs)
:?:
ingoros
Posts: 22
Joined: 2005-10-02 22:14
Location: Dortmund
 

Re: PERL läuft nicht!

Post by ingoros »

Also die docroot ist falsch?
Hmm ..
Da müssten irgendwie die virtuellen Hosts rein, bzw. deren docroots rein?
wgot
Posts: 1675
Joined: 2003-07-06 02:03
 

Re: PERL läuft nicht!

Post by wgot »

Hallo,
ingoros wrote: Folgendes läuft:
linux:/home/www/web88/html/cgi-bin # perl test.cgi

-D DOC_ROOT="/srv/www/htdocs"
[2005-11-16 22:43:45]: emerg: cannot get docroot information (/srv/www/htdocs)
Du brauchst ein suexec das für den korrekten DocRoot /home/www compiliert ist, falls es bis vor kurzem ging ist das beim Apache-Update über Yast abhanden gekommen.

Aus dem Backup holen, selbst compilieren (beste Lösung, Forensuche hilft), oder schaun ob hier das passende dabei ist: http://sw-soft.com/de/download/confixx/addons

Gruß, Wolfgang
ingoros
Posts: 22
Joined: 2005-10-02 22:14
Location: Dortmund
 

Re: PERL läuft nicht!

Post by ingoros »

DANKE!!!
Post Reply