View previous topic :: View next topic |
Author |
Message |
mamunata Apprentice
Joined: 30 Nov 2004 Posts: 169
|
Posted: Thu Oct 29, 2009 7:57 am Post subject: |
|
|
kernelOfTruth wrote: |
you need to select BFS (as a CPU scheduler instead of the stock-scheduler CFS) and select BFQ for the i/o-scheduler
kernel-config:
Code: | # CONFIG_CPU_CFS is not set
CONFIG_CPU_BFS=y
CONFIG_CPU_BFS_AUTOISO=y
# CONFIG_BFS_CUSTOM_RR is not set |
Code: | for i in /sys/block/sd*; do
/bin/echo "bfq" > $i/queue/scheduler
done |
|
I'm using latest zen sources 2.6.31-r4 with BFS and BFQ schedulers and can't see notable changes in system performance - during emerge process system load increase to 8-9 and even more.
kernelOfTruth wrote: |
the following might also provide you with additional throughput:
Code: |
for i in /sys/block/sd*; do
/bin/echo "256" > $i/queue/read_ahead_kb
/bin/echo "192" > $i/queue/max_sectors_kb
/bin/echo "1" > $i/queue/rq_affinity
/bin/echo "0" > $i/queue/nomerges
done
|
|
This doesn't seem to make any difference, and there is an error
Code: |
echo 1 > /sys/block/hda/queue/rq_affinity
echo: write error: Invalid argument
|
I haven't make any further tests but have noticed that even when using my PC for daily tasks as web browse, chat, music, file browse and so on, load is about 1 and even 1,5. With gentoo kernel from 2.6.30 branch average load was about 0.5 |
|
Back to top |
|
|
F-0_ICE l33t
Joined: 06 Dec 2004 Posts: 679
|
Posted: Fri Oct 30, 2009 7:54 pm Post subject: |
|
|
don't know if the issue is related but i get high cpu usage when writing data to hard drive.
i have a sata 1 motherboard/drive and for some reason i only have udma5 available.
i have two questions:
when writing data to my drive what is normal cpu usage?
and why don't i have anything higher than udma5 available?
i have been trying to find an answer to these on my own for a while now so i would appreciate any insight. _________________ ~AMD64
AMD: Athlon64 X2 3800+
2G PC3200
ATI: RADEON HD 4350
Linksys: WMP54G
True Knowledge is Best Acquired Through Experience. |
|
Back to top |
|
|
sidamos Apprentice
Joined: 16 Dec 2007 Posts: 246
|
Posted: Sat Oct 31, 2009 10:26 pm Post subject: |
|
|
OK, the problem is solved for me!
I have AMD64X2, IDE disks, running 32 bit Gentoo. My system was pretty unresponsive (scrolling in Firefox for example paused a lot) when running mplex or dvdauthor with source and dest files on the same disk, despite the fact that I used nice and ionice.
I tried:
- 2.6.29 with CFQ
- 2.6.29 with AS
- 2.6.30 with CFQ
- 2.6.30 with AS
- 2.6.30 with DEADLINE
All with timer 100 Hz. The best combination (with only a little "feeled" improvement) was 2.6.29 with CFQ.
Now I tried:
- 2.6.31-zen5, BFS, BFQ, 1000 Hz
And everything is good now! While running mplex or dvdauthor or copying large files over Gigabit, I can make normal use of other programs with almost no hiccups!
Of course I don't know, which of the changes fixed it:
- 2.6.31
- ZEN patches
- 1000 Hz
- BFS
- BFQ |
|
Back to top |
|
|
mamunata Apprentice
Joined: 30 Nov 2004 Posts: 169
|
Posted: Mon Nov 02, 2009 11:41 am Post subject: |
|
|
sidamos wrote: |
I have AMD64X2, IDE disks, running 32 bit Gentoo.
|
Problem that is discussed here is for 64bit version ..... or may be I'm wrong, but in my opinion 32bit systems are not affected so hard. |
|
Back to top |
|
|
d-fens Tux's lil' helper
Joined: 09 Jan 2004 Posts: 93
|
Posted: Wed Nov 04, 2009 10:20 am Post subject: |
|
|
sidamos wrote: |
- 2.6.31
- ZEN patches
- 1000 Hz
- BFS
- BFQ |
i had too many throwbacks to be convinced completely, but it seems to solve all the troubles i had with performance
my personal testcase (emerge hugin) runs smooth - yay! |
|
Back to top |
|
|
kernelOfTruth Watchman
Joined: 20 Dec 2005 Posts: 6111 Location: Vienna, Austria; Germany; hello world :)
|
|
Back to top |
|
|
snipe n00b
Joined: 12 Nov 2009 Posts: 6
|
Posted: Thu Nov 12, 2009 5:03 pm Post subject: |
|
|
Switched from gentoo-sources to zen-sources just to try this out and it was a big difference.
Now using 2.6.31-zen7 with SLQB, 1000hz and it works like a charm, No more hiccups |
|
Back to top |
|
|
albright Advocate
Joined: 16 Nov 2003 Posts: 2588 Location: Near Toronto
|
Posted: Tue Nov 17, 2009 4:51 pm Post subject: |
|
|
using
System uname: Linux-2.6.31-zen7-x86_64-Intel-R-_Core-TM-_i7_CPU_920_@_2.67GHz-with-gentoo-1.12.13
with BFS, BFQ andSQLB
I read somewhere that in kde 4.3 strigi works OK so I started it up.
System bogged right down when indexing began - mouse very slow to
respond, painful window movement etc Real ugly
system began to work properly in a minute (indexing still going on in
the background of course)
Has anyone seen this problem with strigi indexing? _________________ .... there is nothing - absolutely nothing - half so much worth
doing as simply messing about with Linux ...
(apologies to Kenneth Graeme) |
|
Back to top |
|
|
Hallerich n00b
Joined: 04 Dec 2009 Posts: 1
|
Posted: Fri Dec 04, 2009 1:12 am Post subject: 2.6.32-gentoo |
|
|
Hey all,
I suffered a lot from this problem since I switched to amd64. Now I just updated to the latest gentoo-sources (2.6.32 released yesterday), because I was curious to see if it had anything to do with the replacement of the pdflush threads (which I noticed to always stall my system when I was copying large amounts of data) with a new per backing device based writeback (see this summary on kernelnewbies.org).
Now I am happy to say that this update seems to solve all the problematic behaviour, with the system now running really smooth even with heavy IO in the background
So I expect this might help others who are affected by this as well!
Good luck guys |
|
Back to top |
|
|
kernelOfTruth Watchman
Joined: 20 Dec 2005 Posts: 6111 Location: Vienna, Austria; Germany; hello world :)
|
|
Back to top |
|
|
Sujao l33t
Joined: 25 Sep 2004 Posts: 677 Location: Germany
|
Posted: Mon Dec 07, 2009 11:38 am Post subject: Re: 2.6.32-gentoo |
|
|
Hallerich wrote: | Hey all,
I suffered a lot from this problem since I switched to amd64. Now I just updated to the latest gentoo-sources (2.6.32 released yesterday), because I was curious to see if it had anything to do with the replacement of the pdflush threads (which I noticed to always stall my system when I was copying large amounts of data) with a new per backing device based writeback (see this summary on kernelnewbies.org).
Now I am happy to say that this update seems to solve all the problematic behaviour, with the system now running really smooth even with heavy IO in the background
So I expect this might help others who are affected by this as well!
Good luck guys |
I am running 2.6.32-gentoo now. Was hashing some files (~3GB), copying others (~4GB) -> Total lockup with frozen cursor for about 30s. After that slow response. Maybe some minor improvements. No big change. |
|
Back to top |
|
|
kernelOfTruth Watchman
Joined: 20 Dec 2005 Posts: 6111 Location: Vienna, Austria; Germany; hello world :)
|
Posted: Mon Dec 07, 2009 12:46 pm Post subject: Re: 2.6.32-gentoo |
|
|
Sujao wrote: | Hallerich wrote: | Hey all,
I suffered a lot from this problem since I switched to amd64. Now I just updated to the latest gentoo-sources (2.6.32 released yesterday), because I was curious to see if it had anything to do with the replacement of the pdflush threads (which I noticed to always stall my system when I was copying large amounts of data) with a new per backing device based writeback (see this summary on kernelnewbies.org).
Now I am happy to say that this update seems to solve all the problematic behaviour, with the system now running really smooth even with heavy IO in the background
So I expect this might help others who are affected by this as well!
Good luck guys |
I am running 2.6.32-gentoo now. Was hashing some files (~3GB), copying others (~4GB) -> Total lockup with frozen cursor for about 30s. After that slow response. Maybe some minor improvements. No big change. |
with which filesystem and mount-options is that happening ? _________________ https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa
Hardcore Gentoo Linux user since 2004 |
|
Back to top |
|
|
Sujao l33t
Joined: 25 Sep 2004 Posts: 677 Location: Germany
|
Posted: Mon Dec 07, 2009 4:11 pm Post subject: Re: 2.6.32-gentoo |
|
|
kernelOfTruth wrote: | with which filesystem and mount-options is that happening ? |
Mostly xfs (rw,noatime) on a luks device (-c aes-cbc-essiv:sha256 -s 256). Home and root on ext3 with same luks parameters and additionaly on raid-1.
EDIT: I just remuxed a 4.4GB file with mmg from xfs to xfs on different hdds and even Amarok stopped playing a mp3 until mmg finished. |
|
Back to top |
|
|
zehnan1 Tux's lil' helper
Joined: 08 Oct 2004 Posts: 90 Location: Slovenia
|
Posted: Sat Dec 12, 2009 7:54 am Post subject: |
|
|
I can cofirm much better performance with BFS, BFQ, SQLB combo.
For me a test is considered the following: try to do things while unraring 8GB large file, running a game in windowed mode and playing xvid movie in smplayer. Kwin desktoip effects were on. Game ran at 130 fps (normally 155fps) without hicups, movie ran fluid without framedrops and konqueror starts in 6 seconds, firefox in 15. Desktop effects were fluid without hicups except for the resizing which doesn't work anyway.
If I try comparing this to the previous situation with CFS-CFQ; the game would would have systematic frame drops, movies exhibit similar hicup problems, the konqueror wouldn't start for half a minute and firefox wouldn't start until the rar finished and if it did I probably couldn't type in the web address because of the horrible lag. Desktop effects would become usuable.
System is quadcore with 2gb ram, kernel 2.6.31-zen7 ZEN SMP PREEMPT. |
|
Back to top |
|
|
PaulBredbury Watchman
Joined: 14 Jul 2005 Posts: 7310
|
Posted: Sat Dec 12, 2009 10:45 am Post subject: |
|
|
The pf-kernel includes BFQ and BFS, as an alternative to the zen patchset. In case this is useful for people to try.
Edit: Updated URL.
Last edited by PaulBredbury on Wed Jul 07, 2010 10:18 am; edited 1 time in total |
|
Back to top |
|
|
teapot Tux's lil' helper
Joined: 09 Nov 2006 Posts: 85 Location: Stockholm , Sweden
|
Posted: Tue Dec 15, 2009 6:21 pm Post subject: |
|
|
I have tried the new 2.6.32 kernel that comes with a new low-latency mode for CFQ enabled by default and I can confirm a huge performance increase (latency-wise , that is ).
My previous experience with 64-bit Linux on this computer was just terrible. The system "only" has 1Gb of RAM , which with firefox and a few tabs is used up pretty quickly. Let me just say that even light disk-swapping on top of a system with the all to well known I/O-induced latency problem of the Linux kernel made things completely awful.
But I am still confused and not at all convinced that this problem is solved once and for all. It cannot have been entirely CFQ's fault. The first thing I tried when I first noticed latency problems was to use another I/O-scheduler , but with little improvement.
Why does this new CFQ-mode suddenly make things a lot better ? |
|
Back to top |
|
|
Yzzyx n00b
Joined: 30 Nov 2004 Posts: 35
|
Posted: Tue Dec 22, 2009 12:35 pm Post subject: |
|
|
[quote="Sujao"] Lepaca Kliffoth wrote: |
Does it also solve the dd if=/dev/zero of=dump problem where the system locks up as soon as RAM is full?
|
No it does not. I have an AMD machine that will freeze as soon as it used all the memory while copying (in 64bit mode). I just bought a second AMD machine (cheap, all new hardware different type: chipset, memory and CPU) to test if it was a Linux problem or a hardware problem. The problem was there on this machine too. So I can crash (total freeze) both these machines at will in 64bit mode (and they do it when I dont will it too). Is anyone working on a fix for this? maybe keep the machines from allocating the last megs of memory on a AMD machine as a quick fix? |
|
Back to top |
|
|
DigitalCorpus Apprentice
Joined: 30 Jul 2007 Posts: 283
|
Posted: Thu Dec 31, 2009 3:28 am Post subject: Re: 2.6.32-gentoo |
|
|
Sujao wrote: | kernelOfTruth wrote: | with which filesystem and mount-options is that happening ? |
Mostly xfs (rw,noatime) on a luks device (-c aes-cbc-essiv:sha256 -s 256). Home and root on ext3 with same luks parameters and additionaly on raid-1.
EDIT: I just remuxed a 4.4GB file with mmg from xfs to xfs on different hdds and even Amarok stopped playing a mp3 until mmg finished. |
can you post xfs_info of the volumes in question? I used to use XFS for about a year doing heavy I/Os like what you mentioned. Having smaller than 1GB allocation groups helped significantly for this. to find the approximate optimal agsize, find out the fastest your HDD can read (hdparm -t /dev/<first fdisk partition>) and if you have a partition at end of disk, get that as well. For me I have 120MB/sec and ~60MB/sec. I opted for setting agsize close to a multiple common to both, such as 256MB or 128MB. I suffered from about a 5% throughput drop, but the latency difference between that and stock XFS was night and day. _________________ Atlas (HDTV PVR, HTTP & Media server)
http://mobrienphotography.com/ |
|
Back to top |
|
|
haarp Guru
Joined: 31 Oct 2007 Posts: 535
|
Posted: Sat Jan 09, 2010 1:10 pm Post subject: |
|
|
PaulBredbury wrote: | The pf patchset includes BFQ and BFS, as an alternative to the zen patchset. In case this is useful for people to try. |
Is there an Overlay maintaining this patchset? I couldn't find any and I'm tired of patching myself on every kernel update :/ |
|
Back to top |
|
|
pste Tux's lil' helper
Joined: 14 Dec 2004 Posts: 106
|
Posted: Mon Mar 01, 2010 7:44 pm Post subject: |
|
|
First I have to say, I may be repeating something already mentioned since this is a quite extensive thread...
I seem to have the same problem (Intel Core2Duo = amd64 as arch, currently gentoo-sources-2.6.33) and this IO-sluggishness is really annoying me. I think I saw something about a kernel bug posted, any progress from there? What I'd like to contribute is some hopefully useful info (if its not already posted, that is).
The problem becomes really evident when having a vpn-tunnel going! My log is filled with occasional
Code: | Mar 1 20:02:13 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 328092 (expecting 328086, lost or reordered)
Mar 1 20:02:13 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 328109 (expecting 328108, lost or reordered)
Mar 1 20:02:13 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 328111 (expecting 328110, lost or reordered)
Mar 1 20:02:13 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 328124 (expecting 328123, lost or reordered)
| during normal traffic (intranet surfing), a situation that perhaps is quite normal (at least so I've read somewhere), however I have a hunch it is connected to this IO problem since I'm confident that the intensity increases with increased [disk] IO and eventually end up being almost every packet, or even more??? like this:
Code: | Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342686 (expecting 342684, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342687 (expecting 342684, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342688 (expecting 342684, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342689 (expecting 342684, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342694 (expecting 342693, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342695 (expecting 342693, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342696 (expecting 342693, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342697 (expecting 342693, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342700 (expecting 342698, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342701 (expecting 342698, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342702 (expecting 342699, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342704 (expecting 342703, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342708 (expecting 342706, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342727 (expecting 342723, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342728 (expecting 342723, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342730 (expecting 342723, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342732 (expecting 342723, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342734 (expecting 342723, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342736 (expecting 342723, lost or reordered)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 log[decaps_gre:pptp_gre.c:414]: buffering packet 342729 (expecting 342723, lost or reordered)
...
| and eventually resulting in:
Code: | Mar 1 20:02:31 [pptp] nm-pptp-service-5133 warn[decaps_gre:pptp_gre.c:426]: discarding bogus packet 343022 (expecting 342723)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 warn[decaps_gre:pptp_gre.c:426]: discarding bogus packet 343023 (expecting 342723)
Mar 1 20:02:31 [pptp] nm-pptp-service-5133 warn[decaps_gre:pptp_gre.c:426]: discarding bogus packet 343024 (expecting 342723)
...
going on until VPN fails... |
With "normal" (meaning intermittent IO with pauses within reasonable time) load these bogus packet entry states seems to be recovered from, keeping the connection open. But with too intense IO it gets stuck with endless bogus packets finally terminating the VPN connection. Starting an emerge --sync in parallel with a file transfer is a sure connection breaker. What I've found to be the most certain IO blocker of all is to start a file transfer to an USB drive, that will definitely terminate the VPN tunnel within seconds!!!
Is this info useful? (sorry for the long log lists though, I only thought I'd try to convey a feeling of despair...)
Is the best "solution" really to start using zen-sources (and adherent schedulers)?? Shouldn't this work with "normal" sources? No ranting, just thinking out loud...
/pste |
|
Back to top |
|
|
lagalopex Guru
Joined: 16 Oct 2004 Posts: 565
|
Posted: Mon Mar 08, 2010 4:24 pm Post subject: |
|
|
2.6.33-ck1 bahaves pretty nice for me. But most hickups happend after some uptime, so lets wait and pray |
|
Back to top |
|
|
Mekoryuk Apprentice
Joined: 17 Sep 2003 Posts: 174
|
Posted: Mon Mar 08, 2010 10:43 pm Post subject: |
|
|
I have seen next to zero improvement, and I've been using BFS/BFQ/SQLB for several kernel releases. I'm currently on zen-2.6.31-r5. Heavy I/O still grinds my system to a halt. Just today I tried to copy a multi-gig file to a memory stick and my computer was unusable until it finished. Preallocation of multi-gig torrent files like Linux ISOs also results in the system becoming effectively unusable until the process finishes, and any emerges installing large amounts of data (like game files) does it too.
About the only improvement I've seen is gameplay in Quake Wars doesn't hiccup any more.
I remember reading somewhere there was an issue with my HDD's (Seagate Barracuda) NCQ implementation, so I'm beginning to think that I'll never see decent I/O performance until I buy a new HDD. :C |
|
Back to top |
|
|
Yamakuzure Advocate
Joined: 21 Jun 2006 Posts: 2305 Location: Adendorf, Germany
|
Posted: Tue Mar 09, 2010 1:08 pm Post subject: |
|
|
All problems with responsiveness are gone since I use gentoo-sources-2.6.32* ... I don't know why, though. _________________ Edited 220,176 times by Yamakuzure |
|
Back to top |
|
|
matze_na n00b
Joined: 04 Apr 2007 Posts: 54 Location: Germany
|
Posted: Tue Mar 09, 2010 5:53 pm Post subject: |
|
|
I wouldn't go as far as to say the problem has totally vanished, but it certainly got a lot better over the last months.
Especially the move to 2.6.33-zen1 with BFS and CFQ (since BFQ isn't available yet) was quite an improvement over 2.6.32-zen with BFS and BFQ.
At the moment, I am totally happy with my system.. Ok, there sure is a little slowdown when moving large files I guess, but it doesn't really bother me now. It's way better than a few months ago. |
|
Back to top |
|
|
PaulBredbury Watchman
Joined: 14 Jul 2005 Posts: 7310
|
Posted: Wed Jul 07, 2010 10:17 am Post subject: |
|
|
BFQ is back in pf-kernel, for anyone interested to try it. |
|
Back to top |
|
|
|