On Tue, Dec 1, 2009 at 8:12 AM, Christian Heimes <li...@cheimes.de> wrote:
> Victor Subervi wrote: > > Well, that's what I've tried. I've loaded the permissions up, 0777, and > it > > still throws the same error. I've also tried os.chmod(file, 0777) from > the > > script, and I get the same permissions error. I can do all of this from > the > > python prompt. I've set the ownership of the file attempting these > commands > > to root.root. Nothing works. Please advise. > > You have to set the write and execute permssion on *directory*, not on > the file. unlink (aka remove) requires write permission on the directory > in order to remove the file. > That worked! > > It's like in the real world. You may be allowed to modify a document (w > permission on the file) but you may not be allowed to remove it from its > cabinet (w permission on the directory). > THANK YOU for this analogy. Hopefully, that will help me remember it the next time it occurs ;) V
-- http://mail.python.org/mailman/listinfo/python-list