Need help in Apache Perl-CGI set up and config
Results 1 to 5 of 5

Thread: Need help in Apache Perl-CGI set up and config

  1. #1
    Member
    Join Date
    Jul 2002
    Posts
    37

    Unhappy Need help in Apache Perl-CGI set up and config

    hello I'm a newbie in perl-cgi. Recently, I configured my apache configuration's scriptalias
    to c:/website/cgi-bin I also happened to have an activestate perl interpreter on my computer.
    my question is, why is it that when I run file:///C:/website/cgi-bin/access.pl in my web browser
    it does'nt display the contents in html? Instead it runs the perl interpreter in dos mode?
    Is there something wrong with my configuration? Help please
    BTW can you guys please help me with the correct set up for cgi and perl to run correctly? Thank you very much

  2. #2
    Super Moderator
    Know-it-All Master Beaver

    Join Date
    Jan 2003
    Posts
    3,914
    Hey Hey,

    A simple search on google would have helped ya here.... I'm sure you'd have found tons..

    Anways.. here's a few links for you that have the steps and process to go through.. most of them are apache, perl, php and mysql tho . but skip the steps for products you aren't using.

    http://www.lameindustries.org/tutori...s/apache.shtml
    http://www.thesitewizard.com/archive...toapache.shtml
    http://www.visca.com/clueless/perl_apache_win9x.html

    Those should do the trick for ya.

    Peace,
    HT
    IT Blog: .:Computer Defense:.
    PnCHd (Pronounced Pinched): Acronym - Point 'n Click Hacked. As in: "That website was pinched" or "The skiddie pinched my computer because I forgot to patch".

  3. #3
    Member
    Join Date
    Jul 2002
    Posts
    37
    Gee Thanks!!! That really helped a lot!

  4. #4
    Banned
    Join Date
    Jun 2003
    Posts
    1,302
    The reason that it doesn't run correctly is because Atleast as far as I have read in my CGI book. CGI scripts are aliased. Meaning that, your scripts are never actually run in front of the person that is using them.

    You should be using your scripts through a alias in your html.

    It should be something like this. (Forgive me, my HTML skills kind of suck right now.)

    <html>
    <title> This is the song that never ends </title>
    <Head> Welcome to my site!!! </title>
    <body>
    <form method = "Post" action="/cgi-bin/form.exe"> Form</form>
    ##That would be what, would get your cgi to run your perl script, whenever this page was run.
    </body>
    </html>

    You have got to forgive me if that isn't the best explanation, but I really suck at HTML, I can do the basics, I usually use other languages where my html falls off.

    If you need a better explanation, I will show you. I can grab a book real quick for about 2 mins, and then write this a better way.

    As for the set up for CGI and perl. HT pretty much covered that, but there is one thing I am going to have to say, if you are running RH, which I doubt, but you are going to have to go to services, and turn on httpd.

    Without that on, your server won't run.

  5. #5
    Member
    Join Date
    Jul 2002
    Posts
    37
    Actually I'm using windowsxp. I a bit confused because I configured the webserver in CGI based on the link that htregz posted. But each time a perl or a cgi script the explorer can't seem to find it. As a matter of fact I got this errors on my log:

    [Sun Jul 18 23:13:38 2004] [notice] Parent: Created child process 812
    [Sun Jul 18 23:13:38 2004] [notice] Child 812: Child process is running
    [Sun Jul 18 23:13:38 2004] [notice] Child 812: Acquired the start mutex.
    [Sun Jul 18 23:13:38 2004] [notice] Child 812: Starting 250 worker threads.
    [Sun Jul 18 23:13:47 2004] [error] [client 127.0.0.1] script not found or unable to stat: C:/website/cgi-binaccess.pl
    [Sun Jul 18 23:14:03 2004] [notice] Parent: Child process exited successfully.
    [Sun Jul 18 23:53:56 2004] [notice] Parent: Created child process 2296
    [Sun Jul 18 23:53:56 2004] [notice] Child 2296: Child process is running
    [Sun Jul 18 23:53:56 2004] [notice] Child 2296: Acquired the start mutex.
    [Sun Jul 18 23:53:56 2004] [notice] Child 2296: Starting 250 worker threads.
    [Sun Jul 18 23:54:07 2004] [error] [client 127.0.0.1] File does not exist: C:/website/email.pl
    [Sun Jul 18 23:54:53 2004] [error] [client 127.0.0.1] script not found or unable to stat: C:/website/cgi-binemail.pl
    [Sun Jul 18 23:56:02 2004] [error] [client 127.0.0.1] script not found or unable to stat: C:/website/cgi-binemail.pl

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

 Security News

     Patches

       Security Trends

         How-To

           Buying Guides