Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754896AbZKSOgF (ORCPT ); Thu, 19 Nov 2009 09:36:05 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754556AbZKSOgD (ORCPT ); Thu, 19 Nov 2009 09:36:03 -0500 Received: from mail-iw0-f178.google.com ([209.85.223.178]:56380 "EHLO mail-iw0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753469AbZKSOf7 (ORCPT ); Thu, 19 Nov 2009 09:35:59 -0500 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=hIMRmxQmEPGc129mG0C7lRrQZNqf/NZ68ulp3yCCf11zw33UW1IBj3Oujw9CzAU6xI FZCbB7+R9fo8Lq2Ks6CpWuGDI3hVsJqbH8e2UGCx/qOcv2eQz1kNQQj4TE0Wzh6Ef9X6 dZZJNgGEh63bNowlDWXGTR3M2PNSrBA2irreQ= MIME-Version: 1.0 In-Reply-To: References: Date: Thu, 19 Nov 2009 23:36:04 +0900 Message-ID: <2f11576a0911190636vd21069bv2fe4f22a57b3d333@mail.gmail.com> Subject: Re: Linux 2.6.31 - very swap-happy with plenty of free RAM From: KOSAKI Motohiro To: Dan Merillat Cc: linux-kernel@vger.kernel.org, Rik van Riel , Norbert Preining , Tomasz Chmielewski , Sven-Haegar Koch , Dave Chinner Content-Type: multipart/mixed; boundary=00504501416d789b560478ba479f Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 20767 Lines: 319 --00504501416d789b560478ba479f Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi Dan, 2009/11/18 Dan Merillat : > procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu= ---- > =A0r =A0b =A0 swpd =A0 free =A0 buff =A0cache =A0 si =A0 so =A0 =A0bi =A0= =A0bo =A0 in =A0 cs us sy id wa > =A01 =A01 =A0 =A0 =A00 774404 =A049644 1713932 =A0 =A00 =A0 =A00 =A0 =A0 = 8 =A0 =A044 2680 5105 23 42 =A00 35 > =A02 =A01 =A0 =A0 =A00 774900 =A049448 1713668 =A0 =A00 =A0 =A00 =A0 =A0 = 8 =A0 =A028 2870 5101 22 41 =A00 36 > > swapon /dev/vg1/swap > > =A02 =A02 =A034460 770808 =A047824 1709852 =A0 =A00 34460 =A0 952 34472 3= 174 5601 21 48 =A02 29 > =A01 =A01 129716 759904 =A047460 1699364 =A0 =A00 95316 =A0 272 95532 309= 3 5641 16 49 =A07 29 > =A01 =A04 196728 756680 =A047436 1693616 =A0 64 67080 =A0 =A092 67104 298= 0 5569 18 49 24 =A08 > =A02 =A01 246212 754076 =A047396 1689240 =A0 32 49652 =A0 220 49760 3241 = 5405 19 51 =A01 29 > =A02 =A03 282404 791648 =A047272 1686252 =A0 16 36284 =A0 240 36392 3088 = 6281 18 52 =A09 22 > =A01 =A04 299464 847200 =A047260 1685208 =A0324 17296 =A0 324 17320 3190 = 6199 23 46 =A00 30 > =A02 =A05 302316 854384 =A047256 1685884 =A0944 3804 =A01948 =A03812 2723= 5297 20 45 =A05 31 > 11 =A03 303436 861700 =A047384 1686400 1188 1900 =A02084 =A01912 2615 459= 3 21 51 =A09 20 > swapoff -a > =A02 =A06 301740 863436 =A047384 1687048 1860 =A0 =A04 =A02368 =A0 128 25= 41 4591 21 63 =A00 15 > =A03 =A04 300076 865916 =A047384 1687604 1672 =A0 =A00 =A02120 =A0 156 26= 73 5208 19 63 =A00 18 > =A02 =A05 297676 866288 =A047380 1687988 2396 =A0 =A00 =A02668 =A0 188 26= 32 5259 17 70 =A02 12 > =A02 =A02 295556 866784 =A047380 1687956 2352 =A0 =A00 =A02352 =A0 =A0 0 = 2621 5316 16 72 =A09 =A04 > =A05 =A05 293168 867156 =A047384 1688120 2344 =A0 =A00 =A02344 =A0 =A020 = 2651 5469 18 79 =A00 =A04 > =A02 =A04 291108 870504 =A047396 1688260 2036 =A0 =A00 =A02172 =A0 160 23= 81 4817 15 67 =A00 18 > =A03 =A03 289416 870612 =A047400 1688476 2028 =A0 =A00 =A02260 =A0 148 26= 02 5214 18 69 =A00 13 > =A03 =A03 287528 871928 =A047400 1688556 1928 =A0 =A00 =A02136 =A0 =A0 0 = 2470 5096 19 68 =A03 10 > =A02 =A04 285740 873896 =A047408 1688892 2352 =A0 =A00 =A02764 =A0 172 24= 90 5194 18 66 =A00 17 > > 1.7gb of disk cache, 750 meg of free RAM, and it swaps out 300meg in a > matter of seconds when given access to a swapfile, then thrashes the > disk like crazy because that RAM was actively in use. From an > interactivity standpoint the machine is unusable - 1-2 second pauses > on mouse movement, 10-15 seconds for the window manager to change > window focus, keypresses take 1-2 seconds to show up, etc. =A0When I > issue a swapoff it takes 10-15 =A0minutes for it to slowly pull it all > back in - once it's done I run fine. > > The machine has 4gb of RAM (64bit), and runs 3 VMware VMs with a total > of 1024mb allocated to them. =A0 VMware uses file-backed RAM (for some > ungodly stupid reason) which is on a separate spindle (/dev/sdb) from > swap (/dev/sda). =A0I've got one VM pointed to a file-backed RAM on a > tmpfs (512mb) that's probably got quite a bit of memory activity. > > The other main RAM hogs are the usual suspects - firefox, Xorg, > thunderbird, openoffice, pidgin, etc, the usual junk on a busy Linux > desktop. > > All the sysctl tuneables should be defaults, there's no distro or > local changes to any vm settings (mmap_min_addr=3D0 for Wine, > shmmax=3D256mb, some ipv6 tweaks) > > Ideas on where to start looking? =A0If this is a vmware issue I'll take > it to them. Umm, very strange. I made two debug patch. can you please apply it and post following command output? % cat /proc/meminfo % cat /proc/vmstat % cat /proc/zoneinfo # cat /proc/filecache | sort -nr -k3 |head -30 --00504501416d789b560478ba479f Content-Type: application/octet-stream; name="proc-filecache-v2.patch" Content-Disposition: attachment; filename="proc-filecache-v2.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_g27mbv7z2 ZGlmZiAtLWdpdCBhL0RvY3VtZW50YXRpb24vZ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AgICAgICAyMjUwCiAK Ky4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4uLi4u Li4uLi4uLi4uLi4uLi4uLi4uLi4uLgorCitmaWxlY2FjaGU6CisKK1Byb3ZpZGVzIGFjY2VzcyB0 byB0aGUgaW4tbWVtb3J5IGZpbGUgY2FjaGUuCisKK1RvIGxpc3QgYW4gaW5kZXggb2YgYWxsIGNh Y2hlZCBmaWxlczoKKworICAgIGNhdCAvcHJvYy9maWxlY2FjaGUKKworVGhlIG91dHB1dCBsb29r cyBsaWtlOgorCisgICAgIyBmaWxlY2FjaGUgMS4wCisgICAgIyAgICAgIGlubyAgICAgICBzaXpl ICAgY2FjaGVkIGNhY2hlZCUgIHN0YXRlICAgcmVmY250ICBkZXYgICAgICAgICAgICAgZmlsZQor ICAgICAgIDEwMjYzMzQgICAgICAgICA5MSAgICAgICA5MiAgICAxMDAgICAtLSAgICAgIDY2ICAg ICAgMDM6MDIoaGRhMikgICAgIC9saWIvbGQtMi4zLjYuc28KKyAgICAgICAgMjMzNjA4ICAgICAg IDEyNDIgICAgICA5NzIgICAgIDc4ICAgLS0gICAgICA2NiAgICAgIDAzOjAyKGhkYTIpICAgICAv bGliL3Rscy9saWJjLTIuMy42LnNvCisgICAgICAgICA2NTIwMyAgICAgICAgNjUxICAgICAgNDc2 ICAgICA3MyAgIC0tICAgICAgMSAgICAgICAwMzowMihoZGEyKSAgICAgL2Jpbi9iYXNoCisgICAg ICAgMTAyNjQ0NSAgICAgICAgMjYxICAgICAgMTYwICAgICA2MSAgIC0tICAgICAgMTAgICAgICAw MzowMihoZGEyKSAgICAgL2xpYi9saWJuY3Vyc2VzLnNvLjUuNQorICAgICAgICAyMzU0MjcgICAg ICAgICAxMCAgICAgICAxMiAgICAxMDAgICAtLSAgICAgIDQ0ICAgICAgMDM6MDIoaGRhMikgICAg IC9saWIvdGxzL2xpYmRsLTIuMy42LnNvCisKKworCWlubz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dvICIsCisJCSAgIGlub2RlLT5pX21vZGUpOworCisJaWYgKGxpc3Rf ZW1wdHkoJmlub2RlLT5pX2RlbnRyeSkpIHsKKwkJaWYgKCFhdG9taWNfcmVhZCgmaW5vZGUtPmlf Y291bnQpKQorCQkJc2VxX3B1dHMobSwgIihub25hbWUpXG4iKTsKKwkJZWxzZQorCQkJc2VxX3By aW50ZihtLCAiKCUwMng6JTAyeClcbiIsCisJCQkJCWltYWpvcihpbm9kZSksIGltaW5vcihpbm9k ZSkpOworCX0gZWxzZSB7CisJCXN0cnVjdCBwYXRoIHBhdGggPSB7CisJCQkubW50ID0gTlVMTCwK KwkJCS5kZW50cnkgPSBsaXN0X2VudHJ5KGlub2RlLT5pX2RlbnRyeS5uZXh0LAorCQkJCQkgICAg IHN0cnVjdCBkZW50cnksIGRfYWxpYXMpCisJCX07CisKKwkJc2VxX3BhdGgobSwgJnBhdGgsICJc dFxuXFwiKTsKKwkJc2VxX3B1dGMobSwgJ1xuJyk7CisJfQorfQorCitzdGF0aWMgaW50IGlpX3No b3coc3RydWN0IHNlcV9maWxlICptLCB2b2lkICp2KQoreworCXVuc2lnbmVkIGxvbmcgaW5kZXgg PSAqKGxvZmZfdCAqKSB2OworCXN0cnVjdCBmY2FjaGVfcmVhZF9zdGF0ZSAqcyA9IG0tPnByaXZh dGU7CisgICAgICAgIHN0cnVjdCBpbm9kZSAqaW5vZGU7CisKKwlpZiAoaW5kZXggPT0gMCkgewor CQlzZXFfcHV0cyhtLCAiIyAgICAgIGlubyAgICAgICBzaXplICAgY2FjaGVkIGNhY2hlZCUgIgor CQkJICJyZWZjbnQgc3RhdGUgZGV2ICAgICAgICAgICAgICBtb2RlIGZpbGVcbiIpOworCX0KKwor ICAgICAgICBpbm9kZSA9IGl3aW5faW5vZGUocywgaW5kZXgpOworCXNob3dfaW5vZGUobSwgaW5v ZGUpOworCisJcmV0dXJuIDA7Cit9CisKK3N0YXRpYyB2b2lkICppaV9zdGFydChzdHJ1Y3Qgc2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mlsZWNhY2hlX29wZW4sCisJLnJlbGVhc2UJPSBm aWxlY2FjaGVfcmVsZWFzZSwKKwkucmVhZAkJPSBzZXFfcmVhZCwKKwkubGxzZWVrCQk9IHNlcV9s c2VlaywKK307CisKKworc3RhdGljIF9faW5pdCBpbnQgZmlsZWNhY2hlX2luaXQodm9pZCkKK3sK Kwlwcm9jX2NyZWF0ZSgiZmlsZWNhY2hlIiwgMDYwMCwgTlVMTCwgJnByb2NfZmlsZWNhY2hlX2Zv cHMpOworCXJldHVybiAwOworfQorbW9kdWxlX2luaXQoZmlsZWNhY2hlX2luaXQpOwo= --00504501416d789b560478ba479f Content-Type: application/octet-stream; name="0001-Add-recent-rotated-scanned-info-to-proc-zoneinfo.patch" Content-Disposition: attachment; filename="0001-Add-recent-rotated-scanned-info-to-proc-zoneinfo.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_g27mcg0t3 RnJvbSA1M2QxZDU1ZTk1NTkxODkxMTAyY2Q3ZjFjMzQwNGY0NDdlODNkZmQwIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBLT1NBS0kgTW90b2hpcm8gPGtvc2FraS5tb3RvaGlyb0BqcC5m dWppdHN1LmNvbT4KRGF0ZTogVGh1LCAxOSBOb3YgMjAwOSAyMzoxOTozOSArMDkwMApTdWJqZWN0 OiBbUEFUQ0hdIEFkZCByZWNlbnQtcm90YXRlZC9zY2FubmVkIGluZm8gdG8gL3Byb2Mvem9uZWlu Zm8KClNpZ25lZC1vZmYtYnk6IEtPU0FLSSBNb3RvaGlybyA8a29zYWtpLm1vdG9oaXJvQGpwLmZ1 aml0c3UuY29tPgotLS0KIG1tL3Ztc3RhdC5jIHwgICAxMSArKysrKysrKysrKwogMSBmaWxlcyBj aGFuZ2VkLCAxMSBpbnNlcnRpb25zKCspLCAwIGRlbGV0aW9ucygtKQoKZGlmZiAtLWdpdCBhL21t L3Ztc3RhdC5jIGIvbW0vdm1zdGF0LmMKaW5kZXggODg5MjU0Zi4uOWJmOTQ1MSAxMDA2NDQKLS0t IGEvbW0vdm1zdGF0LmMKKysrIGIvbW0vdm1zdGF0LmMKQEAgLTc2NSw2ICs3NjUsMTcgQEAgc3Rh dGljIHZvaWQgem9uZWluZm9fc2hvd19wcmludChzdHJ1Y3Qgc2VxX2ZpbGUgKm0sIHBnX2RhdGFf dCAqcGdkYXQsCiAJCSAgIHpvbmUtPnByZXZfcHJpb3JpdHksCiAJCSAgIHpvbmUtPnpvbmVfc3Rh cnRfcGZuLAogCQkgICB6b25lLT5pbmFjdGl2ZV9yYXRpbyk7CisKKwlzZXFfcHJpbnRmKG0sCisJ CSAgICJcbiAgcmVjZW50X3JvdGF0ZWRfYW5vbjogJWx1IgorCQkgICAiXG4gIHJlY2VudF9zY2Fu bmVkX2Fub246ICVsdSIKKwkJICAgIlxuICByZWNlbnRfcm90YXRlZF9maWxlOiAlbHUiCisJCSAg ICJcbiAgcmVjZW50X3NjYW5uZWRfZmlsZTogJWx1IiwKKwkJICAgem9uZS0+cmVjbGFpbV9zdGF0 LnJlY2VudF9yb3RhdGVkWzBdLAorCQkgICB6b25lLT5yZWNsYWltX3N0YXQucmVjZW50X3NjYW5u ZWRbMF0sCisJCSAgIHpvbmUtPnJlY2xhaW1fc3RhdC5yZWNlbnRfcm90YXRlZFsxXSwKKwkJICAg em9uZS0+cmVjbGFpbV9zdGF0LnJlY2VudF9zY2FubmVkWzFdKTsKKwogCXNlcV9wdXRjKG0sICdc bicpOwogfQogCi0tIAoxLjYuMi41Cgo= --00504501416d789b560478ba479f-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/