[mythtv-users] Myth Storage Drive failing

Michael T. Dean mtdean at thirdcontact.com
Thu Sep 5 14:16:58 UTC 2013


On 09/05/2013 10:05 AM, Ben Kamen wrote:
> Hey all... SmartD is reporting more bad sectors on one of my 2 myth 
> recording storage drives.
>
> (they are NOT in a RAID)
>
> So I figured, I could just shut mythbackend down while I copy all the 
> data to replacement
> drive and then swap (they're in hot-swap cages) them out and do 
> whatever linux management to
> get the new drive online/where I want.
>
> Should be that simple, yes?

Yes.

> OR -- is there a fancier way to do this where myth can keep running 
> but just
> not record to that drive anymore. (like going into Myth setup and 
> changing all the storage locations.
> I'm not as thrilled with that idea just from remember to put 
> everything back.)

Yes.  You can either just delete the directory/directories on the file 
system in question from your Storage Group directory lists (make sure 
you do it for all SGs that have any directories on that file system).  Or:

mv /path/to/directory/in/storage/group 
/path/to/directory/in/storage/group-offline

So that now the directory you told MythTV to use doesn't exist, so it 
won't use it.  (Note, also, that you need to make sure you're using an 
appropriate Storage Group Disk Scheduler ( 
http://www.mythtv.org/wiki/Storage_Groups#Storage_Group_Disk_Scheduler ) 
for this to work.  Specifically, use either Balanced I/O or Combination, 
but do /not/ use either of Balanced Free Space or Balanced Percent Free 
Space because of a bug in those implementations that will cause MythTV 
to still try to use the non-existent directory for writing new 
recordings (resulting in failed recordings).)

You should restart mythbackend after changing the directory name, 
though, to make sure it picks up on the change.

The latter approach also has the benefit that it doesn't change any of 
MythTV's configuration (meaning there's no configuration to change back) 
and only changes a file system on a broken drive that needs fixing 
(probably at least a bad-sector check with the drive tools from the 
vendor and a reformat) before you could consider using it with MythTV.  
So, you won't even have to change that directory name back--as you'll be 
rebuilding the whole file system at minimum.

Mike


More information about the mythtv-users mailing list