If you want to see the the permission of a file you can use ls -l /path/to/file command.
For example
ls -l acroread -rwxr-xr-x 1 10490 floppy 17242 May 8 2013 acroread
What does this mean ?
First - represents a regular file. It gives you a hint of the type of object it is. It can have following values.
d (directory) c (character device) l (symlink) p (named pipe) s (socket) b (block device) D (door) - (regular file) r represents read permission. w represents write permission and x represents executable permission.
First combination of rwx represents permission for the owner . Second combination of rwx represents permission for the group . Third combination of rwx represents permission for the other of the file.
Octal notation
Permission of file can also be represented in octal notation. In octal notation
Read or r is represented by 4, Write or w is represented by 2 Execute x is represented by 1.
Sum of these three is use to represent the permission.
stat command can be used to view file permission in octal notation
stat -c "%a %n" /path/of/file
For example
stat -c "%a %n" acroread 755 acroread
Here you can see
stat -c "%a %n" file , 755, 644
ModuleNotFoundError: No module named 'MySQLdb', ...
Ubuntu18.04下使用pyenv安装python报错:BUILD FAILED (Ubun ...
dell提供了工具远程查看服务器硬件状态,可以修改硬件的参数,可以远程连接过去直接修改,就不需要 ...
启动报undefined symbol: EVP_CIPHER_CTX_cleanup错误。op ...
ubuntu开启crontab日志记录及解决No MTA installed, discardi ...
暂时还没有评论,第一个来评论吧!