View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 30 posts ] 
Go to page 1, 2  Next

Print view Previous topic   Next topic  
Author Message
Search for:
 Post subject: Random pauses
PostPosted: Tue Nov 28, 2006 8:53 am 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
Ok, firstly my system spec:

CPU: Sempron 2800+
Mobo: A7n8x-vm (nforce 2 chipset with onboard gfx)
RAM: 512mb
HDD: 2 x 250Gb Maxtor 16mb cache (/myth is an LVM partition)
Capture card: Nova-T

Basically I get random pauses (1-2seconds) while watching any kind of media: AVI files, live tv, recorded tv, MP3s. I even get random pauses while playing an AVI file on my windows machine from my knoppmyth box. The pauses seem to be totally random, sometimes I only get 1 during 45mins, sometimes 3 within 10mins.

CPU usage doesn't seem to spike during the pauses. Since it also happens while streaming to another PC I suspect it is something to do with the disks/filesystem etc. I know ext3 isn't supposed to need defraging, but my /myth partition is getting on for about 2 years old now, could that be causing it?

I followed the guide on the wiki for enabling dma, and both drives definitely have dma enabled.

Does anybody have any ideas for sorting this out, or narrowing down where the problem is?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 28, 2006 9:26 am 
Offline
Joined: Sun Jul 24, 2005 4:16 pm
Posts: 508
Location: Ft. Worth TX
I have to say I've experienced this myself, with a setup running HD TV.
It doesn't happen too often, but acts like some other task runs, grabs a higher priority of processor time than Mythtv, and thens hands back the cpu cycles to Mythtv. I don't have any ideas what the culprit is though.

I can induce it by going into Mythweb, and moving through the program guide. I take this as an example of forcing cpu cycles to be used otherwise than processing the picture.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 28, 2006 11:43 am 
Offline
Joined: Fri Nov 18, 2005 9:22 am
Posts: 777
Location: spencerport, ny (USA)
I've been noticing this lately, since re-building my system after one of my drives failed.
During the pauses, I see the HDD light. Not just a flicker, but it's on steady for a few seconds. If I watch TOP in an xterm window, I see that it's got a high percentage of WA. Between 30-75% sometimes, for extended periods. When things are good, WA is < 1%.
I assume this means "waiting for I/O".

DMA IS ON. I checked that first.
Last night I noticed my disks filling up, and I'd had a crash in the backend while it did the auto expire. So I re-started and deleted a bunch of stuff (200GB) manually. It took 10 min for the deletes to catch up, and during that time, the WA state was high, and playback was unwatchable.

Just some observations....
--
Chris


Top
 Profile  
 
 Post subject:
PostPosted: Wed Nov 29, 2006 3:57 am 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
I'm thinking about doing a reinstall and see if that improves things, although i'm sure as soon as I do a new version will come out!


Top
 Profile  
 
 Post subject:
PostPosted: Sat Dec 09, 2006 6:26 am 
Offline
Joined: Tue Aug 09, 2005 2:09 pm
Posts: 107
mad_paddler wrote:
I'm thinking about doing a reinstall and see if that improves things, although i'm sure as soon as I do a new version will come out!


mad_paddler did a re-install work for you? I am having the same issue.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 4:37 am 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
I was going to do it over the weekend but after sitting down and trying to work out what all the customisations were I thought I would do some more testing first...

I closed mythfrontend, stopped mythbackend and mysql and tried playing an avi file from the command line... OMG there were no pauses!!!

This kinda rules out fragmentation or hard drive problems so I suspect something in either mythfrontend, mythbackend or mysql is stealing CPU cycles or I/O.

Another thing I have noticed is mythbackend.log is filled with these:

Code:
2006-12-11 10:34:08.783 DVB#0 Using DVB card 0, with frontend 'Conexant CX22702 DVB-T'.
2006-12-11 10:34:08.857 EITScanner: Now looking for EIT data on channel 97
2006-12-11 10:34:09.792 DVB#0 DVB SI Table Parser Started


Does anyone know if that could be causing the pauses?

EDIT:
Found this thread and seems to describe my problem. Unfortunately none of the solutions posted worked for the guy.
http://www.gossamer-threads.com/lists/m ... ded#214214


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 9:18 am 
Offline
Joined: Thu Dec 15, 2005 12:20 pm
Posts: 102
I've been having little weird pauses on my system as well, since I upgraded from R5A30.2 to R5D1.

Running a mythfilldatabase can make the HD LED go solid for a bit, during which time LiveTV gets very erratic. Then it clears up.

Strangely enough, using XvMC seems to both help and hinder the issue.

For instance, going to the Program Guide while in LiveTV causes a stoppage of both audio and video for up to a full second, and then it's fine again--until you exit the Program Guide, and it "burps" again.

Turning off XvMC fixes this--but then the CPU stays at much higher usage rates while watching LiveTV or recordings.

I know I definitely didn't have this issue with R5A30.2. Looking forward to trying the next KM with 0.20 to see what happens...

_________________
R5.5
p4/3.0 GHz
2GB PC3200
Abit IC7-G
3x Seagate 7200.10 SATA (raid1 /, raid5 /myth)
eVGA FX-5500 AGP
3x PVR-150 (model 1045)
MCEUSB2 remote w/Philips USB transceiver


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 11:01 am 
Offline
Joined: Tue Aug 09, 2005 2:09 pm
Posts: 107
I don't know what is up. My system works fine as long as I am either watching live tv or watching a recording. But if I am recording and watching anything else, (live tv, or a recording) I get the random pauses. If both tuners are recording, the resulting recordings playback fine, (or at least I haven't noticed any problems). Which would seem to point more at the player than anything else. I have my suspicions that it has to do with the fact that knoppmyth is handling buffering differently on the newer releases. I am thinking about maxing out my ram in my system, but that is probably just a shot in the dark.

-Nate

_________________
P4 1.6 GHz
1.2 GB RAM
Nvidia GeForce4 MX 4000
Hauppage PVR 500 MCE
Soundblaster Live
ATI Remote Wonder II


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 11:27 am 
Offline
Joined: Fri May 21, 2004 11:55 pm
Posts: 1206
Location: Silicon Valley, CA
I've noticed that MythTv is pretty sensitive to disk performance, especially when running an HD setup.

I used to have a 300G Seagate as my main drive but switched to an older 20G IBM for the boot 'n root drive. I now see small pauses and other screw-ups when the machins is heavily loaded -- i.e. when commercial flagging is going on while I watch and record programs.

Here is the hdparm timing from my slow root disk and my fast /myth disk:
Code:
root@mythtv:~# hdparm -tT /dev/hda

/dev/hda:
 Timing cached reads:   3880 MB in  2.00 seconds = 1940.29 MB/sec
 Timing buffered disk reads:   36 MB in  3.01 seconds =  11.96 MB/sec

root@mythtv:~# hdparm -tT /dev/hdc

/dev/hdc:
 Timing cached reads:   3892 MB in  2.00 seconds = 1945.32 MB/sec
 Timing buffered disk reads:  136 MB in  3.02 seconds =  45.10 MB/sec

The /dev/hda disk which contains / can only sustain about 12M/sec while the /myth partition can sustain over 45M/sec. But having a fast drive on /myth does not seem to be sufficient for good performance. I'm switching back to a fast root drive when I overhaul my system again.

_________________
Do you code to live, or live to code?
Search LinHES forum through Google


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 12:53 pm 
Offline
Joined: Fri Nov 18, 2005 9:22 am
Posts: 777
Location: spencerport, ny (USA)
FWIW, my "random" pauses are definitely predictable now. If I'm watching, I'll see a pause at 11:00 and then at 11:35, when the news and Leno, respectively, start recording. It's not the recording that does it - it's the purging of the old episiode. i.e. Leno starts recording, and Myth deletes the one from two days ago. There's a lot of disk activity while this happens. If I watch TOP, it shows a lot of WA usage.
Somehow, we need a "kinder, gentler" delete.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 1:06 pm 
Offline
Joined: Thu Dec 15, 2005 12:20 pm
Posts: 102
Interesting idea, thornsoft. And that definitely makes sense.

But I have a good 100GB of freespace on my /myth partition, and have tried manually deleting the LiveTV recordings well in advance.

I was thinking a 2.2 GHz P4 and 512MB of RAM would be enough, but now I'm beginning to wonder...

I saw an interesting thread over at Gossamer recently in which the debate of "fast, single core" was better or worse than "slower, dual core" ... there did not seem to be a definite answer/agreement reached by the majority of the participants, although it was implied that most of the MythTV programs won't take advantage of additional CPU's/cores.

Kinda tempted to reinstall from scratch on a faster box, anyway... hmm...

_________________
R5.5
p4/3.0 GHz
2GB PC3200
Abit IC7-G
3x Seagate 7200.10 SATA (raid1 /, raid5 /myth)
eVGA FX-5500 AGP
3x PVR-150 (model 1045)
MCEUSB2 remote w/Philips USB transceiver


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 1:39 pm 
Offline
Joined: Wed Aug 23, 2006 3:07 pm
Posts: 339
thornsoft wrote:
FWIW, my "random" pauses are definitely predictable now. If I'm watching, I'll see a pause at 11:00 and then at 11:35, when the news and Leno, respectively, start recording. It's not the recording that does it - it's the purging of the old episiode. i.e. Leno starts recording, and Myth deletes the one from two days ago. There's a lot of disk activity while this happens. If I watch TOP, it shows a lot of WA usage.
Somehow, we need a "kinder, gentler" delete.


I wonder if it's mysql then, since deleting a show basically involves deleting a file and then the mysql updates. I bet the single file delete isn't the culprit.

I've noticed my system pauses for a few seconds after I've deleted a show manually. I have 1 gig of ram, so I doubt if memory is the problem.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 1:42 pm 
Offline
Joined: Fri Nov 18, 2005 9:22 am
Posts: 777
Location: spencerport, ny (USA)
borgednow wrote:
I wonder if it's mysql then, since deleting a show basically involves deleting a file and then the mysql updates. I bet the single file delete isn't the culprit.

I may try a test tonight: I'll delete one of the older shows manually, at a time that the system wouldn't be trying to delete it. I'll see if there's a lot of HDD activity and pauses, and report back here.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 5:31 pm 
Offline
Joined: Wed Aug 23, 2006 3:07 pm
Posts: 339
thornsoft wrote:
borgednow wrote:
I wonder if it's mysql then, since deleting a show basically involves deleting a file and then the mysql updates. I bet the single file delete isn't the culprit.

I may try a test tonight: I'll delete one of the older shows manually, at a time that the system wouldn't be trying to delete it. I'll see if there's a lot of HDD activity and pauses, and report back here.


I just tried it. It doesn't seem to happen every time.

In this attempt, I wasn't recording anything when I deleted a show. The other times, I might have been recording when I noticed it.

I'm not that familiar with mysql's internal design. I could be that on certain occassions it grabs and holds the cpu while expanding the database.

I do know there is a lot going on with mysql. Deleting a show means doing a bunch of updates, logging the queries, and also doing regular background stuff such as table indexing and database resizing.

Maybe there's a way to limit mysql's cpu to no more than 50% of the cpu or something. I'll have to go read up on it.

I'm a lot more familiar with MS sql server, which is excellent at eating up cpu cycles, even when not running queries.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 8:06 pm 
Offline
Joined: Tue Aug 09, 2005 2:09 pm
Posts: 107
you could try playing around with the renice command to change the processes "nice" settings. If you run "top" on your myth machine you can see what the nice settings are for each process as well how much each process is using of your cpu.

_________________
P4 1.6 GHz
1.2 GB RAM
Nvidia GeForce4 MX 4000
Hauppage PVR 500 MCE
Soundblaster Live
ATI Remote Wonder II


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 30 posts ] 
Go to page 1, 2  Next



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu