[mythtv-users] OT: rsync, or is there a better option?

Brad Templeton brad+myth at templetons.com
Fri Dec 3 22:16:34 UTC 2004

I have to say that there are some pretty robust filesystems out there
for linux, in which it should be pretty hard to lose files that are
not being written to at the moment of system crash, unless you have
a hard disk crash.   Of course only backup will prevent you from losing
data in a hard disk failure.

But for the rest, it seems a pretty expensive thing to do (most of us
feel we don't have enough disk space for our videos) on the videos
that probably are going to be watched and then deleted thereafter.

One trick (which I don't think rsync will do) would be to backup videos
only if they get to a certain age, implying they are now in your
"collection" rather than your "watch and delete" category.  I suppose
it would be nice if you could set a bit in Myth to mark such shows
but I don't know how to do that.

However, you could do the following trick:

    Run a command to create a hard link (not symlink) of your "collection"
    videos into another directory:

	cd <myth video dir>
	find . -mtime +3 -exec "mv {} ../collection"
	cc ../collection
	(insert command to rsync to your backup machine)

Of course another alternative would be to transcode videos down before
backup, since this is only a backup, and you might find it suitable
to have them slightly lower res in the event of hard disk fail.

More information about the mythtv-users mailing list