Perl / Apache on RH9.0 not working.

From: IS Manager (ismanager_at_ccbnpts.com)
Date: 04/26/04

  • Next message: Jason Dixon: "Re: Perl / Apache on RH9.0 not working."
    To: "'General Red Hat Linux discussion list'" <redhat-list@redhat.com>
    Date: Mon, 26 Apr 2004 12:44:37 -0500
    
    

    After a complete re-install of RH to v9.0 I can't get even the simplest
    of perl scripts to work in Apache. If I set the bang to -w the script
    will work but if it is not set then then I get this:
    --------------------------------
    Server error!
    The server encountered an internal error and was unable to complete your
    request.
    Error message:
    Premature end of script headers: hello.cgi
    If you think this is a server error, please contact the webmaster
    Error 500
    [site url]
    Mon 26 Apr 2004 12:36:41 PM CDT
    Apache/2.0.40 (Red Hat Linux)
    ---------------------------------

    The script in question is this:
    --------------------------------
    #!/usr/bin/perl
    #
    print <<EOP;
    Content-type: text/html

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    <html>
    <head>
            <title>Hello World!</title>
    </head>
    <body>
    <p>Hello World!</p>
    </body>
    </html>
    EOP
    --------------------------------

    Can't get any simpler than that. So anyone know what's wrong? This is
    the first time I"ve used Apache 2.0 so I'm not sure if this is an Apache
    or a Perl issue.

    Here is the mod_perl info from the server:
    ---------------------------------
    Module Name: mod_perl.c
    Content handlers: yes
    Configuration Phase Participation: Create Directory Config, Merge
    Directory Configs, Create Server Config, Merge Server Configs
    Request Phase Participation: Post-Read Request, Header Parse, Translate
    Path, Check Access, Verify User ID, Verify User Access, Check Type,
    Fixups, Logging
    Module Directives:
    PerlSwitches - Perl Switches
    PerlModule - PerlModule
    PerlRequire - PerlRequire
    PerlOptions - Perl Options
    PerlInitHandler - Subroutine name
    PerlSetVar - PerlSetVar
    PerlAddVar - PerlAddVar
    PerlSetEnv - PerlSetEnv
    PerlPassEnv - PerlPassEnv
    <Perl - NOT YET IMPLEMENTED
    =pod - Start of POD
    =back - End of =over
    =cut - End of POD
    __END__ - Stop reading config
    PerlLoadModule - A Perl module
    PerlInterpStart - Number of Perl interpreters to start
    PerlInterpMax - Max number of running Perl interpreters
    PerlInterpMaxSpare - Max number of spare Perl interpreters
    PerlInterpMinSpare - Min number of spare Perl interpreters
    PerlInterpMaxRequests - Max number of requests per Perl interpreters
    PerlInterpScope - Scope of a Perl interpreter
    PerlSendHeader - Tell mod_perl to scan output for HTTP headers
    PerlSetupEnv - Turn setup of %ENV On or Off
    PerlHandler - Subroutine name
    PerlTaintCheck - Turn on -T switch
    PerlWarn - Turn on -w switch
    PerlProcessConnectionHandler - Subroutine name
    PerlChildInitHandler - Subroutine name
    PerlPreConnectionHandler - Subroutine name
    PerlHeaderParserHandler - Subroutine name
    PerlAccessHandler - Subroutine name
    PerlAuthenHandler - Subroutine name
    PerlAuthzHandler - Subroutine name
    PerlTypeHandler - Subroutine name
    PerlFixupHandler - Subroutine name
    PerlResponseHandler - Subroutine name
    PerlLogHandler - Subroutine name
    PerlInputFilterHandler - Subroutine name
    PerlOutputFilterHandler - Subroutine name
    PerlPostReadRequestHandler - Subroutine name
    PerlTransHandler - Subroutine name
    PerlOpenLogsHandler - Subroutine name
    PerlPostConfigHandler - Subroutine name
    Current Configuration:
    ------------------------------------

    Any help would be welcome.

    Thanks in advance.

    Paul Pettit
    IT Manager / Webmaster
    Consistent Computer Bargains, Inc.
    http://www.ccbnpts.com

    -- 
    redhat-list mailing list
    unsubscribe mailto:redhat-list-request@redhat.com?subject=unsubscribe
    https://www.redhat.com/mailman/listinfo/redhat-list
    

  • Next message: Jason Dixon: "Re: Perl / Apache on RH9.0 not working."

    Relevant Pages

    • Advice for moving linux script to MacPerl
      ... in perl that runs on our Linux web server. ... - I told them to download and install MacPerl, ... script that prints the environment variables. ...
      (comp.lang.perl.misc)
    • Re: DBD::Oracle dbd_st_execute slow speed
      ... I take it you are comparing like for like with the Plus or Developer script? ... have you tried this piece of Perl with some hardcoded values? ... My DBA ran an analyze table, looked at the indexes and server ... the same oracle database and same schema and tables. ...
      (perl.dbi.users)
    • [Full-Disclosure] PR0V1NG RFP WR0NG
      ... Agree that the presented Perl code has issues, and I agree that it's very ... I've taken a sample perl test script which reads: ... Server: Netscape-Enterprise/4.1 ... I'm a washed out sell out capitalizing on my 10 seconds of fame for writing some crappy advisories and some shitty perl code. ...
      (Full-Disclosure)
    • RE: Perl / Apache on RH9.0 not working.
      ... Perl / Apache on RH9.0 not working. ... The server encountered an internal error and was unable to complete your ... Premature end of script headers: ... Configuration Phase Participation: Create Directory Config, ...
      (RedHat)
    • Re: IIS backup
      ... >script) but apparently it can't be used to restore the config and metadata ... >to move them to another server which gets backed up to tape. ...
      (microsoft.public.inetserver.iis)