Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
What about every 15seconds if no progress has happened? How would you define progress? I would then start at 0.15s downtime as default or at custom conf value if defined. If no progress happens I would double the value. Stefan Am 30.12.2012 um 06:55 schrieb Dietmar Maurer diet...@proxmox.com: i really like that idea instead of having a fixed downtime of 1s. What is about starting at 0.5s and then add 0.5s every 15 runs? Yes, we can do that, but may Every 15 runs if we make no progress? ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] qemu-server: add support for unsecure migration (setting in datacenter.cfg)
Am 30.12.2012 um 06:51 schrieb Dietmar Maurer diet...@proxmox.com: i wasn't able to find more information about the speed of ssh influenced by aes-ni. I'm not sure that it will result in so much speed. The Problem isn't the encryption it is at a specific point the buffer handling in ssh. Which uses HARDCODED pretty small buffers. But that should be fixable? Sure here patches http://www.psc.edu/index.php/hpn-ssh but nobody at openssh wants to implement them. So the only solution will be a direct tcp connection. No chance to get the patches included? I would really like to get ssh fixed instead - that would help a lot more people. Would be great but then proxmox need to maintain a custom ssh version. Stefan___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
What about every 15seconds if no progress has happened? How would you define progress? Maybe we can check if remaining memory goes up and down. (So it could also works with qemu 1.4 as we dont have expected_downtime value) (if remaining memory last remaing memory){ counter++ } if(counter == 15){ set_migrate_downtime = migratedowntime + 0.X sec counter = 0; } - Mail original - De: Stefan Priebe - Profihost AG s.pri...@profihost.ag À: Dietmar Maurer diet...@proxmox.com Cc: Alexandre Derumier aderum...@odiso.com, pve-devel@pve.proxmox.com Envoyé: Dimanche 30 Décembre 2012 09:33:09 Objet: Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0 What about every 15seconds if no progress has happened? How would you define progress? I would then start at 0.15s downtime as default or at custom conf value if defined. If no progress happens I would double the value. Stefan Am 30.12.2012 um 06:55 schrieb Dietmar Maurer diet...@proxmox.com: i really like that idea instead of having a fixed downtime of 1s. What is about starting at 0.5s and then add 0.5s every 15 runs? Yes, we can do that, but may Every 15 runs if we make no progress? ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
Hi, attached a patch. Greets, Stefan Am 30.12.2012 09:39, schrieb Alexandre DERUMIER: What about every 15seconds if no progress has happened? How would you define progress? Maybe we can check if remaining memory goes up and down. (So it could also works with qemu 1.4 as we dont have expected_downtime value) (if remaining memory last remaing memory){ counter++ } if(counter == 15){ set_migrate_downtime = migratedowntime + 0.X sec counter = 0; } - Mail original - De: Stefan Priebe - Profihost AG s.pri...@profihost.ag À: Dietmar Maurer diet...@proxmox.com Cc: Alexandre Derumier aderum...@odiso.com, pve-devel@pve.proxmox.com Envoyé: Dimanche 30 Décembre 2012 09:33:09 Objet: Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0 What about every 15seconds if no progress has happened? How would you define progress? I would then start at 0.15s downtime as default or at custom conf value if defined. If no progress happens I would double the value. Stefan Am 30.12.2012 um 06:55 schrieb Dietmar Maurer diet...@proxmox.com: i really like that idea instead of having a fixed downtime of 1s. What is about starting at 0.5s and then add 0.5s every 15 runs? Yes, we can do that, but may Every 15 runs if we make no progress? From a1dd1fb3aad3317a5d571688e1bf6726338232d4 Mon Sep 17 00:00:00 2001 From: Stefan Priebe s.pri...@profihost.ag Date: Sat, 29 Dec 2012 20:23:23 +0100 Subject: [PATCH] implement dynamic migration_downtime --- PVE/QemuMigrate.pm | 21 +++-- PVE/QemuServer.pm |4 ++-- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/PVE/QemuMigrate.pm b/PVE/QemuMigrate.pm index ab01fa0..f290975 100644 --- a/PVE/QemuMigrate.pm +++ b/PVE/QemuMigrate.pm @@ -348,9 +348,9 @@ sub phase2 { my $migrate_downtime = $defaults-{migrate_downtime}; $migrate_downtime = $conf-{migrate_downtime} if defined($conf-{migrate_downtime}); if (defined($migrate_downtime)) { - $self-log('info', migrate_set_downtime: $migrate_downtime); + $self-log('info', migrate_set_downtime: .$migrate_downtime); eval { - PVE::QemuServer::vm_mon_cmd_nocheck($vmid, migrate_set_downtime, value = int($migrate_downtime)); + PVE::QemuServer::vm_mon_cmd_nocheck($vmid, migrate_set_downtime, value = int($migrate_downtime*100)/100); }; $self-log('info', migrate_set_downtime error: $@) if $@; } @@ -379,6 +379,8 @@ sub phase2 { my $usleep = 200; my $i = 0; my $err_count = 0; +my $migration_lastremaining = 0; +my $migrate_downtimecounter = 0; while (1) { $i++; my $avglstat = $lstat/$i if $lstat; @@ -437,6 +439,21 @@ sub phase2 { #$self-log('info', migration xbzrle cachesize: ${xbzrlecachesize} transferred ${xbzrlebytes} pages ${xbzrlepages} cachemiss ${xbzrlecachemiss} overflow ${xbzrleoverflow}); } +if ($stat-{ram}-{remaining} $stat-{ram}-{remaining} $migration_lastremaining) { + $migration_lastremaining = $stat-{ram}-{remaining}; + $migrate_downtimecounter++; + } +if ($migrate_downtimecounter 5) { + $migrate_downtimecounter = 0; +$migrate_downtime *= 2; + $self-log('info', migrate_set_downtime: $migrate_downtime); + eval { + PVE::QemuServer::vm_mon_cmd_nocheck($vmid, migrate_set_downtime, value = int($migrate_downtime*100)/100); + }; + $self-log('info', migrate_set_downtime error: $@) if $@; + $migrate_downtimecounter = time(); +} + $lstat = $stat-{ram}-{transferred}; } else { diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index 93d0300..524a15c 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -382,10 +382,10 @@ EODESCR }, migrate_downtime = { optional = 1, - type = 'integer', + type = 'number', description = Set maximum tolerated downtime (in seconds) for migrations., minimum = 0, - default = 1, + default = 0.1, }, cdrom = { optional = 1, -- 1.7.10.4 ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH 3/3] add downtime expected_downtime query-migrate info
Hi Alexandre, attached you'll find a patchset with 10 more patches which make migration even more faster. They're stable for me too. Greets, Stefan Am 29.12.2012 15:54, schrieb Stefan Priebe - Profihost AG: Great! To me even xzbrle works fine now. Am 29.12.2012 um 15:47 schrieb Alexandre DERUMIER aderum...@odiso.com: I have just done some little tests with qemu 1.3 + migration patches set, now it's working fine, no more crash ! (playing video hd). setting migrate_set_downtime to 1sec, give me: for no memory activity : 36ms downtime for high memory activity : 650ms downtime I'll do more extensive tests monday. Thanks for the patches ! - Mail original - De: Stefan Priebe s.pri...@profihost.ag À: Alexandre DERUMIER aderum...@odiso.com Cc: pve-devel@pve.proxmox.com, Dietmar Maurer diet...@proxmox.com Envoyé: Samedi 29 Décembre 2012 15:07:30 Objet: Re: [pve-devel] [PATCH 3/3] add downtime expected_downtime query-migrate info Hi, Am 29.12.2012 15:02, schrieb Alexandre DERUMIER: oh, ok. I'll tests the patchs mondays. Thanks! Does migration works fine for you with them ? Yes - it works fine / perfectly. But i've no VM with a desktop to play HD videos ;-) Stefan - Mail original - De: Stefan Priebe s.pri...@profihost.ag À: Alexandre DERUMIER aderum...@odiso.com Cc: pve-devel@pve.proxmox.com, Dietmar Maurer diet...@proxmox.com Envoyé: Samedi 29 Décembre 2012 14:55:33 Objet: Re: [pve-devel] [PATCH 3/3] add downtime expected_downtime query-migrate info Hi Alexandre, Am 29.12.2012 14:51, schrieb Alexandre DERUMIER: Great to known that you finally found it !. Not found ;-) just know that the rework of the migration code fixes it. May be it might be a deadlock - they've changed the locking and threading handling. (Do you have respond to Paolo Bonzini, because the last response I see was that it was not working). No - i just tried to apply parts of the patchset on qemu 1.3 instead of using whole 1.4 git trunk. Alexandre might you try my rebased patches on top of pve-qemu 1.3? So, Do you want to apply the first patch only (to fix you bug), or apply the whole patches set ? (equal to current git code ?). All patches i had attached ;-) Not sure that Dietmar want to apply the big patches set ;) sure but just wanted to know if they're stable for you too. So if they're i will care about them in my own branch. So I've at least a working migration. I'll retest the whole patches set, because I was having migration problem (vm paused with error) with last qemu git. That's why i've ported not all patches and on top of qemu 1.3 instead of qemu 1.4. Stefan ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel qemu-migration-full.tar.gz Description: application/gzip ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
[pve-devel] qemu-img convert bug?
Hi all, When using qemu-img convert the resulting image seems to grow! Anybody seen this too? root@esx2:~# time qemu-img convert -t writeback -p -O qcow2 /mnt/pve/qnap_nfs/images/106/vm-106-disk-1.qcow2 /var/lib/vz/images/106/vm-106-disk-1.qcow2 (100.00/100%) real6m8.103s user0m3.410s sys 0m36.071s root@esx2:~# qemu-img info /var/lib/vz/images/106/vm-106-disk-1.qcow2 image: /var/lib/vz/images/106/vm-106-disk-1.qcow2 file format: qcow2 virtual size: 16G (17179869184 bytes) disk size: 7.2G cluster_size: 65536 root@esx2:~# qemu-img info /mnt/pve/qnap_nfs/images/106/vm-106-disk-1.qcow2image: /mnt/pve/qnap_nfs/images/106/vm-106-disk-1.qcow2 file format: qcow2 virtual size: 16G (17179869184 bytes) disk size: 7.3G cluster_size: 65536 -- Hilsen/Regards Michael Rasmussen Get my public GnuPG keys: michael at rasmussen dot cc http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0xD3C9A00E mir at datanom dot net http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0xE501F51C mir at miras dot org http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0xE3E80917 -- System going down at 1:45 this afternoon for disk crashing. signature.asc Description: PGP signature ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
I'm testing your patch. remaning memory can also stay at 0 at the end (with last qemu git migration patch), so we need to also check that. also in your patch, what is + $migrate_downtimecounter = time(); ? - Mail original - De: Stefan Priebe s.pri...@profihost.ag À: Alexandre DERUMIER aderum...@odiso.com Cc: pve-devel@pve.proxmox.com, Dietmar Maurer diet...@proxmox.com Envoyé: Dimanche 30 Décembre 2012 13:25:40 Objet: Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0 Hi, attached a patch. Greets, Stefan Am 30.12.2012 09:39, schrieb Alexandre DERUMIER: What about every 15seconds if no progress has happened? How would you define progress? Maybe we can check if remaining memory goes up and down. (So it could also works with qemu 1.4 as we dont have expected_downtime value) (if remaining memory last remaing memory){ counter++ } if(counter == 15){ set_migrate_downtime = migratedowntime + 0.X sec counter = 0; } - Mail original - De: Stefan Priebe - Profihost AG s.pri...@profihost.ag À: Dietmar Maurer diet...@proxmox.com Cc: Alexandre Derumier aderum...@odiso.com, pve-devel@pve.proxmox.com Envoyé: Dimanche 30 Décembre 2012 09:33:09 Objet: Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0 What about every 15seconds if no progress has happened? How would you define progress? I would then start at 0.15s downtime as default or at custom conf value if defined. If no progress happens I would double the value. Stefan Am 30.12.2012 um 06:55 schrieb Dietmar Maurer diet...@proxmox.com: i really like that idea instead of having a fixed downtime of 1s. What is about starting at 0.5s and then add 0.5s every 15 runs? Yes, we can do that, but may Every 15 runs if we make no progress? ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
[pve-devel] [PATCH 2/2] add set migrate_downtime default value to 0.1 add number type
can be integer or float ex: 1 1.0 0.3 Signed-off-by: Alexandre Derumier aderum...@odiso.com --- PVE/QemuServer.pm |7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index 10865ad..5c39728 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -382,10 +382,10 @@ EODESCR }, migrate_downtime = { optional = 1, - type = 'integer', + type = 'number', description = Set maximum tolerated downtime (in seconds) for migrations., minimum = 0, - default = 1, + default = 0.1, }, cdrom = { optional = 1, @@ -1441,6 +1441,9 @@ sub check_type { } elsif ($type eq 'integer') { return int($1) if $value =~ m/^(\d+)$/; die type check ('integer') failed - got '$value'\n; +} elsif ($type eq 'number') { +return $value if $value =~ m/^(\d+)(\.\d+)?$/; +die type check ('number') failed - got '$value'\n; } elsif ($type eq 'string') { if (my $fmt = $confdesc-{$key}-{format}) { if ($fmt eq 'pve-qm-drive') { -- 1.7.10.4 ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] implement dynamic migration_downtime V2
Just got patch 2/2 missing 1/2? Stefan Am 30.12.2012 um 19:02 schrieb Alexandre Derumier aderum...@odiso.com: I have rework the patch of stefan. (and split it in 2 parts) I have tested it with qemu 1.3 migration code qemu git migration code, both works fine. ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
[pve-devel] qemu-img convert bug, one more example
time qemu-img convert -t writeback -p -O raw /dev/qnap_vg/vm-117-disk-1 /var/lib/vz/images/117/vm-117-disk-1.raw (100.00/100%) real1m39.023s user0m0.814s sys 0m10.076s root@esx2:~# qemu-img info /var/lib/vz/images/117/vm-117-disk-1.raw image: /var/lib/vz/images/117/vm-117-disk-1.raw file format: raw virtual size: 4.0G (4294967296 bytes) disk size: 2.2G root@esx2:~# qemu-img info /dev/qnap_vg/vm-117-disk-1 image: /dev/qnap_vg/vm-117-disk-1 file format: raw virtual size: 4.0G (4294967296 bytes) disk size: 0 Original disk: disk size: 0 New disk: disk size: 2.2G What is going on? -- Hilsen/Regards Michael Rasmussen Get my public GnuPG keys: michael at rasmussen dot cc http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0xD3C9A00E mir at datanom dot net http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0xE501F51C mir at miras dot org http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0xE3E80917 -- I must Create a System, or be enslav'd by another Man's; I will not Reason and Compare; my business is to Create. -- William Blake, Jerusalem signature.asc Description: PGP signature ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH 3/3] add downtime expected_downtime query-migrate info
Hi, Am 30.12.2012 16:29, schrieb Alexandre DERUMIER: Seem stable here too, thanks ! great! Willd definitely keep them in my branch. Migration is now as fast and as stable i originally expected from kvm. Dietmar are you interested too / have you thought about implement them into pve-qemu-kvm? Greets Stefan ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
Hi, Am 30.12.2012 16:31, schrieb Alexandre DERUMIER: I'm testing your patch. remaning memory can also stay at 0 at the end (with last qemu git migration patch), so we need to also check that. OK - will wait for your patch. Still missing part1. also in your patch, what is + $migrate_downtimecounter = time(); ? Oops - a left over of an old idea. Stefan ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
attached a patch. I think a fast round should clear the counter? ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
Re: [pve-devel] [PATCH] increase migrate_set_downtime only if expected downtime is more than 30 iterations 0
Am 31.12.2012 um 06:00 schrieb Dietmar Maurer diet...@proxmox.com: attached a patch. I think a fast round should clear the counter? But this would raise the chance to have a constant up and down. I could imagine lowering the counter by just 0.5 could prevent that. Stefan ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel