dondoucette has asked for the wisdom of the Perl Monks concerning the following question:

---NOOB ALERT---

I have a compaq proliant 3000 server (dual PIII) running Mandrake 9.2, I am attempting to install YaBB (http://www.yabbforum.com/) and I am having an odd problem, I hope someone can help.

I am logged in as ROOT to install and set permissions etc... When I attempt to open the yabb.cgi script in a wb browser locally I get the whole file printed out in my browser window like it would be in a text editor. When I try to open yabb.cgi in a browser window somewhere else on the LAN I get Forbidden You don't have permission to access /forum/cgi-bin/yabb/YaBB.cgi on this server.

I have set the permissions to 777 on all directories and files, I can open the forum,cgi-bin and yabb directories and view their contents but I can't access YaBB.cgi from my browser on the LAN.

Any thoughts? Thank you!

Retitled by davido.

Replies are listed 'Best First'.
Re: OT: Perl Oddity (2meAnyway)
by Tanktalus (Canon) on Jan 13, 2005 at 18:50 UTC

    This is not a perl question, it's a web server question. You should look up the docs on your web server.

    Hint: look for AddHandler if you're using Apache (most likely). A line like:

    AddHandler cgi-script .cgi
    can help this. It's not always a good idea, but you should read the documentation to find out if it is ok for your system.

Re: OT: Perl Oddity (2meAnyway)
by itub (Priest) on Jan 13, 2005 at 19:03 UTC
    Another thing if you are using Apache: if you are using it with suexec, it may refuse to execute CGI scripts with 0777 permissions (or any non-owner write permission on the file or any parent directory).
Re: OT: Perl Oddity (2meAnyway)
by JYDawg (Novice) on Jan 14, 2005 at 10:39 UTC

    First up, I hope this thing is not on the internet

    Second, stay away from root all files and dirs need to be read by the user running the webserver, which should never be root (locate httpd.conf; grep ^User httpd.conf). Probably it's the user apache

    If your just fooling arround try setting the apache users shell to "/bin/bash" and set it's password. Login with the apache user. If there is anything you can't do then apache won't be able to either.

    Setting every thing to perm 777 is a bad idea anyday.

    check out mod_perl if you are seriouse about creating perl cgi's

    --- Lead me not into temptation for I can find it myself...