Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 6 of 6
  1. #1
    Registered User
    Join Date
    Feb 2004
    Posts
    2

    Default Perl cgi's now need -w or -U to run

    Not sure what I have done - but suddenly all my perl scripts need me to add -U or -w on the shebang line to run (or I get a500 internal server error) - anyone have a clue (I had auto update on - have since changed to manual - but I doubt any std update would have done it ?)

    suexec log shows:

    info: (target/actual) uid: (userid/userid) gid: (userid/userid) cmd: perldiver.cgi
    [2005-07-27 16:01:47]: error: target uid/gid (32005/505) mismatch with directory (32005/505) or program (99/99) or trusted user (0/10)

    My script is chmod 0755, userid and group are userid/userid (real ones) and both the group and userid are defined in /etc/group and /etc/passwd respectively. and cgi is in /home/userid/public_html/cgi-bin

    I may experiment with turning suexec off in apache - if I can figure out how to do that (this is a test server so no impact at moment)

    Jim
    Last edited by jcarey; 07-27-2005 at 02:58 AM.

  2. #2
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Is /home/userid/public_html/cgi-bin owned by userid:userid and chmod 755? Is /home/userid/public_html owned by userid:nobody and chmod 750?
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  3. #3
    Registered User
    Join Date
    Feb 2004
    Posts
    2

    Default

    Yes - true in both cases - I noticed that the www->public_html was root.root - changed that as well to userid.nobody to no effect

    strange
    Jim

  4. #4
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    That is odd. I'm trying to wrack my brains as I have seen that before (with my perl coder hat on) but cannot rmember the cause.

    If you hit a dead end, feel free to PM me.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  5. #5
    Registered User
    Join Date
    Aug 2006
    Posts
    2

    Default

    Quote Originally Posted by chirpy
    Is /home/userid/public_html/cgi-bin owned by userid:userid and chmod 755? Is /home/userid/public_html owned by userid:nobody and chmod 750?

    Hello,

    how may i do that? in SSH? WHM? can tell me step by step? really sorry im fresh newbies..

  6. #6
    Member WebScHoLaR's Avatar
    Join Date
    Dec 2005
    Location
    Planet Earth
    Posts
    506

    Default

    You need to connect to the server via SSH. If you are on a Windows platform then you can use SSH client like Putty to connect to the server and then check the permissions and ownerships of the directories.

    Regards,
    WebScHoLaR

    WebHosting Blog: http://WebScHoLaR.net

Similar Threads & Tags
Similar threads

  1. How can a user run a .cgi script outside the cgi-bin?
    By BianchiDude in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 02-24-2009, 09:16 AM
  2. CGI files with .cgi extension don't run
    By danf in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 04-17-2008, 12:08 PM
  3. How to run Perl CGI script
    By rgaut in forum New User Questions
    Replies: 4
    Last Post: 09-02-2007, 06:06 PM
  4. Replies: 1
    Last Post: 11-05-2006, 03:46 PM
  5. cgi-bin / perl won't run
    By netnexi in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 04-15-2004, 10:12 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube