<div class="gmail_quote">On Tue, Dec 1, 2009 at 8:12 AM, Christian Heimes <span dir="ltr"><<a href="mailto:lists@cheimes.de">lists@cheimes.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">Victor Subervi wrote:<br>
> Well, that's what I've tried. I've loaded the permissions up, 0777, and it<br>
> still throws the same error. I've also tried os.chmod(file, 0777) from the<br>
> script, and I get the same permissions error. I can do all of this from the<br>
> python prompt. I've set the ownership of the file attempting these commands<br>
> to root.root. Nothing works. Please advise.<br>
<br>
</div>You have to set the write and execute permssion on *directory*, not on<br>
the file. unlink (aka remove) requires write permission on the directory<br>
in order to remove the file.<br></blockquote><div><br>That worked! <br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
It's like in the real world. You may be allowed to modify a document (w<br>
permission on the file) but you may not be allowed to remove it from its<br>
cabinet (w permission on the directory).<br></blockquote><div><br>THANK YOU for this analogy. Hopefully, that will help me remember it the next time it occurs ;)<br>V<br></div></div>