↑ ↓ select, Enter open, Esc close

Check permissions along a path

Adjust the values, the command updates live
user@server
namei -l /var/www/vhosts/example.com/httpdocs/index.php

Splits the path and shows permissions, owner and group for every level starting at /. Accessing a file requires the x permission on every parent directory. If it is missing somewhere, this shows immediately where.

Note: namei is part of util-linux and always available on Debian and Ubuntu.

Also searched as

  • permission denied although file permissions are correct
  • 403 forbidden caused by permissions
  • which folder blocks access
  • show permissions of all parent directories

Read first, then run.

The commands on myline.de act directly on servers, files and databases. A wrong path or placeholder can delete data irreversibly or make a server unreachable.

  • All commands are provided without warranty and are not tested on every system.
  • Understand what a command does before running it, and check every placeholder.
  • Make a backup first and, if possible, try it on a test system.
  • You run commands at your own risk. Liability for damages is excluded to the extent permitted by law.