> A directory needs 'x' to allow searching in it.
Nope. A directory needs 'r' to allow searching in it. A directory needs 'x' to allow chdir into it, and 'w' to create an entry in it.
It helps to think of a directory as a structured file (which in <update type="add"> classical </update> unix semantics, it is). Searching a directory is reading it ('r' permissions); changing directories, <update type="add">and accessing or changing the files pointed to by the directory entries</update> is executing it ('x' permissions); and modifying the directory (adding or removing entries in the structured file) is writing it ('w' permissions).
Update: So, if you want to add a new file, you need 'wx' permissions, reading the file names needs 'r', reading the file names and getting to the file itself (done by ls -l - it reads the inode) needs 'rx'. Directories act funny unless you understand what part is managed by each permission bit. Even then it can still be kindof funny.
Updates: Slight modifications after validation
--MidLifeXis
The tomes, scrolls etc are dusty because they reside in a dusty old house, not because they're unused. --hangon in this post
|