Interview Prep/Docker/Storage, volumes and disk space

SELinux: `Permission denied` accessing a bind-mounted directory on RHEL/Fedora.

IntermediateTroubleshootingStorage, volumes and disk space
Answer

Likely causes → Host directory has no container_file_t label.

Diagnose → ls -Z /host/dir; ausearch -m avc -ts recent.

Fix → Add :z (shared) or :Z (private) to the mount, or chcon -Rt container_file_t /host/dir. Never mount /home or / with :Z.

Prevent → Keep SELinux enforcing and label volumes.

All Docker questions Roadmap: Docker & containers

More on Storage, volumes and disk space