Return-Path: X-Original-To: apmail-cloudstack-issues-archive@www.apache.org Delivered-To: apmail-cloudstack-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B56371851B for ; Thu, 28 Apr 2016 19:56:14 +0000 (UTC) Received: (qmail 73246 invoked by uid 500); 28 Apr 2016 19:56:13 -0000 Delivered-To: apmail-cloudstack-issues-archive@cloudstack.apache.org Received: (qmail 72910 invoked by uid 500); 28 Apr 2016 19:56:13 -0000 Mailing-List: contact issues-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list issues@cloudstack.apache.org Received: (qmail 72712 invoked by uid 500); 28 Apr 2016 19:56:13 -0000 Delivered-To: apmail-incubator-cloudstack-issues@incubator.apache.org Received: (qmail 72366 invoked by uid 99); 28 Apr 2016 19:56:13 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Apr 2016 19:56:13 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 1B4B72C1F6F for ; Thu, 28 Apr 2016 19:56:13 +0000 (UTC) Date: Thu, 28 Apr 2016 19:56:13 +0000 (UTC) From: "ASF subversion and git services (JIRA)" To: cloudstack-issues@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CLOUDSTACK-9142) Migrate VM changes xmlDesc in an unsafe way MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CLOUDSTACK-9142?page=3Dcom.atla= ssian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId= =3D15262837#comment-15262837 ]=20 ASF subversion and git services commented on CLOUDSTACK-9142: ------------------------------------------------------------- Commit c03e359824327b56af6b1921155d8796d2958f9c in cloudstack's branch refs= /heads/4.7 from [~williamstevens@gmail.com] [ https://git-wip-us.apache.org/repos/asf?p=3Dcloudstack.git;h=3Dc03e359 ] Merge pull request #1348 from DaanHoogland/CLOUDSTACK-9142 CLOUDSTACK-9142 Migrate VM changes xmlDesc in a safe wayThe problem arises = when the origin hypervisor has an ip addres that ends with 1, like '10.10.1= 0.1' and the qemu VM description is containing an address that has that as = part of its address, '10.10.10.100' for instance. now migrating to '10.10.10.10' will change both addresses in the xml descri= ption file for qemu. It is fixed and unit tests are added. I am not sure ye= t how to integration test this. Regression will probably work so creating a= PR now. * pr/1348: CLOUDSTACK-9142 Migrate VM changes xmlDesc in a safe way Signed-off-by: Will Stevens > Migrate VM changes xmlDesc in an unsafe way > ------------------------------------------- > > Key: CLOUDSTACK-9142 > URL: https://issues.apache.org/jira/browse/CLOUDSTACK-914= 2 > Project: CloudStack > Issue Type: Bug > Security Level: Public(Anyone can view this level - this is the defa= ult.)=20 > Components: KVM, Management Server > Affects Versions: 4.6.0, 4.7.0 > Reporter: David Amorim Faria > Assignee: Daan Hoogland > Priority: Critical > > This issue appears with commit https://github.com/apache/cloudstack/commi= t/a709f34ff93579981afbd4df0f4334b61ada29a8 > where xmlDesc has some content replaced: {code} > xmlDesc =3D dm.getXMLDesc(xmlFlag).replace(libvirtComputingResource.getPr= ivateIp(), command.getDestinationIp()); > {code} > This line from LibvirtComputingResource.java was refactored into LibvirtM= igrateCommandWrapper.java in commit https://github.com/apache/cloudstack/co= mmit/28e55462f15bdd8699e97b668c4ffc01735a533d > Example, node1 is 10.0.0.1, node2 is 10.0.0.2, rbd mon_host is 10.0.0.13. > VM is running on kvm node1 and this happened when migrating a VM from nod= e1 to node2, where the kvm nodes and the RBD mon nodes (mon_host) use IP ad= dresses in the same range, and the mon_host has an ip address that partiall= y matches the ip address (string) of the first kvm node. > In the process list one can see that the mon_host changes from 10.0.0.13 = to 10.0.0.23 in the destination host, blocking the migration after a timeou= t due to primary storage not being available. > {code} > root 25206 1.8 0.0 440184 17188 ? Sl 13:33 0:00 /usr/lib= exec/qemu-kvm -name r-74-VM -S -machine pc-i440fx-rhel7.0.0,accel=3Dkvm,usb= =3Doff -cpu host,+rdtscp,+pdpe1gb,+dca,+pcid,+pdcm,+xtpr,+tm2,+est,+smx,+vm= x,+ds_cpl,+monitor,+dtes64,+pclmuldq,+pbe,+tm,+ht,+ss,+acpi,+ds,+vme -m 256= -realtime mlock=3Doff -smp 1,sockets=3D1,cores=3D1,threads=3D1 -uuid 1a32b= 655-0acf-424b-8722-9e7f507a3070 -smbios type=3D1,manufacturer=3DApache Soft= ware Foundation,product=3DCloudStack KVM Hypervisor,uuid=3D1a32b655-0acf-42= 4b-8722-9e7f507a3070 -no-user-config -nodefaults -chardev socket,id=3Dcharm= onitor,path=3D/var/lib/libvirt/qemu/domain-r-74-VM/monitor.sock,server,nowa= it -mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol -rtc base=3Dutc -= no-shutdown -boot strict=3Don -device piix3-usb-uhci,id=3Dusb,bus=3Dpci.0,a= ddr=3D0x1.0x2 -device virtio-serial-pci,id=3Dvirtio-serial0,bus=3Dpci.0,add= r=3D0x6 -drive file=3Drbd:rbd/15ea00f9-e52e-43cf-9e5e-62188e9da5d2:id=3Dclo= udstack:key=3DXXXXXXXX=3D=3D:auth_supported=3Dcephx\;none:mon_host=3D10.0.0= .23\:6789,if=3Dnone,id=3Ddrive-virtio-disk0,format=3Draw,serial=3D15ea00f9e= 52e43cf9e5e,cache=3Dnone -device virtio-blk-pci,scsi=3Doff,bus=3Dpci.0,addr= =3D0x7,drive=3Ddrive-virtio-disk0,id=3Dvirtio-disk0,bootindex=3D2 -drive fi= le=3D/usr/share/cloudstack-common/vms/systemvm.iso,if=3Dnone,id=3Ddrive-ide= 0-1-0,readonly=3Don,format=3Draw,cache=3Dnone -device ide-cd,bus=3Dide.1,un= it=3D0,drive=3Ddrive-ide0-1-0,id=3Dide0-1-0,bootindex=3D1 -netdev tap,fd=3D= 32,id=3Dhostnet0,vhost=3Don,vhostfd=3D33 -device virtio-net-pci,netdev=3Dho= stnet0,id=3Dnet0,mac=3D11:11:11:11:11:11,bus=3Dpci.0,addr=3D0x3,rombar=3D0,= romfile=3D -netdev tap,fd=3D34,id=3Dhostnet1,vhost=3Don,vhostfd=3D35 -devic= e virtio-net-pci,netdev=3Dhostnet1,id=3Dnet1,mac=3D22:22:22:22:22:22,bus=3D= pci.0,addr=3D0x4,rombar=3D0,romfile=3D -netdev tap,fd=3D36,id=3Dhostnet2,vh= ost=3Don,vhostfd=3D37 -device virtio-net-pci,netdev=3Dhostnet2,id=3Dnet2,ma= c=3D33:33:33:33:33:33,bus=3Dpci.0,addr=3D0x5,rombar=3D0,romfile=3D -chardev= pty,id=3Dcharserial0 -device isa-serial,chardev=3Dcharserial0,id=3Dserial0= -chardev socket,id=3Dcharchannel0,path=3D/var/lib/libvirt/qemu/r-74-VM.age= nt,server,nowait -device virtserialport,bus=3Dvirtio-serial0.0,nr=3D1,chard= ev=3Dcharchannel0,id=3Dchannel0,name=3Dr-74-VM.vport -device usb-tablet,id= =3Dinput0 -vnc 10.0.0.2:4,password -vga cirrus -incoming tcp:[::]:49152 -ms= g timestamp=3Don > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)