1 |
On Mon, May 7, 2012 at 5:41 AM, Alex Schuster <wonko@×××××××××.org> wrote: |
2 |
> Some while ago, I wrote: |
3 |
> |
4 |
> [ |
5 |
> mplayer stutters when I/O is going on, even hangs for seconds when I do a |
6 |
> dd if=/dev/zero of=somefile bs=1M |
7 |
> ] |
8 |
> |
9 |
>> Urs Schutz writes: |
10 |
>> |
11 |
>> > Just an idea: Is the disk OK? Replace /dev/sda with your |
12 |
>> > disk... |
13 |
> [...] |
14 |
>> > I had a bad disk here, which resulted in slow IO, but not |
15 |
>> > complete failure. Smart detected this immediately. Sorry, |
16 |
>> > I do not know how to check disks with LVM. |
17 |
>> |
18 |
>> Didn't you get errors in yslog then? |
19 |
>> |
20 |
>> I also thought about swapping the system drive - I have a larger backup |
21 |
>> drive, with nearly identical logical volumes on it, where I make |
22 |
>> backups with rdiffbackup. So even the content is identical, except for |
23 |
>> an additional rdiff-backup directory containing the increments. So all |
24 |
>> I have to do is to echange the two volume group names, reboot, and the |
25 |
>> system will run from the other drive. But I very much doubt this will |
26 |
>> help, transfer speed looks okay to me, around 100 MB/s with dd. |
27 |
> |
28 |
> I did it in another way. I created a large file system (LVM) on my 2nd |
29 |
> drive, copied /, /usr, /var, /opt and /home over. My whole system is |
30 |
> encrypted, but I omitted this, just to make sure this is not the |
31 |
> bottleneck. |
32 |
> |
33 |
> Alas, no change. Another thing I tried was to change the SATA mode in my |
34 |
> BIOS from AHCI to whatever the other option is. This did not help either. |
35 |
> |
36 |
> Now this is really annoying. I watch small clips mostly, and can live |
37 |
> with that, and when I want to watch stuff with others, I copy the file to |
38 |
> tmpfs, which seems to help a lot. |
39 |
> |
40 |
> But now I found another solution: NOT USING KDE. |
41 |
> |
42 |
> When X crashed (trying to make the old Unreal game play), I fired up |
43 |
> another window manager, and when I played a video in there, there was no |
44 |
> problem at all. So, I have another workaround. |
45 |
> |
46 |
> But does anyone have an idea, why running KDE is the problem? Disabling |
47 |
> desktop effects does not help. |
48 |
> |
49 |
> I must be totally crazy because I still want to use KDE, despite the big |
50 |
> trouble it gives me nearly every day. Yes, most things work fine now, but |
51 |
> there are many many little problems, daily application crashes, and every |
52 |
> time I log in I fear that the desktop won't come up. 8G of RAM was not |
53 |
> enough to avoid swapping, so now I have 16G, that's fine, I no longer |
54 |
> care about kwin using 1G of my RAM. Oh, and I no longer use KMail, after |
55 |
> it ate thousands of mails I just wanted to move. No problem, they were |
56 |
> not important, but I no longer trust the KDEPIM suite. And it seems the |
57 |
> developers do not care about this, the bug report got no replies. |
58 |
> |
59 |
> But anyway. Any idea why it only happens with KDE? I will ask on the KDE |
60 |
> mailing list, but I thought I post here first, maybe there's something |
61 |
> Gentoo-specific going on here. |
62 |
> |
63 |
> Wonko |
64 |
> |
65 |
|
66 |
Hey Wonko, |
67 |
OK, fire up two terminals. In one run top, hit 1 & z so you see all |
68 |
your CPUs and then watch CPU usage. In the second terminal su to root |
69 |
and run iotop -o. Now, watch for a few minutes and get a feel for |
70 |
what's going on when video is not running. Then start your video and |
71 |
watch IO usage and CPU usage. Where's the problem? |
72 |
|
73 |
Once you get an idea where the bottleneck is we can address what a |
74 |
solution might be. In general, if the CPUs aren't maxed out and it's |
75 |
an I/O problem then usually a bit more buffering is a simple solution. |
76 |
Other more draconian solution might be a real-time kernel with a |
77 |
player (if there is one) that is set up for real-time playback. |
78 |
|
79 |
Looking forward to hearing your test results. |
80 |
|
81 |
Cheers, |
82 |
Mark |