1. 20 9月, 2017 11 次提交
    • Z
      vhost-user: add support reconnect for vhost-user ports · edaf4ebe
      ZhiPeng Lu 提交于
      For vhost-user ports, Open vSwitch acts as the server and QEMU the client.
      When OVS crashed or restart, QEMU shoule be reconnect to OVS.
      Signed-off-by: NZhiPeng Lu <lu.zhipeng@zte.com.cn>
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      edaf4ebe
    • J
      storage: Add new events for *PoolBuild() and *PoolDelete(). · b0652192
      Julio Faracco 提交于
      This commit adds new events for two methods and operations: *PoolBuild() and
      *PoolDelete(). Using the event-test and the commands set below we have the
      following outputs:
      
      $ sudo ./event-test
      Registering event callbacks
      myStoragePoolEventCallback EVENT: Storage pool test Defined 0
      myStoragePoolEventCallback EVENT: Storage pool test Created 0
      myStoragePoolEventCallback EVENT: Storage pool test Started 0
      myStoragePoolEventCallback EVENT: Storage pool test Stopped 0
      myStoragePoolEventCallback EVENT: Storage pool test Deleted 0
      myStoragePoolEventCallback EVENT: Storage pool test Undefined 0
      
      Another terminal:
      $ sudo virsh pool-define test.xml
      Pool test defined from test.xml
      
      $ sudo virsh pool-build test
      Pool test built
      
      $ sudo virsh pool-start test
      Pool test started
      
      $ sudo virsh pool-destroy test
      Pool test destroyed
      
      $ sudo virsh pool-delete test
      Pool test deleted
      
      $ sudo virsh pool-undefine test
      Pool test has been undefined
      
      This commits can be a solution for RHBZ #1475227.
      
      Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1475227Signed-off-by: NJulio Faracco <jcfaracco@gmail.com>
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      b0652192
    • Z
      qemu: handle reconnect on chardev hotplug · 0dde16be
      ZhiPeng Lu 提交于
      The patch passes the reconnect timeout to QEMU by monitor on
      chardev hotplug.
      Signed-off-by: NZhiPeng Lu <lu.zhipeng@zte.com.cn>
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      0dde16be
    • D
      Link libvirt_util.la with gnutls · c120ce16
      Daniel P. Berrange 提交于
      The util/vircrypto.c file uses gnutls, so we must directly link
      libvirt_util.la with gnutls to avoid errors on OS which do not
      resolve symbols against indirectly linked libraries.
      
      This fixes a build failure on Ubuntu Trusty
      
        CCLD     storagevolxml2argvtest
      /usr/bin/ld: ../src/.libs/libvirt_util.a(libvirt_util_la-vircrypto.o): undefined reference to symbol 'gnutls_strerror@@GNUTLS_1_4'
      
      //usr/lib/x86_64-linux-gnu/libgnutls.so.26: error adding symbols: DSO missing from command line
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      c120ce16
    • A
      qemu: Add qemu command line generation for a VxHS block device · dbd98380
      Ashish Mittal 提交于
      The VxHS block device will only use the newer formatting options and
      avoid the legacy URI syntax.
      
      An excerpt for a sample QEMU command line is:
      
        -drive file.driver=vxhs,file.vdisk-id=eb90327c-8302-4725-9e1b-4e85ed4dc251,\
         file.server.type=tcp,file.server.host=192.168.0.1,\
         file.server.port=9999,format=raw,if=none,id=drive-virtio-disk0,cache=none \
        -device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\
         id=virtio-disk0
      
      Update qemuxml2argvtest with a simple test.
      Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com>
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      dbd98380
    • A
      qemu: Refactor qemuBlockStorageSourceBuildHostsJSONSocketAddress · 8b5e76e9
      Ashish Mittal 提交于
      Extract out the "guts" of building a server entry into it's own
      separately callable/usable function in order to allow building
      a server entry for a consumer with src->nhosts == 1.
      8b5e76e9
    • A
      util: storage: Add JSON backing volume parse for VxHS · 2a48252b
      Ashish Mittal 提交于
      Add the backing parse and a test case to verify parsing of VxHS
      backing storage.
      Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com>
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      2a48252b
    • A
      docs: Add schema and docs for Veritas HyperScale (VxHS) · e6a7fa26
      Ashish Mittal 提交于
      Alter the schema to allow a VxHS block device. Sample XML is:
      
        <disk type='network' device='disk'>
          <driver name='qemu' type='raw' cache='none'/>
          <source protocol='vxhs' name='eb90327c-8302-4725-9e1b-4e85ed4dc251'>
            <host name='192.168.0.1' port='9999'/>
          </source>
          <target dev='vda' bus='virtio'/>
          <serial>eb90327c-8302-4725-9e1b-4e85ed4dc251</serial>
          <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
        </disk>
      
      Update the html docs to describe the capability for VxHS.
      
      Alter the qemuxml2xmltest to validate the formatting.
      Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com>
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      e6a7fa26
    • A
      storage: Introduce VIR_STORAGE_NET_PROTOCOL_VXHS · 029c36c9
      Ashish Mittal 提交于
      Add a new virStorageNetProtocol for Veritas HyperScale (VxHS) disks
      Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com>
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      029c36c9
    • J
      qemu: Detect support for vxhs · fa6159dd
      John Ferlan 提交于
      Using the query-qmp-schema introspection - look for the 'vxhs'
      blockdevOptions type.
      
      NB: This is a "best effort" type situation as there is not a
          mechanism to determine whether the running QEMU has been
          built with '--enable-vxhs'. All we can do is check if the
          option to use vxhs for a blockdev-add exists in the command
          infrastructure which does not take that into account when
          building its table of commands and options.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      fa6159dd
    • L
      util: virPCIGetNetName(): use first netdev name when phys_port_id isn't matched · 747116e0
      Laine Stump 提交于
      The mlx4 (Mellanox) netdev driver implements the sysfs phys_port_id
      file for both VFs and PFs, so you can find the VF netdev plugged into
      the same physical port as any given PF netdev by comparing the
      contents of phys_port_id of the respective netdevs. That's what
      libvirt does when attempting to find the PF netdev for a given VF
      netdev (or vice versa).
      
      Most other netdev's drivers don't implement phys_port_id, so the file
      is visible in sysfs directory listing, but attempts to read it result
      in ENOTSUPP. In these cases, libvirt is unable to read phys_port_id of
      either the PF or the VF, so it just returns the first entry in the
      PF/VF's list of netdevs.
      
      But we've found that the i40e driver is in between those two
      situations - it implements phys_port_id for PF netdevs, but doesn't
      implement it for VF netdevs. So libvirt would successfully read the
      phys_port_id of the PF netdev, then try to find a VF netdev with
      matching phys_port_id, but would fail because phys_port_id is NULL for
      all VFs. This would result in a message like the following:
      
         Could not find network device with phys_port_id '3cfdfe9edc39'
         under PCI device at /sys/class/net/ens4f1/device/virtfn0
      
      To solve this problem in a way that won't break functionality for
      anyone else, this patch saves the first netdev name we find for the
      device, and returns that if we fail to find a netdev with the desired
      phys_port_id.
      747116e0
  2. 19 9月, 2017 25 次提交
  3. 18 9月, 2017 4 次提交