[mythtv-users] "background" balancing disks in a storage group

Chris Pinkham cpinkham at bc2va.org
Sat Apr 24 15:58:19 UTC 2010

* On Thu Apr 22, 2010 at 08:24:01AM -0400, Brian J. Murrell wrote:
> On Wed, 2010-04-21 at 19:36 -0400, Chris Pinkham wrote: 
> > 
> > Nothing exists like this currently.  We have talked about the idea
> > previously, in fact I have a patch which adds code to the JobQueue
> > to do the actual file migration.
> Nice.  But the actual migration is the easy part.  As I surmised, that
> could be done completely external to mythbackend.

Yep, that's why I haven't completed it yet, because it's a bit of work
and low on my TODO.  Also because the external myth_archive_job.pl does
a decent job of this as a semi-manual process.

> The real secret is in having the migration factor into the storage
> directory weightings and more importantly, having it planned for known
> idle times (i.e. so looking to the upcoming schedule for slots of time
> long enough to migrate a recording) and most importantly, the ability to
> pause or cancel a migration in the case of unexpected i/o bandwidth
> demands due to something new being added to the schedule.

More reasons why I haven't done it.  I see 4 different components of
Myth being involved in this.  1) The Housekeeper to schedule daily/weekly
tasks to even out storage,  2) the JobQueue to handle moving the files
around,  3) the AutoExpirer to schedule move jobs if possible instead of
having to delete recordings,  and 4) the disk scheduling code I added for
Storage Groups.  All of this and more will need to be modified to
implement this feature properly and the gain isn't enough right now to
justify bumping it up on my TODO list with the limited time I have to
work on MythTV.

I'd like to see it done though, so if anyone is looking for a project,
feel free to discuss on the list or in IRC when I'm around.

> Indeed.  Probably (hopefully) in the real world there are enough
> instances of only recording a single thing at a time to help keep the
> disk space balanced.

Yeah, this is another reason it's low on my priority list.  About a year
ago, I added a new 1TB drive to my existing Default Storage Group.  I
think I moved around 200GB of recordings onto it, just to eliminate
space concerns on my other 4 drives in the Storage Group.  I prefer the
balanced I/O (aka the original Storage Group balancing method) method of
placing recordings on the disks, but even with that mode selected, the 1TB
drive quickly started filling up because there are many times throughout
the week when only one recording is scheduled.


More information about the mythtv-users mailing list