Get Numeric File/Directory Permissions

  • Run the following command as root on a file/directory of your choice:
stat -c %a /etc/hosts
  • You should get the numeric permissions of the file/directory output:
644