[mythtv-users] Moving of old recordings to another Storage Group
Pieter De Wit
pieter at insync.za.net
Wed Jan 4 02:18:31 UTC 2012
Hi All,
Imaging the following disk/storage group layout:
Default: /var/lib/mythtv/recordings/
recordings_old: /var/lib/mythtv/recordings_old/
/var/lib/mythtv is a remote mount point (NFS)
/var/lib/mythtv/livetv is a local mount point*
/var/lib/mythtv/recordings is a local mount point*
* Mounted locally due to lag on the network causing pauses in LiveTV when
a new program starts, that also happen to be recorded (this, from my
investigation, generates a file in livetv/ and recordings/)
Due to the above lag issues, I would like to have the livetv stuff as
local, including recordings. The "problem" is that /var/lib/mythtv is a
2TB mount which now only houses my ripped DVDs, not something that
grows much. It seems to be a waste of space, so I came up with the idea of
"expiring" old recordings to the NFS mount. The chances that they will be
accessed is slim, but one never knows.
I wrote a script to find the recordings older than 7 days, then move them
to /var/lib/mythtv/recordings_old/ and update the DB. From what I
understand, the DB update is not *needed*, but I prefer to keep it clean.
Comments/Suggestions welcome !
Pending above comments/suggestions this will make it's way to the feature
request wiki :)
Change the variables at the top of the script to suite your local needs.
The script can be downloaded at:
http://www.insync.za.net/expire_recordings.sh
TODO:
* Read the SG_SDIR and SG_TDIR from the DB
* Fix bugs/implement suggestions ?
Cheers,
Pieter
More information about the mythtv-users
mailing list