What does the execute bit mean on a directory, as opposed to a file?
- It means the files inside the directory are executable. Permissions do not propagate; each file carries its own mode.
- It allows creating new files inside the directory. Creating and deleting entries requires the write bit on the directory, plus x to reach it.
- It grants the right to traverse the directory — to reach anything inside it by name. Without it you cannot even stat a file whose full path you already know, though with read you could still list the names. On directories, x is search permission; r is the right to list names. They are genuinely independent.
- It is meaningless on directories and ignored by the kernel. It is the single most important bit on a directory: without it the directory is unusable.
On a folder, x means you may go inside it, and without it you cannot open a file even when you know its exact name.
Directory permissions come up constantly in real debugging — a deploy that cannot read a config four levels down usually fails on a missing x somewhere in the path, not on the file's own mode. namei -l /path/to/file walks the whole chain and shows you exactly where it breaks.
Changing the file's mode. If the missing bit is on a folder above it, the file's own permissions were never the problem.