[pve-devel] [PATCH] balloon: use qom-get for guest balloon statistics V4

2015-03-05 Thread Alexandre Derumier
changelog: qom-get return values are $info->{stats}->{"stat-total-memory"}; $info->{stats}->{"stat-free-memory"}; and not $info->{"stat-total-memory"}; $info->{"stat-free-memory"}; Signed-off-by: Alexandre Derumier --- PVE/QemuServer.pm | 21 +++-- 1 file changed, 11 insert

Re: [pve-devel] [IB#1034892] Guest disk data security

2015-03-05 Thread Dietmar Maurer
applied, thanks! ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

[pve-devel] qemu-server : balloon: use qom-get for guest balloon statistics V3

2015-03-05 Thread Alexandre Derumier
changelog: only use qom-get, no need to call qmp query-balloon query-ballon "actual" = qom-get "stat-total-memory" query-ballon "maxmem" = config memory value (with pending, the value is accurate now) (I'll try to autoballoning today) ___ pve-devel

[pve-devel] [PATCH] balloon: use qom-get for guest balloon statistics V3

2015-03-05 Thread Alexandre Derumier
Signed-off-by: Alexandre Derumier --- PVE/QemuServer.pm | 21 +++-- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index bb7a7f3..c884854 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -2490,17 +2490,12 @@ sub vm

[pve-devel] [PATCH_V4] Bug Fix 602

2015-03-05 Thread Wolfgang Link
now zfs will wait 5 sec if error msg is "dataset is busy" Signed-off-by: Wolfgang Link --- PVE/Storage/ZFSPoolPlugin.pm | 18 -- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/PVE/Storage/ZFSPoolPlugin.pm b/PVE/Storage/ZFSPoolPlugin.pm index 5cbd1b2..d8721a4 100

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
>>This can be retrieve too with qom : stat-total-memory >>so,only "actual" balloon value need to an extra qmp query. Oops, sorry, this is wrong. qom "stat-total-memory" = qmp "actual" I need to rebase my patch for a v3 - Mail original - De: "aderumier" À: "dietmar" Cc: "pve-devel

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
>>only max_mem is missing from orignal qmp query-balloon or qom-get. >>No sure we need to keep a patch just for this. We can use vmid.conf value. >>(with pending, now we also have true value) This can be retrieve too with qom : stat-total-memory so,only "actual" balloon value need to an extr

[pve-devel] [PATCH] balloon: use qom-get for guest balloon statistics V2

2015-03-05 Thread Alexandre Derumier
Signed-off-by: Alexandre Derumier --- PVE/QemuServer.pm | 30 -- 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index bb7a7f3..01f671d 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -2486,22 +2486,37 @

[pve-devel] qemu-server : balloon: use qom-get for guest balloon statistics V2

2015-03-05 Thread Alexandre Derumier
changelog: qom values return are stat-free-memory && stats-total-memory, not free_mem && total_mem ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
>> Maybe it's time to remove this patch, and use qemu qom implementation ? >> >>Would be great, but current code needs 'actual, max_mem'? just send a patch. the actual value is return by original query-balloon. only max_mem is missing from orignal qmp query-balloon or qom-get. No sure we need to

[pve-devel] qemu-server: balloon: use qom-get for guest balloon statistics

2015-03-05 Thread Alexandre Derumier
This patch use qom-get to retrieve guest balloon statisctics, instead to use the proxmox query-balloon patch, which seem to not work anymore when the vm is started with -machine option. I don't have tested it too much, so help is welcome for testing _

[pve-devel] [PATCH] balloon: use qom-get for guest balloon statistics

2015-03-05 Thread Alexandre Derumier
Signed-off-by: Alexandre Derumier --- PVE/QemuServer.pm | 30 -- 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index bb7a7f3..2bb907c 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -2486,22 +2486,37 @

Re: [pve-devel] [PATCH_V3] Bug Fix 602

2015-03-05 Thread Dietmar Maurer
On 03/06/2015 05:57 AM, Dietmar Maurer wrote: So this regex will never match! oh, just saw that the colon is added inside run_command - so just ignore this. + + if ($ret =~ m/.*: dataset is busy.*/){ + + for(my $i = 0; $ret && $i < 5; $i++){ + sleep(1); +

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Dietmar Maurer
> As far I remember, we have make the virtio-balloon-fix-query.patch patch, > because at this time, it was impossible to use qom guest-stats to retrieve all > values in 1 call > (And we wanted to avoid to call 5-6 times qom guest-stats) yes, we use that inside QemuServer::vmstatus, so that needs t

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Dietmar Maurer
> On March 6, 2015 at 5:26 AM Alexandre DERUMIER wrote: > > > Seem to be a proxmox bug finally (or maybe proxmox use a path not used anymore > by qemu), > > using qom balloon guest-stats (with the guest is started with -machine ..) Maybe you can try to find out what we do differently? ___

Re: [pve-devel] [PATCH_V3] Bug Fix 602

2015-03-05 Thread Dietmar Maurer
> -run_command($cmd, outfunc => $output, timeout => $timeout); > +run_command($cmd, errmsg => "ERROR", outfunc => $output, timeout => > $timeout); Note: you use "ERROR" here - without collon. > > return $msg; > } > @@ -291,7 +291,26 @@ sub zfs_create_zvol { > sub zfs_delete_zvol

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
@Dietmar: As far I remember, we have make the virtio-balloon-fix-query.patch patch, because at this time, it was impossible to use qom guest-stats to retrieve all values in 1 call (And we wanted to avoid to call 5-6 times qom guest-stats) Now,it seem that we can get all values directly. (excl

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
Seem to be a proxmox bug finally (or maybe proxmox use a path not used anymore by qemu), using qom balloon guest-stats (with the guest is started with -machine ..) my $stats = vm_mon_cmd_nocheck($vmid, 'qom-get', path => "machine/peripheral/balloon0",

[pve-devel] [PATCH_V3] Bug Fix 602

2015-03-05 Thread Wolfgang Link
now zfs will wait 5 sec if error msg is "dataset is busy" Signed-off-by: Wolfgang Link --- PVE/Storage/ZFSPoolPlugin.pm | 23 +-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/PVE/Storage/ZFSPoolPlugin.pm b/PVE/Storage/ZFSPoolPlugin.pm index 5cbd1b2..999e43

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
maybe this commit http://git.qemu.org/?p=qemu.git;a=commit;h=91ba21208839643603e7f7fa5864723c3f371ebe http://lists.nongnu.org/archive/html/qemu-devel/2014-09/msg05176.html virtio-balloon: fix virtio-balloon child refcount in transports diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
Thanks Michael That's seem to confirm that the problem come from the "-machine " option. I'm currently digging inside qemu code to find what does it change. - Mail original - De: "datanom.net" À: "pve-devel" Envoyé: Jeudi 5 Mars 2015 17:30:00 Objet: Re: [pve-devel] balloon bug in qemu

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Michael Rasmussen
On Thu, 5 Mar 2015 16:44:05 +0100 (CET) Alexandre DERUMIER wrote: > Note that balloon itself is working > > # info balloon > balloon: actual=1024 max_mem=1024 > > # balloon 512 > > # info balloon > balloon: actual=512 max_mem=1024 > > Before migration: # info version 2.1.3 # info balloon ba

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
Note that balloon itself is working # info balloon balloon: actual=1024 max_mem=1024 # balloon 512 # info balloon balloon: actual=512 max_mem=1024 - Mail original - De: "aderumier" À: "Andrew Thrift" Cc: "pve-devel" Envoyé: Jeudi 5 Mars 2015 16:17:49 Objet: Re: [pve-devel] balloon

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
ok,I speak too fast. It's not related to this patch. on current pve-qemu-kvm 2.1. balloon is working fine # info balloon balloon: actual=1024 max_mem=1024 total_mem=1002 free_mem=941 mem_swapped_in=0 mem_swapped_out=0 major_page_faults=120 minor_page_faults=215272 last_update=1425568324 But

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
I need to do more tests, but it seem that this commit (applied on qemu 2.2 but not on qemu 2.1) http://git.qemu.org/?p=qemu.git;a=commit;h=22644cd2c60151a964d9505f4c5f7baf845f20d8 fix the problem with qemu 2.1. (I have tested with the patch, balloon works fine, I need to test without the patch t

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
in proxmox virtio-balloon-fix-query.patch, we have hw/virtio/virtio-balloon.c + +if (!(balloon_stats_enabled(dev) && balloon_stats_supported(dev) && + dev->stats_last_update)) { + return; +} + +info->last_update = dev->stats_last_update; +info->has_last_update = t

Re: [pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Andrew Thrift
Hi Alexandre, This may be the cause of the crashes we have been experiencing.We reported them here: http://forum.proxmox.com/threads/21276-Kernel-Oops-Panic-on-3-10-5-and-3-10-7-Kernels These only started happening since we moved to qemu-2.1.x and we get the same output: # info balloon ball

Re: [pve-devel] [PATVH_V2] Bug Fix 602

2015-03-05 Thread Dietmar Maurer
On 03/05/2015 02:13 PM, Dietmar Maurer wrote: $msg .= "$line\n"; }; -run_command($cmd, outfunc => $output, timeout => $timeout); +if ($method eq "destroy") { + +eval {run_command($cmd, errmsg => 1, outfunc => $output, timeout => $timeout);}; + +if(my $err = $@) { +

Re: [pve-devel] [PATVH_V2] Bug Fix 602

2015-03-05 Thread Dietmar Maurer
On 03/03/2015 01:17 PM, Wolfgang Link wrote: now zfs will wait 5 sec if error msg is "dataset is busy" Signed-off-by: Wolfgang Link --- PVE/Storage/ZFSPoolPlugin.pm | 28 ++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/PVE/Storage/ZFSPoolPlugin.p

Re: [pve-devel] [PATCH] drive_add : escape \ character

2015-03-05 Thread Dietmar Maurer
applied both patches, thanks! ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

[pve-devel] balloon bug in qemu 2.1 ?

2015-03-05 Thread Alexandre DERUMIER
Hi, I have see a bug report here: http://forum.proxmox.com/threads/2-RAM-Problem-since-Upgrade-to-3-4?p=108367&posted=1#post108367 about balloon. on my qemu 2.2 #info balloon balloon: actual=1024 max_mem=2048 total_mem=985 free_mem=895 mem_swapped_in=0 mem_swapped_out=0 major_page_faults=

[pve-devel] [PATCH] drive_add : escape \ character

2015-03-05 Thread Alexandre Derumier
storage.cfg --- rbd mystorage monhost 10.5.0.11:6789; 10.5.0.12:6789; 10.5.0.13:6789 drive_add auto "file=rbd:poolceph1/vm-101-disk-8:mon_host=10.5.0.11\\:6789; 10.5.0.12\\:6789; 10.5.0.13\\:6789:id=admin:auth_supported=cephx:keyring=/etc/pve/priv/ceph/cephzimbra.keyring,if=none,id=d

[pve-devel] [PATCH] rbd: monhost string : escape only ":" character

2015-03-05 Thread Alexandre Derumier
we need to escape ":" used to defined mon ports "10.5.0.11:6789; 10.5.0.12:6789; 10.5.0.13:6789" -> "10.5.0.11\:6789; 10.5.0.12\:6789; 10.5.0.13\:6789" Signed-off-by: Alexandre Derumier --- PVE/Storage/RBDPlugin.pm | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --gi

Re: [pve-devel] [PATCH] qmp drive_add : remove backslashes from $drive string

2015-03-05 Thread Alexandre DERUMIER
>>Ok,I think we can do it like this. >>I think that only qemu command line need this, but I'll do tests to be sure. I have checked, it's not so easy. I think we should keep the addslashes in rbdplugin if you have a storage.cfg with monhost with spaces and ports monhost 10.5.0.11:6789; 10.5.0

Re: [pve-devel] Host freeze exaclty after 00:00h

2015-03-05 Thread Eneko Lacunza
Hi Detlef, I have seen problems similar to this previously, but only on test clusters. What version of packages? My diagnose was that there was some process gone crazy that affected all the node. I don't think I had CTs there. Did you have VMs running? On 05/03/15 07:55, Detlef Bracker wrot

Re: [pve-devel] Host freeze exaclty after 00:00h

2015-03-05 Thread Detlef Bracker
Oh, I means I have found from where this was comming! I had before on one container a hacker and I have down this container (blocking customer) and I have forgot to set the onboot=no and yesterday I have restart the host, but this is interessting - and 999 is only a clone from 280 for analysis and