So I have a question about CHMOD with regards to a directory which I hope some kindly person can address In the example below of my home directory, the permissions imply: read, write, execute for the owner, read and write only for the group and also read and write for others. However, a directory of course can not be executed, and somewhere I read that the x in the case of directory permissions only means it is searchable. This makes sense so I just wanted to confirm it, or does it mean that any executable type files within the directory can be executed by the owner? It's a bit confusing to me because the syntax appears to be as I stated above, or in numerical form as: 755. It also looks like owner and group are the same - root? drwxr-xr-x 4 root root 4096 Mar 12 00:51 home
The "x" bit on a directory means that one can search through the directory and execute any files within it. In this case, no one but root can modify the directory. Everyone else can only execute/search through it (not modify it).
The x bit on directories means you can execute directory commands, like listing contents and such, it does not automatically mean files inside are executable. Mrk
Okay, thank you all for your help ah yes, already on to that one https://www.wilderssecurity.com/showpost.php?p=1843771&postcount=23
Yes, a nice site which is not complete, though. It doesn't mention the the -R (recursive) and the capital letter X (special execute) options - see, e.g., http://en.wikipedia.org/wiki/Chmod and http://www.freebsd.org/cgi/man.cgi?chmod
Actually, just caught my error It should state: read and execute for the group and others permissions
r bit on directories means you can execute 'ls' command x bit on directories means you can execute 'cd' command dr-------- 2 tux tux 4096 Mar 23 13:19 d1 d--x------ 2 tux tux 4096 Mar 23 13:22 d2 cd d1 bash: cd: d1: Permission denied ls d2 ls: cannot open directory d2: Permission denied
one more easy way to do things is that midnight commander (MC) i almost do every thing from mc chown chmod .......etc great tool also another easy one gnome commander