[mythtv-users] 'wa' field in 'top' is +90% when recording a show

Steven Adeff adeffs.mythtv at gmail.com
Tue Mar 21 22:16:33 UTC 2006


On 3/21/06, Daniel Walton <dwalton at cisco.com> wrote:
> On Mon, 20 Mar 2006, Brian Wood wrote:
> > On Mar 20, 2006, at 11:25 AM, Daniel Walton wrote:
> > > I've noticed that sometimes when I'm recording tv and when watching certain
> > > shows I've recorded, the cpu is pegged at 99% or 100% with most of the
> > > utilization in 'wa' (wa stands for "I/O wait state").  I record a lot of HD
> > > content so I have two 250 gig drives and I use LVM to make the two drives
> > > appear as one to mythtv.  One of these two drives is a refurb (didn't
> > > realize it until after I bought it) and I suspect that I'm only seeing the
> > > high wa utilization when I'm accessing the refurb drive.
> > >
> > > How can I verify which drive a show is stored on in a LVM enviroment?  Any
> > > other ideas on what could be causing wa to go sky high?  Trying to playback
> > > a show with the CPU hammered like this doesn't work very well.
> > >
> >
> > I don't know what makes you so quick to blame the refurb drive, I
> > don't think there's any particular reason it should be any more prone
> > to trouble than a new one. The only drive I have ever had die on me
> > was new, and I use a lot of refurbed drives.
>
> I didn't have this problem before I added the refurb drive.  Odds are its either
> the drive or the fact that I'm using LVM.  I just need a way to verify which is
> the issue.
>
> >
> > I've read that LVM has a lot of overhead, more than it has any right
> > to have. I have a pair of 250GB drives running as a software RAID0
> > array and they work just fine, I had a lot of problems when I tried
> > LVM, although I am using the system for just SD.
>
> If the LVM overhead is what is causing my high wa cpu usage then I don't see how
> LVM ever gained any popularity.  Here is a good example of the problem, this is
> happening when I run mythtranscode on a SD show:
>
> backend:~# dstat -a
> ----total-cpu-usage---- -disk/total -net/total- ---paging-- ---system-- ---load-avg---
> usr sys idl wai hiq siq|_read write|_recv _send|__in_ _out_|_int_ _csw_|_1m_ _5m_ 15m_
>  14   2  72  12   0   0|   0     0 |   0     0 |   0     0 |   0     0 |2.41 2.36 1.42
>   3   1   0  96   0   0|4740k    0 | 192B 2468B|   0     0 | 367   250 |2.41 2.36 1.42
>   1   1   0  98   0   0|3048k    0 |  64B  362B|   0     0 | 351   149 |2.41 2.36 1.42
>   0   0   0 100   0   0|   0  4096B|  64B  362B|   0     0 | 329    51 |2.38 2.35 1.42
>   0   0   0  97   0   3|   0    96k|  64B  346B|   0     0 | 331    52 |2.38 2.35 1.42
>   4   1   0  95   0   0|4100k 4096B|  64B  346B|   0     0 | 360   195 |2.38 2.35 1.42
>   4   2   0  94   0   0|6560k    0 |  64B  362B|   0     0 | 383   274 |2.38 2.35 1.42
>   5   1   0  93   1   0|8200k    0 |  64B  362B|   0     0 | 394   326 |2.38 2.35 1.42
>   4   2   0  94   0   0|6152k 4096B|  64B  362B|   0     0 | 377   267 |2.35 2.34 1.42
>   0   0   0 100   0   0|   0     0 |  64B  362B|   0     0 | 328    49 |2.35 2.34 1.42
>   0   0   0 100   0   0| 128k   20k|  64B  346B|   0     0 | 333    57 |2.35 2.34 1.42
>   1   0   0  99   0   0| 256k    0 |  64B  346B|   0     0 | 330    59 |2.35 2.34 1.42
>   6   4   0  90   0   0|10.4M    0 |  64B  346B|   0     0 | 413   403 |2.35 2.34 1.42
>   5   1   0  93   1   0|13.0M   16k| 128B  850B|   0     0 | 600   566 |2.32 2.34 1.42
>  10   6   0  85   0   0|7812k    0 | 128B  954B|   0     0 | 234   324 |2.32 2.34 1.42
>   1   0   0  99   0   0| 644k    0 | 234B  898B|   0     0 | 339   129 |2.32 2.34 1.42
>            ^^^^^
>
> My cpu has been pegged due to wa for 10 minutes now.
>
>
> > I'm not sure how to discover which drive of an LVM array your file is stored
> > on, but I believe it will use all of the capacity of the "first" drive before
> > it stores anything on the second, so if this is a fairly new system it would
> > be reasonable to assume your second drive is not yet being used if the total
> > is less than 250GB.
>
> I added the second drive in time for the winter olympics so I have more that
> 250G of recorded content.
>
> Thanks
> Daniel

have you used top to see what CPU the LVM is using?  Did you go with a
striped LVM?

If you used striped and both drives are not the same exact model then
I suspect you could see a large wa% usage.

--
Steve


More information about the mythtv-users mailing list