discover the directory that prevents a file from being read in linux
This will redirect the standard output of find
to /dev/null
, and display only the errors (including permission denied) while accessing directories.
find . -type d > /dev/null
If you're okay with limiting the check to user/group/other permissions, use
namei -l /l/o/n/g/path/file