Hot answers tagged

3

If you don't mind moving the files... You could do this by moving the files into a git repository, and symlinking them to their old locations; you'd end up with ~/gitrepo/somedir/otherdir/file1 moved from ~/somedir/otherdir/file1 ~/gitrepo/otherdir/somedir/file2 moved from ~/otherdir/somedir/file2 a symlink from ~/somedir/otherdir/file1 to ...


3

Simply feed it a list of everything you DO want counted using --files0-from find -type f -print0 | du --files0-from=-


2

Git over git is just a little crazy :) Try to add to gitignore dir with your repositories. Add in your cron script command to archive your repositories before commit. (Optioal) Setup auto commit/push to all your included repository. IMHO, 1 & 2 will be good for you. cd /home tar -zcvf my-gits-backup.tar.gz path/to/git/projects git add . git commit ...


2

I also have a bunch of git repos and back them up upon logout, reboot or shutdown with rsync to my cloud. Its the simplest solution you will find out there. I also heard about bup(https://github.com/bup/bup), but never used it, so I cannot tell you how well it works. Myself, I wouldn't use git to backup multiple git repos (as I don't need a history of ...


2

After the snapshot, you can use rsnapshot diff which calls rsnapshot-diff to note the differences between two snapshots. It just compares inode numbers so is fairly efficient. Alternatively, before each backup create a file outside the backup tree to note the time, touch timestamp. Then before a new backup, create a new timestamp, touch timestamp.new, and ...


1

One possibility would be to create a read-only view of the directories you want that dedicated user to be able to back up, with bindfs. Do not use sudo at all; make rrsync the only command that's allowed to this user. One-time setup: mkdir /somewhere/backup-views /somewhere/backup-views/dir1 /somewhere/backup-views/dir2 chmod 700 /somewhere/backup-views ...


1

Yes, you would replace the UUIDs as you think. The backup filesystems all have unique UUIDs, just as the active ones do, so the entries you have in the bootable backup will all be unique. The article you reference presents a simplified example, with expanding it to multiple fstab entries "left as an exercise for the reader".


1

If you have GNU find, you can make it print the file sizes. find /source ! -type d -printf '%P %s\n' Sort the output to get deterministic output. If the filenames contain newlines, it's possible to get the same sorted output for different arrangements, but that's not going to happen unless deliberately engineered. comm -3 <(find /source ! -type d ...



Only top voted, non community-wiki answers of a minimum length are eligible