|
|
#1 (permalink) |
|
Registered User
Seasoned Poster
Joined in Oct 2007
54 posts
Gave thanks: 3
Thanked 3 times
|
I can't write files with CGI Perl
I have an old script that needs to run as CGI Perl. I moved it to a new server, but am not able to write files, even in a directory that is set to 777. I am thinking this might be because Perl is running as an unknown user, and doesn't have execute permissions to the directory containing the directory I am trying to write too - which means it can't set it as it's working directory?
Does anyone know how I need to set my permissions to let Perl be able to write files? |
|
|
|
|
|
#2 (permalink) |
|
URB4N 5K1LLZ
Super #1
Joined in Sep 2005
Lives in Orlando, FL
Hosted on SH63
2,648 posts
Gave thanks: 81
Thanked 127 times
|
Have you gone into your Cpanel and checked on the Perl Modules feature? I've never worked with CGI/Perl scripts before, so I'm not 100% sure, but from looking over it on Cpanel, it looks like it could help you. =)
__________________
Roxanne Surpass Staff Urban Roxy -Personal Blog SH63 - the best darn shared server!
|
|
|
|
|
|
#3 (permalink) |
|
Surpass Developer
On a golden path...
Joined in Jan 2004
Lives in Florida
Hosted on decc.surpasshosting.com
399 posts
Gave thanks: 10
Thanked 68 times
|
Your perl script should be 755. The directory you are trying to write to should also be 755 because it will be run in suexec mode. Which means it will run as your username instead of the default "nobody" user. If the permissions are 777, its not going to run at all. You may wish to also check the Error Log in cPanel, which will log any system errors your script generates
__________________
Mark Surpass Hosting Developer sɹnoʎ uɐɥʇ ɹǝʇʇǝq sı bıs ʎɯ |
|
|
|