Posted on 2006-05-12
Last Modified: 2013-11-18
i have to web hosting accounts and neither will let me use perl or cgi scripts!

everytime i attempt to run a script i get on both accounts:

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Question by:John-Bayles
    LVL 18

    Accepted Solution


    That is a server error that the host must resolve on their end.  So contact your hosting company where you yake hosting of your website either try these.

    1) what does the error log say?
    2) what happens when you run the script like so:
       # not like
       perl scriptname.cgi
    3) if #2 fails, check that your first line says #!/path/to/perl, do a
    "which perl" if you don't know your full /path/to/perl
    4) If #2 works, su to the webserver user (nobody?) and try to run the
    program, make sure script is 755 permissions, and directory too.
    5) Assuming all the above works, is the first line printed out
    "Content-type: text\html/n/n" ??
    6) Look and use the ScriptLog directive if you still can't find out what
    is happening.
    LVL 18

    Expert Comment

    by:Sam Panwar
    Go to

    cpanel> web log >

    see the log and tell the what log say
    LVL 14

    Expert Comment

    are you putting the scripts in your cgi-bin?  do they have proper permissions (go into file manager and check. should be 755).

    do the cgi-scripts that come bundled with your cpanel work?  cgiemail is a common one that's included. try going to if it redirects to (which is what happens when you don't supply any parameters when calling it), then things are functioning fine, it's a problem with the script you're trying to run.

    if cgiecho is present, but doesn't run, then you need to contact your provider to straighten things out.

    if cgiecho does function, and you're putting your scripts in your cgi-bin with 755 permissions, then you need to check them out.. path to perl (viewable from your cpanel home), syntax, etc.
    LVL 4

    Author Comment

    yes the files are in my cgi-bin and the permissions are set correctly

    Featured Post

    Gigs: Get Your Project Delivered by an Expert

    Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

    Join & Write a Comment

    Preface This article introduces an authentication and authorization system for a website.  It is understood by the author and the project contributors that there is no such thing as a "one size fits all" system.  That being said, there is a certa…
    Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
    Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
    The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now