weizhouapache commented on issue #8704: URL: https://github.com/apache/cloudstack/issues/8704#issuecomment-2034750892
> @weizhouapache > > the issue is still present > > Steps followed > > 1. Create a KVM external environment > > Launch a centos 7 vm and install the following packages > > ``` > yum install qemu-kvm libvirt libvirt-python libguestfs-tools virt-install > > Systemctl enable libvirtd > > systemctl start libvirtd > ``` > > 2. Edit the /etc/libvirtd/libvirtd.conf > > ``` > > listen_tls = 0 > listen_tcp = 1 > tcp_port = "16509" > auth_tcp = "none" > mdns_adv = 0 > > key_file="/etc/pki/libvirt/private/serverkey.pem" > > cert_file="/etc/pki/libvirt/servercert.pem" > > ca_file="/etc/pki/CA/cacert.pem" > ``` > > 3. Edit the /etc/sysconfig/libvirtd > > ``` > `LIBVIRTD_ARGS="--listen"' ` > ``` > > 4. Launch a vm with the following command > > `virt-install --virt-type=kvm --name centos8 --vcpus 2 --ram 2048 --os-variant=rhel8.0 --cdrom=/var/lib/libvirt/images/centos8.iso --network=default --disk size=16` > > 5. Shutdown the vm > > `virsh shutdown <name > ` Agent Logs > > ``` > > 2024-02-26 10:08:04,738 DEBUG [cloud.agent.Agent] (agentRequest-Handler-5:null) (logid:da44af16) Processing command: com.cloud.agent.api.GetRemoteVmsCommand > 2024-02-26 10:08:04,739 DEBUG [kvm.resource.LibvirtConnection] (agentRequest-Handler-5:null) (logid:da44af16) Looking for libvirtd connection at: qemu+tcp://10.0.32.71/system > 2024-02-26 10:08:04,745 DEBUG [resource.wrapper.LibvirtGetRemoteVmsCommandWrapper] (agentRequest-Handler-5:null) (logid:da44af16) VM testkiran: powerstate = VIR_DOMAIN_SHUTOFF; vm state=PowerOff > 2024-02-26 10:08:04,749 DEBUG [resource.wrapper.LibvirtGetRemoteVmsCommandWrapper] (agentRequest-Handler-5:null) (logid:da44af16) Unable to retrieve unmanaged instance info. > java.lang.NullPointerException > at com.cloud.hypervisor.kvm.resource.LibvirtDomainXMLParser.getTagValue(LibvirtDomainXMLParser.java:431) > at com.cloud.hypervisor.kvm.resource.LibvirtDomainXMLParser.extractCpuModeDef(LibvirtDomainXMLParser.java:518) > at com.cloud.hypervisor.kvm.resource.LibvirtDomainXMLParser.parseDomainXML(LibvirtDomainXMLParser.java:390) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetRemoteVmsCommandWrapper.getUnmanagedInstance(LibvirtGetRemoteVmsCommandWrapper.java:90) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetRemoteVmsCommandWrapper.execute(LibvirtGetRemoteVmsCommandWrapper.java:71) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetRemoteVmsCommandWrapper.execute(LibvirtGetRemoteVmsCommandWrapper.java:46) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtRequestWrapper.execute(LibvirtRequestWrapper.java:78) > at com.cloud.hypervisor.kvm.resource.LibvirtComputingResource.executeRequest(LibvirtComputingResource.java:1903) > at com.cloud.agent.Agent.processRequest(Agent.java:683) > at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:1106) > at com.cloud.utils.nio.Task.call(Task.java:83) > at com.cloud.utils.nio.Task.call(Task.java:29) > at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) > at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) > at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) > at java.base/java.lang.Thread.run(Thread.java:829) > 2024-02-26 10:08:04,749 ERROR [resource.wrapper.LibvirtGetRemoteVmsCommandWrapper] (agentRequest-Handler-5:null) (logid:da44af16) Error while fetching instance details > com.cloud.utils.exception.CloudRuntimeException: Unable to retrieve unmanaged instance info. null > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetRemoteVmsCommandWrapper.getUnmanagedInstance(LibvirtGetRemoteVmsCommandWrapper.java:110) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetRemoteVmsCommandWrapper.execute(LibvirtGetRemoteVmsCommandWrapper.java:71) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetRemoteVmsCommandWrapper.execute(LibvirtGetRemoteVmsCommandWrapper.java:46) > at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtRequestWrapper.execute(LibvirtRequestWrapper.java:78) > at com.cloud.hypervisor.kvm.resource.LibvirtComputingResource.executeRequest(LibvirtComputingResource.java:1903) > at com.cloud.agent.Agent.processRequest(Agent.java:683) > at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:1106) > at com.cloud.utils.nio.Task.call(Task.java:83) > at com.cloud.utils.nio.Task.call(Task.java:29) > at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) > at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) > at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) > at java.base/java.lang.Thread.run(Thread.java:829) > ``` @kiranchavala can you test with latest 4.19 or main ? the vm import issue should be fixed by #8720 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@cloudstack.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org