[mythtv-users] Recording directly to RAID

Joseph Fry joe at thefrys.com
Sat Jul 28 21:01:56 UTC 2012


>
>
>  > But do yourself a favor and DONT USE RAID.
> >
> > I ran a variety of RAID configurations over the years and have finally
> seen
> > the error of my ways.
>
> > Mythtv works best with multiple drives in it's storage groups and does a
> > wonderful job spreading the load out.
>
> True: MythTV does work quite well with independent disks, and for
> MythTV-only use RAID may not pay off. But it's not quite that
> clear-cut as you suggest.
>
> > With my arrays, I would hear the drives thrashing as I recorded 2-3
> > channels, watched one recording, and had a commflag running, the
> > heads were all over the disks; because the array used all of the
> > disks for each of 5 processes.
>
> That can happen - getting a RAID array to be efficient with
> multiple processes takes some tuning, you need more RAM
> for buffering and good SATA card(s).
>
> But my 5-disk RAID10 server can handle everything I can throw
> at it over gigabit network, including several mythtv recordings
> at the same time with lots of other stuff going on.
> There's no way I could've gotten similar performance without RAID.
>
> If it was dedicated to MythTV use, it might not be worthwhile,
> especially if you're not managing RAID arrays otherwise,
> as it does add complexity to the system and getting it to
> run well takes time and effort.
>

I am speaking in context of a Myth backend... if they have additional needs
that warrant the increased bandwidth for a single read/write operation that
is a different story altogether.  A typical disk can support multiple
recording and playback operations and the data rates we see in modern
media, so bandwidth saturation isn't an issue.

Additionally, most RAID arrays bandwidth is lower than the combined JBOD
bandwidth (perhaps not with a high end controller or ideal workload). But
doing X reads/writes across X individual disks will likely be faster than
doing X reads/writes to a single array (if X is greater than 2 or 3).


> Additionally, software raid has significant overhead... so a few percent
> of
> > my processor was dedicated to just handling the IO.
>
> That is hardly significant unless you're using Atom or similar
> ultra-low-power CPU.


Depends upon how you define significant.  I noticed my commflagging and
transcoding jobs complete between 5 & 10% faster after splitting the array.
 I know it is only a couple % of processor time... but I don't believe that
it's all about processor time.  My experience makes me believe that some
processes may only use 1 or 2% cpu time but have a substantially greater
impact on a CPU limited process; software raid is one of those.  I suspect
it has to do with cache or RAM bandwidth/utilization, though I would think
that DMA would limit that impact.


> What RAID gives you that no backup can is uptime: recording won't
> stop because one disk dies. And that is really the only good reason
> for considering RAID in a dedicated mythtv box.
>

Very few, mythtv users need a HA (high availability) myth server.  While it
stinks to miss your favorite show, or even a couple of them... the cost of
a RAID array (even software RAID) far exceeds the loss.  Perhaps if your
career or business depended upon seeing a particular recording... but then
there are so many other things that you would need to put in place to
ensure that you didn't miss it (redundant tuners, cable/antenna feeds, that
RAID would only be the start).


>
> RAID can also give serious performance boost, but as noted that takes some
> tuning and in a mythtv-only setup set of single disks will do quite
> well without any effort.
>

It is false that RAID gives you a performance boost.  No RAID array can
sustain transfers faster than the transfer rate of the individual drives
combined.  Try it some time; create the fastest array you can and stream
100GB of zeros to it.  Now split the array and write 100GB/# of drives to
each drive simultaneously.  Unless your controller simply can't handle
standalone disks well, you should find that the same amount of data can be
written to your drives faster than it could when they are RAIDed.  All RAID
has a performance HIT not a boost.

Where RAID is faster is doing single operations.  Rarely, such as when
concurrent recordings seem to all be going to the same disk (because of the
logic behind the storage group load balancing) a RAID array would have the
advantage... but MOST of the time, the load is spread pretty equally, so I
am getting better performance than what RAID can offer.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mythtv.org/pipermail/mythtv-users/attachments/20120728/fc9e4e56/attachment.html>


More information about the mythtv-users mailing list