Skip to content

Track: qemu and libvirt might out of sync #53

@yb01

Description

@yb01

the below virsh cmd tries to remove the memory device, but failed with no match found.

    <memballoon model='virtio'>
      <alias name='balloon0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </memballoon>
    **<memory model='dimm'>
      <target>
        <size unit='KiB'>524288</size>
        <node>0</node>
      </target>
      <alias name='dimm0'/>
      <address type='dimm' slot='0' base='0x140000000'/>
    </memory>
  </devices>**
  <seclabel type='dynamic' model='dac' relabel='yes'>
    <label>+1000:+101</label>
    <imagelabel>+1000:+101</imagelabel>
  </seclabel>
  <qemu:commandline>
    <qemu:env name='VIRTLET_EMULATOR' value='/usr/local/bin/qemu-system-x86_64'/>
    <qemu:env name='VIRTLET_NET_KEY' value='eeecdfd4-b81c-4a7b-abe9-e78cc0228f40'/>
    <qemu:env name='VIRTLET_CONTAINER_ID' value='f31560c5-ca21-588f-63ea-e2ea9d28d8bc'/>
    <qemu:env name='VIRTLET_CONTAINER_LOG_PATH' value='/var/log/pods/system_default_vmdefault_eeecdfd4-b81c-4a7b-abe9-e78cc0228f40/vm/0.log'/>
    <qemu:env name='CGROUP_PARENT' value='/kubepods/podeeecdfd4-b81c-4a7b-abe9-e78cc0228f40/f31560c5-ca21-588f-63ea-e2ea9d28d8bc'/>
  </qemu:commandline>
</domain>

root@ip-172-31-10-115:/# 
**root@ip-172-31-10-115:/# virsh detach-device 1 mem.xml --config --live
error: Failed to detach device from mem.xml
error: device not found: matching memory device was not found**

root@ip-172-31-10-115:/# cat mem.xml 
**<memory model='dimm'>
   <target>
     <size unit='KiB'>524288</size>
     <node>0</node>
   </target>
</memory>**
root@ip-172-31-10-115:/# 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions