Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove a path prefix on backup and/or restore #262

Open
danwilliams opened this issue Apr 1, 2015 · 4 comments
Open

Remove a path prefix on backup and/or restore #262

danwilliams opened this issue Apr 1, 2015 · 4 comments

Comments

@danwilliams
Copy link

Attic uses the full path to back up. This is not always useful or wanted. In many cases I might be backing up the contents of a user's home directory, or files for a website or application, which may later be restored to a different path. In those cases, the absolute path is not only irrelevant, but annoying - it should be possible to extract at any point, from any backup set, consistently, regardless of path changes that may have happened in between (e.g. a website moving to a different server and having a different base path).

I would not mind there being some kind of warning when backing up or restoring a set which uses relative paths - perhaps, though, this would only be needed if extracting the backup to the filesystem root (i.e. /). Otherwise, it should be assumed that the user has read the manual and is using the relative path options because they know how to.

_Comparison note__: Bup allows this sort of thing, e.g. most usefully through its --graft option._

@barsanuphe
Copy link

I agree that I expected to back up a directory's contents, not where this directory is in the specific machine the backup is made. It makes extracting on another machine with different users clunky.

I think an option equivalent of bup's --strip-path would be sufficient.

@ThomasWaldmann
Copy link
Contributor

I use to assemble all useful filesystems under /rootfs using "mount --bind /real /rootfs/real" before backing up (so that I can get rid of /sys /dev /proc vfs and even get the files that reside on-disk on the root fs for /dev that are usually hidden by the vfs mounted over them).

Also, it is a bit unpretty to have always /rootfs/... filenames in the backup and in the exclude list as this is only a backup implementation detail.

@fcartegnie
Copy link

This bug is duplicate of #109

@ThomasWaldmann
Copy link
Contributor

@fcartegnie your link is wrong. Also, only link to duplicates within same project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants