|Syntactic Confectionery Delight|
System and CGI - File Created but not the Content (Similar Situation)by holandes777 (Scribe)
|on Sep 18, 2007 at 15:13 UTC||Need Help??|
holandes777 has asked for the wisdom of the Perl Monks concerning the following question:
This is probably more an apache issue than a perl issue. Still, I have been asking for help from apache folks and gotten none. So in the words of Mathezar of Galaxy Quest, "You are our last hope!"
There is a similar thread under "System and CGI - File Created but not the Content". I thought this was different enough to post separately becasue SELinux is off in my case and perl is the file writter.
When executed the browser shows "we are trying to write", the /var/www/html/DATA/kk.txt file exists, it is 666, owned by apache and has zero content.
I am running FC4, Apache 2.0.54, perl 5.8.6, the server is not attached to the internet.
I have done what should never be done: 777 permissions on /var, /var/www, /var/www/html.
Below html I have a directory called DATA, also 777
user apache owns everything below var
setenforce 0 to remove SElinux
(basically, a desperate and ridiculous attempt to allow files to be written)
The odd thing is that the original program (from which this was extracted) up to 10am 9/17/2006. After that, the machine, untouched, exhibited the new behaviour.
All written files prior to 10 am 9/17 are apache 644 and have content. All written files after to 10am 9/17 are apache 644 and are empty.
1) I am probably not doing this the right way ... where should I be writting the files and how should I set upms and httpd.conf. I have been trolling google with "apache permissions" apachec cgi write files" and the like. If you have links to howtos, please send them!
2) In the above case, can I determine the reason and fix it? It would be nice to be able to dial back the permissions to something reasonable
Thanks in advance.