Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^3: CGI script cannot create file.

by Utilitarian (Vicar)
on Dec 18, 2012 at 10:34 UTC ( #1009337=note: print w/replies, xml ) Need Help??


in reply to Re^2: CGI script cannot create file.
in thread CGI script cannot create file.

Well, you could run the following at the command prompt as your user, it does use Perl after all ;)
perl -e ' $apache = qx(ps -ef | grep httpd); @fields=split /\s+/, $apa +che; exec ("chown $fields[0] /path/to/flat/file/directory");'
However setting up a directory with write permission for the uid of the web service directly makes more sense from a certainty of action and security perspective

print "Good ",qw(night morning afternoon evening)[(localtime)[2]/6]," fellow monks."

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1009337]
help
Chatterbox?
[MidLifeXis]: hahaha: Just received a buzz-word-bingo- compliant email (internal) that starts with "%Firstname% %Lastname%...". It only gets better from there.
choroba finds working in a small company boring comparing to a large corporation
[MidLifeXis]: At least test before mass distribution.
[MidLifeXis]: More opportunities for anonymous snafus :-)
[MidLifeXis]: In a small group / company, at least you know who needs to buy the next round of beer for their mess-up.
[MidLifeXis]: :-)

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2017-01-19 12:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (170 votes). Check out past polls.