public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Thomas Fjellstrom <tfjellstrom@shaw.ca>
To: kvm@vger.kernel.org
Subject: Re: Memory usage with qemu-kvm-0.12.1.1
Date: Sun, 3 Jan 2010 03:08:42 -0700	[thread overview]
Message-ID: <201001030308.42862.tfjellstrom@shaw.ca> (raw)
In-Reply-To: <4B379753.6080004@redhat.com>

On Sun December 27 2009, Avi Kivity wrote:
> On 12/27/2009 07:00 PM, Daniel Bareiro wrote:
> >> Also, qemu might be leaking memory.  Please post 'pmap $pid' for all
> >> of your guests (do that before any of the other tests, on your
> >> swapped-out system).
> >
> > ---------------------------------------------------------------------
> >
> >   total           626376K
> >
> >   total           626472K
> >
> >   total           626396K
> >
> >   total           635292K
> >
> >   total           625388K
> 
> These all seem sane.  So it's a swap regression, hopefully
> 2.6.32.something will have a fix.
> 

Sorry to butt in, but heres something I've found odd:

# ps aux | grep /usr/bin/kvm | grep -v grep | cut -f6 -d' ' | xargs -n 1 -i{} pmap {} | grep total
 total           845928K
 total           450336K
 total           441968K
 total           440740K
 total           845848K
 total           465808K

root     10466  2.6  6.2 845924 253804 ?       Sl    2009 2084:29 /usr/bin/kvm -S -M pc -m 512 -smp 1 -name awiki -uuid 330abdce-f657-e0e2-196b-5bf22c0e76f0 -monitor unix:/var/lib/libvirt/qemu/awiki.monitor,server,nowait -boot c -drive file=/dev/vg0/awiki-root,if=virtio,index=0,boot=on -drive file=/dev/vg0/awiki-swap,if=virtio,index=1 -drive file=/mnt/boris/data/pub/diskimage/debian-503-amd64-netinst.iso,if=ide,media=cdrom,index=2,format= -net nic,macaddr=52:54:00:35:8b:fb,vlan=0,model=virtio,name=virtio.0 -net tap,fd=19,vlan=0,name=tap.0 -serial pty -parallel none -usb -vnc 127.0.0.1:2 -k en-us -vga vmware
root     13953  0.2  1.3 450332 54832 ?        Sl    2009 167:25 /usr/bin/kvm -S -M pc -m 128 -smp 1 -name nginx -uuid 793160c1-5800-72cf-7b66-8484f931d396 -monitor unix:/var/lib/libvirt/qemu/nginx.monitor,server,nowait -boot c -drive file=/dev/vg0/nginx,if=virtio,index=0,boot=on -net nic,macaddr=52:54:00:06:49:d5,vlan=0,model=virtio,name=virtio.0 -net tap,fd=21,vlan=0,name=tap.0 -serial pty -parallel none -usb -vnc 127.0.0.1:3 -k en-us -vga vmware
root     14051 31.4  6.7 441964 273132 ?       Rl   01:19  30:35 /usr/bin/kvm -S -M pc -m 256 -smp 1 -name pfsense -uuid 0af4dfac-70f1-c348-9ce5-0df18e9bdc2c -monitor unix:/var/lib/libvirt/qemu/pfsense.monitor,server,nowait -boot c -drive file=/dev/vg0/pfsense,if=ide,index=0,boot=on -net nic,macaddr=00:19:5b:86:3e:fb,vlan=0,model=e1000,name=e1000.0 -net tap,fd=22,vlan=0,name=tap.0 -net nic,macaddr=52:54:00:53:62:b9,vlan=1,model=e1000,name=e1000.1 -net tap,fd=28,vlan=1,name=tap.1 -serial pty -parallel none -usb -vnc 0.0.0.0:0 -k en-us -vga vmware
root     15528 19.7  6.6 440736 270484 ?       Sl   01:37  15:38 /usr/bin/kvm -S -M pc -m 256 -smp 1 -name pfsense2 -uuid 2c4000a0-7565-b12d-1e2a-1e77cdb778d3 -monitor unix:/var/lib/libvirt/qemu/pfsense2.monitor,server,nowait -boot c -drive file=/dev/vg0/pfsense2,if=ide,index=0,boot=on -drive file=/mnt/boris/data/pub/diskimage/pfSense-1.2.2-LiveCD-Installer.iso,if=ide,media=cdrom,index=2,format= -net nic,macaddr=52:54:00:38:fc:a7,vlan=0,model=e1000,name=e1000.0 -net tap,fd=28,vlan=0,name=tap.0 -net nic,macaddr=00:24:1d:18:f8:f6,vlan=1,model=e1000,name=e1000.1 -net tap,fd=29,vlan=1,name=tap.1 -serial pty -parallel none -usb -vnc 127.0.0.1:1 -k en-us -vga vmware
root     27079  0.9  0.7 845700 30768 ?        SLl   2009 584:28 /usr/bin/kvm -S -M pc -m 512 -smp 1 -name asterisk -uuid a87d8fc1-ea90-0db4-d6fe-c04e8f2175e7 -monitor unix:/var/lib/libvirt/qemu/asterisk.monitor,server,nowait -boot c -drive file=/dev/vg0/asterisk,if=virtio,index=0,boot=on -net nic,macaddr=52:54:00:68:db:fc,vlan=0,model=virtio,name=virtio.0 -net tap,fd=23,vlan=0,name=tap.0 -serial pty -parallel none -usb -vnc 127.0.0.1:5 -k en-us -vga vmware -soundhw es1370
root     31214  0.6  2.9 465804 121476 ?       Sl    2009 207:08 /usr/bin/kvm -S -M pc -m 256 -smp 1 -name svn -uuid 6e30e0be-1781-7a68-fa5d-d3c69787e705 -monitor unix:/var/lib/libvirt/qemu/svn.monitor,server,nowait -boot c -drive file=/dev/vg0/svn-root,if=virtio,index=0,boot=on -net nic,macaddr=52:54:00:7d:f4:0b,vlan=0,model=virtio,name=virtio.0 -net tap,fd=27,vlan=0,name=tap.0 -serial pty -parallel none -usb -vnc 0.0.0.0:4 -k en-us -vga vmware

several of these vms are actually assigned less memory than is stated in -m,
since I used the virt-manager interface to shrink memory size. awiki is set to
256MB, yet is still somehow using over 800MB of virt? one of the "anon" maps
in pmap shows up as nearly 512MB (544788K). The rest of the vms show oddities
like that as well.

host is debian sid with the 2.6.31-2-amd64 kernel, kvm --version reports:

QEMU PC emulator version 0.10.50 (qemu-kvm-devel-88)

and just for kicks:

root@boris:~# free -m
             total       used       free     shared    buffers     cached
Mem:          3964       3891         72          0        108       1686
-/+ buffers/cache:       2096       1867
Swap:         7627        383       7244

-- 
Thomas Fjellstrom
tfjellstrom@shaw.ca

  parent reply	other threads:[~2010-01-03 10:08 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-27 15:51 Memory usage with qemu-kvm-0.12.1.1 Daniel Bareiro
2009-12-27 16:03 ` Avi Kivity
2009-12-27 16:32   ` Rik van Riel
2009-12-27 16:38     ` Avi Kivity
2009-12-27 16:45       ` Rik van Riel
2009-12-27 17:12         ` Avi Kivity
2009-12-27 17:21           ` Rik van Riel
2009-12-30 18:14             ` Hugh Dickins
2009-12-31 15:05               ` Daniel Bareiro
2009-12-31 17:02                 ` Hugh Dickins
2009-12-31 18:36                   ` Rik van Riel
2010-01-03  6:20                     ` Avi Kivity
2010-01-01 16:59                   ` Daniel Bareiro
2009-12-27 17:00   ` Daniel Bareiro
2009-12-27 17:20     ` Avi Kivity
2009-12-27 17:33       ` Avi Kivity
2009-12-27 18:07         ` Daniel Bareiro
2010-01-03 10:08       ` Thomas Fjellstrom [this message]
2010-01-04 15:12         ` Thomas Fjellstrom
2010-01-04 17:18           ` David S. Ahern
2010-01-24  7:43           ` Avi Kivity
2009-12-29  0:49   ` Daniel Bareiro

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201001030308.42862.tfjellstrom@shaw.ca \
    --to=tfjellstrom@shaw.ca \
    --cc=kvm@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox