Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'd like to rsync (backup) a chroot environment from outside the chroot. For that I first make a lvm snapshot of the chroot volume and then run rsync on that.

The only problem with this approach: Symlinks that inside the chroot are absolute are now pointing to the outer-chroot-system and are of course not matching. Since I would like to use copy-unsafe-links, this leads to a false link resolution. Is there a way to make rsync resolve symlinks from another directory than the main root or is there another way to solve this?

share|improve this question

closed as too localized by Gilles, jokerdino, Eliah Kagan, Tom Brossman, fossfreedom Oct 4 '12 at 7:21

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

The only way I can see to do this is running rsync in chroot. But that would depend on the chroot environment being able to run rsync. The next best solution is making a replica and replacing symlinks with actual files. –  Skaperen Oct 3 '12 at 19:23
Please do not ask the same question on multiple sites. This question has been answered on Unix & Linux, so I'm voting to close here. –  Gilles Oct 4 '12 at 0:06

Browse other questions tagged or ask your own question.