1. 14 6月, 2016 2 次提交
  2. 13 6月, 2016 1 次提交
    • W
      libxl: fix vm lock overwritten bug · 9ac94507
      Wang Yufei 提交于
      In libxl driver we do virObjectRef in libxlDomainObjBeginJob,
      If virCondWaitUntil failed, it goes to error, do virObjectUnref,
      There's a chance that someone undefine the vm at the same time,
      and refs unref to zero, vm is freed in libxlDomainObjBeginJob.
      But the vm outside function is not Null, we do virObjectUnlock(vm).
      That's how we overwrite the vm memory after it's freed. I fix it.
      Signed-off-by: NWang Yufei <james.wangyufei@huawei.com>
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      9ac94507
  3. 08 6月, 2016 1 次提交
  4. 07 6月, 2016 2 次提交
  5. 25 5月, 2016 1 次提交
    • C
      libxl: add .domainInterfaceAddresses · ba566428
      Chunyan Liu 提交于
      Add .domainInterfaceAddresses so that user can have a way to
      get domain interface address by 'virsh domifaddr'. Currently
      it only supports '--source lease'.
      
      Signed-off: Chunyan Liu <cyliu@suse.com>
      ba566428
  6. 24 5月, 2016 1 次提交
  7. 20 5月, 2016 1 次提交
  8. 18 5月, 2016 1 次提交
  9. 11 5月, 2016 2 次提交
    • J
      libxl: support migration stream V2 in migration · f9edcfa4
      Jim Fehlig 提交于
      Similar to "support Xen migration stream V2 in save/restore",
      add support for indicating the migration stream version in
      the migration code. To accomplish this, add a minimal migration
      cookie in the libxl driver that is passed between source and
      destination hosts. Initially, the cookie is only used in
      the Begin and Prepare phases of migration to communicate the
      version of the migration stream produced by the source.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      f9edcfa4
    • J
      libxl: support Xen migration stream V2 in save/restore · 5325123d
      Jim Fehlig 提交于
      Xen 4.6 introduced a new migration stream commonly referred to as
      "migration V2". Xen 4.6 and newer always produce this new stream,
      whereas Xen 4.5 and older always produce the legacy stream.
      Support for migration stream V2 can be detected at build time with
      LIBXL_HAVE_SRM_V2 from libxl.h. The legacy and V2 streams are not
      compatible, but a V2 host can accept and convert a legacy stream.
      
      Commit e7440656 changed the libxl driver to use the lowest libxl
      API version possible (version 0x040200) to ensure the driver
      builds against older Xen releases. The old 4.2 restore API does
      not support specifying a stream version and assumes a legacy
      stream, even if the incoming stream is migration V2. Thinking it
      has been given a legacy stream, libxl will fail to convert an
      incoming stream that is already V2, which causes the entire
      restore operation to fail. Xen's libvirt-related OSSTest has been
      failing since commit e7440656 landed in libvirt.git master. One
      of the more recent failures can be seen here
      
      http://lists.xenproject.org/archives/html/xen-devel/2016-05/msg00071.html
      
      This patch changes the call to libxl_domain_create_restore() to
      include the stream version if LIBXL_HAVE_SRM_V2 is defined. The
      version field of the libxlSavefileHeader struct is also updated
      to '2' when LIBXL_HAVE_SRM_V2 is defined, ensuring the stream
      version in the header matches the actual stream version produced
      by Xen. Along with bumping the libxl API requirement to 0x040400,
      this patch fixes save/restore on a migration V2 Xen host.
      
      Oddly, migration has never used the libxlSavefileHeader. It
      handles passing configuration in the Begin and Prepare phases,
      and then calls libxl directly to transfer domain state/memory
      in the Perform phase. A subsequent patch will add stream
      version handling in the Begin and Prepare phase handshaking,
      which will fix the migration related OSSTest failures.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      5325123d
  10. 01 4月, 2016 2 次提交
  11. 29 3月, 2016 2 次提交
  12. 26 3月, 2016 3 次提交
  13. 09 3月, 2016 1 次提交
  14. 04 3月, 2016 2 次提交
  15. 01 3月, 2016 1 次提交
  16. 25 2月, 2016 1 次提交
    • J
      libxl: implement virDomainInterfaceStats · 77fdd82e
      Joao Martins 提交于
      Introduce support for domainInterfaceStats API call for querying
      network interface statistics. Consequently it also enables the use of
      `virsh domifstat <dom> <interface name>` command plus seeing the
      interfaces names instead of "-" when doing `virsh domiflist <dom>`.
      
      After successful guest creation we fill the network interfaces names
      based on domain, device id and append suffix if it's emulated in the
      following form: vif<domid>.<devid>[-emu].  We extract the network
      interfaces info from the libxl_domain_config object in
      libxlDomainCreateIfaceNames() to generate ifname. On domain cleanup we
      also clear ifname, in case it was set by libvirt (i.e. being prefixed
      with "vif"). We also skip these two steps in case the name of the
      interface was manually inserted by the administrator. Since the
      introduction of netprefix (commit a040ba9e), ifnames with a registered
      prefix will be freed on virDomain{Obj,Def}Format*, thus eliminating
      the migration issues observed with the reverted commit d2e5538b whereas
      source and destination would have the same ifname.
      
      For getting the interface statistics we resort to virNetInterfaceStats
      and let libvirt handle the platform specific nits. Note that the
      latter is not yet supported in FreeBSD.
      Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
      77fdd82e
  17. 10 2月, 2016 1 次提交
    • J
      libxl: add p2p migration · a79da245
      Joao Martins 提交于
      Introduce support for VIR_MIGRATE_PEER2PEER in libvirt migration.
      Most of the changes occur at the source and no modifications at
      the receiver.
      
      In P2P mode there is only the Perform phase so we must handle the
      connection with the destination and actually perform the
      migration. libxlDomainPerformP2P implements the connection to the
      destination and libxlDoMigrateP2P implements the actual migration
      logic with virConnectPtr. In this function we take care of doing
      all phases of migration in the destination similar to
      virDomainMigrateVersion3Full. We appropriately save the last
      error reported in each of the phases to provide proper reporting.
      We don't yet support VIR_MIGRATE_TUNNELED and we always use V3
      with extensible params, thus it also makes the implementation
      simpler.
      
      It is worth noting that the receiver didn't have any changes, and
      since it's still the v3 sequence thus it is possible to migrate
      from a P2P to non-P2P host.
      Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
      a79da245
  18. 08 2月, 2016 2 次提交
  19. 05 2月, 2016 1 次提交
  20. 04 2月, 2016 2 次提交
  21. 22 1月, 2016 1 次提交
  22. 21 12月, 2015 1 次提交
    • A
      pci: Introduce virPCIStubDriver enumeration · 6d9cdd2a
      Andrea Bolognani 提交于
      This replaces the virPCIKnownStubs string array that was used
      internally for stub driver validation.
      
      Advantages:
      
        * possible values are well-defined
        * typos in driver names will be detected at compile time
        * avoids having several copies of the same string around
        * no error checking required when setting / getting value
      
      The names used mirror those in the
      virDomainHostdevSubsysPCIBackendType enumeration.
      6d9cdd2a
  23. 18 12月, 2015 2 次提交
  24. 16 12月, 2015 2 次提交
    • J
      libxl: implement virDomainGetJobStats · b7b43919
      Joao Martins 提交于
      Introduces support for domainGetJobStats which has the same
      info as domainGetJobInfo but in a slightly different format.
      Another difference is that virDomainGetJobStats can also
      retrieve info on the most recently completed job. Though so
      far this is only used in the source node to know if the
      migration has been completed. But because we don't support
      completed jobs we will deliver an error.
      Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
      b7b43919
    • J
      libxl: implement virDomainGetJobInfo · ad716651
      Joao Martins 提交于
      Introduce support for domainGetJobInfo to get info about the
      ongoing job. If the job is active it will update the
      timeElapsed which is computed with the "started" field added to
      struct libxlDomainJobObj.  For now we support just the very basic
      info and all jobs have VIR_DOMAIN_JOB_UNBOUNDED (i.e. no completion
      time estimation) plus timeElapsed computed.
      
      Openstack Kilo uses the Job API to monitor live-migration
      progress which is currently nonexistent in libxl driver and
      therefore leads to a crash in the nova compute node. Right
      now, migration doesn't use jobs in the source node and will
      return VIR_DOMAIN_JOB_NONE. Though nova handles this case and
      will migrate it properly instead of crashing.
      Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
      ad716651
  25. 09 12月, 2015 4 次提交