in reply to Writing to the File

Permission denied must not relate only to the directory where you want to write files, but the entire path.

Check whether the directories which are components of the path are executable for the given UID/GID, for the process which writes has to chdir to that directory (i.e. execute all directories along the path).

--shmem

_($_=" "x(1<<5)."?\n".q·/)Oo.  G°\        /
                              /\_¯/(q    /
----------------------------  \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}