Will shiftfs help us mount a diskimage with uid:gid mapped

Saravanan Shanmugham (sarvi) sarvi at cisco.com
Sat May 2 06:04:05 UTC 2020



Our use case is as following
   1. Our fully built software build workspaces can be 800GB+
   2. We have a nightly build that builds the whole workspace 800GB, done by a generic user "buildusr"
   3. We then snapshot that workspace with snapshotting capability.
   3. We want the developer, "sarvi", to be able to clone from that snapshot and be able to do incremental software build and development in the cloned workspace or the seeded filesystem/workspace.

Problem:
All the content, files, directories in the cloned workspace are still owned by "buildusr" and not "sarvi", which causes my builds to fail with permission problems.


Can shifts help us here ?

I am not able to find any documentation on how to I can use shiftfs  to mount a diskimage with the uid:gid mapped.
For example, we have a diskimage contains a file system with full build with all the files owned by "builduser:eng".
I am trying to mount that disk image with a loop device, but want the mount to show all the files in the mount system as owned by "sarvi:eng".
There are no containers in play.  Just linux on baremetal.

Can some one provide some pointers on how to enable shiftfs on a linux and use it for the above usecase ?

Thanks,
Sarvi
Occam’s Razor Rules



More information about the kernel-team mailing list