Score:0

move any writes from one directory in filesystem type to another directory in filesystem type

eg flag

say for example I've a directory /abc/123/tmpdir on ext4/xfs or may be any other file system type.

If I've to mount above directory onto a different directory something like - /xyz/321/tmpdir on a zfs filesystem so that all my writes on /abc/123/tmpdir will actually write on /xyz/321/tmpdir and I basically want to move all writes to another filesystem.

would symbolic link or soft link will be better way or mounting would suggested(considering fstab needs an entry since reboots will not bring back the mount)

muru avatar
us flag
Sounds like you want overlayfs
Score:0
cn flag

For the majority of purposes, a symbolic link will just do. If required because a specific application does not just follow the symbolic link, you indeed could use mount --bind instead, which allows to mount a directory on another directory elsewhere.

As you noted, this is somewhat more complicated - you need to set up, as root user, a line in /etc/fstab, whereas even a normal user can create a symlink (on places where it is permitted).

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.