[mythtv-users] When does MythTV check minimum free space?
Michael T. Dean
mtdean at thirdcontact.com
Thu Feb 17 05:41:23 UTC 2011
On 02/16/2011 11:06 PM, Peter Watkins wrote:
> When does MythTV check the free space in storage directories? (FWIW
> I'm running Ubuntu's MythTV 0.23+fixes on Ubuntu 10.04 LTS.)
> I'm working on my script to re-balance expirable recordings in storage
> groups that have multiple storage directories
Note that you can move recordings to any Storage Group directory--even
across Storage Group boundaries (i.e. from "Default" to "Archive")
without needing to change anything and without causing any problems at all.
The /only/ time you can't move a recording without telling MythTV is
when you move it to a file system that the recording host can not access
(i.e. when you move it from one host to another).
> It would be very handy if I could just move files from one directory
> to another, and I do have the minimum free space set high enough that
> there's virtually always enough room -- but only if MythTV doesn't see
> the short term decrease in free space and decide to autoexpire
> something right away.
> /disk1/recordings -- 1000 GB partition, 30 GB minimum free, normally
> about 32 GB free
> /disk2/recordings -- 1500 GB partition, 30 GB minimum free, normally
> about 32 GB free
> My script wants to swap /disk1/recordings/program1.mpg and
> /disk2/recordings/program2.mpg. Let's say each recording uses 7 GB.
> The end result will be the same -- 32 GB free on each disk. But while
> each recording is being copied/moved, the target directory will dip
> down to about 25 GB free. My script is smart enough to at least avoid
> scheduled recordings -- is that good enough? Does MythTV just check
> the free space if there are fewer than N minutes before the next
> scheduled recording (or when someone uses Live TV)? Or does the
> backend(?) check every M minutes regardless of encoder status and
> recording schedule?
> I know I can use an additional directory that doesn't reside on the
> same partition as a storage directory to ensure that even LiveTV use
> won't cause problems (program1 from disk1 to extra dir, program2 from
> disk2 to disk1, program1 from extra dir to disk2), but that seems
> clunky, especially when each copy operation (for the main recording
> video file) will often take one or two minutes.
MythTV will only ever expire recordings when recordings are in
progress--and then only on the file systems to which it's recording.
You can set your auto-expire free space to 100GB and then copy stuff to
fill all of your disks to 10MB free space, and as long as you clean off
the garbage and have >100GB (plus space for the recordings in progress)
free when it starts recording, nothing will be expired.
More information about the mythtv-users