Bind-Mount a Directory to a Second Path

Make a directory appear elsewhere without symlinks or copies.

LinuxFilesdiskconfigMedium risk
Run sudo mount --bind /source /target to expose the same files at both paths.

01Command

Command
$ sudo mkdir -p /srv/data && sudo mount --bind /home/user/data /srv/data

02What it does

A bind mount shares the same underlying files at a second mount point, which is how containers and chroots give processes a restricted view of a tree. Unlike symlinks it affects all processes and survives path-relative access, making it a precise administration tool.

03Risk

RiskMedium risk
Requirementssudo apt install mount (util-linux)
!Warning: Bind mounts are not persistent unless added to fstab and are easy to forget; unmount with umount when done.

04Undo

Undo
$ sudo umount /srv/data

05Sources

Last verified: 2026-10-13 · Category: System & Settings

06Related solutions