Closed Thread
Results 1 to 5 of 5
Like Tree3Likes
  • 1 Post By sirduncan
  • 1 Post By descalzo
  • 1 Post By Zubair

Thread: subdomain cgi-bin 500 error

  1. #1
    sirduncan is offline x10Hosting Member sirduncan is an unknown quantity at this point
    Join Date
    Sep 2008
    Posts
    40

    subdomain cgi-bin 500 error

    I setup a subdomain (newsub.sirduncan.com), the system setup the folder for me. Within that 'sub' folder, the system also created a cgi-bin folder. I place a hello world perl script, change permissions to 777 and I get a 500 error. Further, the error does not seem to show up in my error log.

    Any ideas?
    dinomirt96 likes this.

  2. #2
    descalzo's Avatar
    descalzo is offline Grim Squeaker descalzo has a brilliant futuredescalzo has a brilliant futuredescalzo has a brilliant future
    Join Date
    Jul 2009
    Location
    Ankh-Morpork
    Posts
    7,633

    Re: subdomain cgi-bin 500 error

    1. cgi-bin permissions set to 0755?
    2. Extension of the file?
    3. File not uploaded from Windowz machine in binary?
    4. Much different from:

    Code:
    #! /usr/bin/perl
    
    use strict ;
    use CGI::Carp qw(fatalsToBrowser);
    
    
    print "Content-type: text/html\n\n";
    
    
    print "<HTML>\n";
    print "<HEAD><TITLE>Hello World!</TITLE></HEAD>\n";
    print "<BODY>\n";
    print "<H2>Hello World!</H2> <br /> \n";
    
    
    print "</BODY>\n";
    print "</HTML>\n";
    5. For security purposes, set the file permissions to 0755. Unless you have a real good reason, never have an executable file world writeable.
    verlmirt17 likes this.
    Nothing is always absolutely so.

  3. #3
    sirduncan is offline x10Hosting Member sirduncan is an unknown quantity at this point
    Join Date
    Sep 2008
    Posts
    40

    Re: subdomain cgi-bin 500 error

    Thank you descalzo. I don't know what the difference was, but the helloworld cgi is now working under that sudomain. Do you know if the strict and Carp are both required in every script?

  4. #4
    descalzo's Avatar
    descalzo is offline Grim Squeaker descalzo has a brilliant futuredescalzo has a brilliant futuredescalzo has a brilliant future
    Join Date
    Jul 2009
    Location
    Ankh-Morpork
    Posts
    7,633

    Re: subdomain cgi-bin 500 error

    Neither are required.

    strict is considered good programming practice (helps catch some misspellings).

    The Carp is good because it prints out more information when there is an error. Good for debugging, not necessary once code is in production (might print out too much info)
    Nothing is always absolutely so.

  5. #5
    Zubair's Avatar
    Zubair is offline x10 Super Spammer Zubair has a reputation beyond reputeZubair has a reputation beyond reputeZubair has a reputation beyond repute
    Join Date
    Jul 2009
    Location
    Pakistan
    Posts
    8,747

    Re: subdomain cgi-bin 500 error

    No reply From the Original poster from past 3 days. So I am going to close this thread. If the problem is still there Feel free to create a new thread.

    ***Thread Closed***
    karimirt47 likes this.
    Zubair Barkat | Level 2 Tech
    █ 888-X10-9668 - zubair[@]x10hosting.com
    x10Hosting - Giving Away Hosting Since 2004

Closed Thread

Similar Threads

  1. 403 error on Subdomain
    By Tharu in forum Free Hosting
    Replies: 4
    Last Post: 11-17-2008, 06:18 AM
  2. An 500 Internal Error on my subdomain?
    By jeffreyh in forum Free Hosting
    Replies: 2
    Last Post: 05-30-2008, 10:18 AM
  3. Subdomain creation error
    By ryanswj in forum Free Hosting
    Replies: 0
    Last Post: 10-08-2007, 04:44 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers