I’d love to know what is causing this - I’ve about exhausted everything I can think of. I use btrfs on my notebook with an SSD drive and it is fantastic. On my desktop, it is so bad the system is hardly usable.
I’m highly suspicious of the WD WD10EARS 4K drive, though really I see nothing that would specifically be causing this issue.
OpenSuse 12.1, kernel 3.4.0 64-bit (kernel.org source compiled via SAKC), btrfsprogs-0.19-43.10.1.x86_64
When originally installed OpenSuse 12.1 with root btrfs there were no I/O performance issues. Over time performance has gotten worse, to the point of system becoming entirely unresponsive for minutes at a time.
At random times even a copy / paste will freeze the machine for upwards of a minute. There is no relation to any particular application - happens with any application, or none at all (just on login)
Even under light use, I/O is wretched at best. Simple operations (opening kate, etc.) can far too long. iotop will show the app using 99% of io - for minutes - only to open a blank document, etc.
The last few days dropbox now start to sync but never finishes - just runs forever with meager I/O rates, but never ends. (There is not even that much new data to sync, I don’t even think it gets through the initial index phase.)
Sometimes, after a bit of use, all the btrfs-endio, btrfs-flush and btrfs-transaction, etc. kernel threads finally end and you can work for awhile. For a while. Rebooting does not help much.
Heaven forbid nepomuk, tracker-store, etc. try to run - it would take hours. (nepomuk is now disabled.)
Setting swapiness (on the thought that things like updatedb running via cron.daily would throw code pages out for disk cache, perhaps causing it to bog down when reloading libs, etc.) did not help at all.
(Swap usage is typically very low nearly at all times.)
# free -m total used free shared buffers cached Mem: 3952 3500 452 0 0 771 -/+ buffers/cache: 2728 1223 Swap: 4094 26 4068
Snapper has been disabled - if snapper runs compdirs the systems becomes completely stalled with disk I/0 to point of freezing completely.
There is no issue with the drive itself - no smart error, hdparm -tT, iozone, bonnie++ all show fine raw performance, etc.
/dev/sdb: Timing cached reads: 16936 MB in 2.00 seconds = 8475.93 MB/sec Timing buffered disk reads: 318 MB in 3.01 seconds = 105.74 MB/sec
This is a 4K (512K emulated drive) and partitions are aligned:
(/dev/sdb3 is root btrfs) # fdisk -l /dev/sdb Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x0008916e Device Boot Start End Blocks Id System /dev/sdb1 2048 1028095 513024 83 Linux /dev/sdb2 1028096 9414655 4193280 82 Linux swap / Solaris /dev/sdb3 9414656 1743808511 867196928 83 Linux /dev/sdb4 1743808512 1953523711 104857600 83 Linux
#hdparm -I /dev/sdb Model Number: WDC WD10EARS-00Y5B1 Serial Number: WD-WMAV51843412 Firmware Revision: 80.00A80
No LVM volumes on this drive, and no encrypted partitions.
At this point it has gotten so bad that a re-install is looking pretty good - this poor i7 desktop runs like its a 486. Maybe an update to 12.2 might fix it, but I’m pretty doubtful.
I would really like to know what is the real culprit here and would appreciate any insight others might be able to share.