1. 08 11月, 2017 1 次提交
  2. 05 10月, 2017 1 次提交
  3. 13 6月, 2017 1 次提交
  4. 07 6月, 2017 1 次提交
  5. 27 4月, 2017 1 次提交
  6. 30 6月, 2016 1 次提交
  7. 07 6月, 2016 2 次提交
  8. 25 5月, 2016 1 次提交
  9. 10 5月, 2016 1 次提交
  10. 06 5月, 2016 1 次提交
  11. 26 4月, 2016 1 次提交
    • M
      qemuProcessCreatePretendCmd: Rework FIPS handling · 927d047e
      Michal Privoznik 提交于
      This function - in contrast with qemuBuildCommandLine - merely
      constructs our internal command representation of a domain. This
      is then later compared against expected output. Or, this function
      is used also in virConnectDomainXMLToNative(). But due to a copy
      paste error this function, just like its image - has @forceFips
      argument that if enabled forces FIPS, otherwise mimics FIPS state
      in the host. If FIPS is enabled or forced the generated command
      line is different to state in which FIPS is disabled. Problem is,
      while this could be desired in the virConnectDomainXMLToNative()
      case, this is undesirable in the test suite as it will produce
      unpredicted results.
      Solution to this is to rename argument to @enableFips to
      specifically tell whether we expect command line to be build in
      either of fashions and make virConnectDomainXMLToNative()
      implementation fetch FIPS state and pass it to
      qemuProcessCreatePretendCmd().
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      927d047e
  12. 15 4月, 2016 1 次提交
  13. 22 3月, 2016 4 次提交
  14. 01 3月, 2016 1 次提交
    • M
      qemu: Shorten per-domain directory names · a89f05ba
      Martin Kletzander 提交于
      Per-domain directories were introduced in order to be able to
      completely separate security labels for each domain (commit
      f1f68ca3).  However when the domain
      name is long (let's say a ridiculous 110 characters), we cannot
      connect to the monitor socket because on length of UNIX socket address
      is limited.  In order to get around this, let's shorten it in similar
      fashion and in order to avoid conflicts, throw in an ID there as well.
      Also save that into the status XML and load the old status XMLs
      properly (to clean up after older domains).  That way we can change it
      in the future.
      
      The shortening can be seen in qemuxml2argv tests, for example in the
      hugepages-pages2 case.
      Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
      a89f05ba
  15. 19 2月, 2016 3 次提交
    • J
      qemu: Avoid calling qemuProcessStop without a job · 81f50cb9
      Jiri Denemark 提交于
      Calling qemuProcessStop without a job opens a way to race conditions
      with qemuDomainObjExitMonitor called in another thread. A real world
      example of such a race condition:
      
        - migration thread (A) calls qemuMigrationWaitForSpice
        - another thread (B) starts processing qemuDomainAbortJob API
        - thread B signals thread A via qemuDomainObjAbortAsyncJob
        - thread B enters monitor (qemuDomainObjEnterMonitor)
        - thread B calls qemuMonitorSend
        - thread A awakens and calls qemuProcessStop
        - thread A calls qemuMonitorClose and sets priv->mon to NULL
        - thread B calls qemuDomainObjExitMonitor with priv->mon == NULL
        => monitor stays ref'ed and locked
      
      Depending on how lucky we are, the race may result in a memory leak or
      it can even deadlock libvirtd's event loop if it tries to lock the
      monitor to process an event received before qemuMonitorClose was called.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      81f50cb9
    • J
      qemu: Introduce qemuProcessBeginStopJob · 4d0c535a
      Jiri Denemark 提交于
      When destroying a domain we need to make sure we will be able to start a
      job no matter what other operations are running or even stuck in a job.
      This is done by killing the domain before starting the destroy job.
      
      Let's introduce qemuProcessBeginStopJob which combines killing a domain
      and starting a job in a single API which can be called everywhere we
      need a job to stop a domain.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      4d0c535a
    • J
      qemu: Pass async job to qemuProcessInit · b7a948be
      Jiri Denemark 提交于
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      b7a948be
  16. 11 2月, 2016 1 次提交
    • M
      qemu: Connect to guest agent iff needed · 88ed9d77
      Michal Privoznik 提交于
      https://bugzilla.redhat.com/show_bug.cgi?id=1293351
      
      Since we already have virtio channel events, we know when guest
      agent within guest has (dis-)connected. Instead of us blindly
      connecting to a socket that no one is listening to, we can just
      follow what qemu-ga does. This has a nice benefit that we don't
      need to 'guest-ping' the agent just to timeout and find out
      nobody is listening.
      
      The way that this commit is implemented:
      - don't connect in qemuProcessLaunch directly, defer that to event
        callback (which already follows the agent) -
        processSerialChangedEvent
      - after migration is settled, before we resume vCPUs, ask qemu
        whether somebody is listening on the socket and if so, connect
        to it.
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      88ed9d77
  17. 09 2月, 2016 2 次提交
    • P
      qemu: iothread: Aggregate code to set IOThread tuning · 1dcc4c7f
      Peter Krempa 提交于
      Rather than iterating 3 times for various settings this function
      aggregates all the code into single place. One of the other advantages
      is that it can then be reused for properly setting IOThread info on
      hotplug.
      1dcc4c7f
    • P
      qemu: vcpu: Aggregate code to set vCPU tuning · 56971667
      Peter Krempa 提交于
      Rather than iterating 3 times for various settings this function
      aggregates all the code into single place. One of the other advantages
      is that it can then be reused for properly setting vCPU info on hotplug.
      
      With this approach autoCpuset is also used when setting the process
      affinity rather than just via cgroups.
      56971667
  18. 08 2月, 2016 1 次提交
  19. 01 2月, 2016 1 次提交
  20. 08 1月, 2016 1 次提交
  21. 26 11月, 2015 2 次提交
    • D
      qemu: convert monitor to use qemuDomainLogContextPtr indirectly · a48539c0
      Daniel P. Berrange 提交于
      Currently the QEMU monitor is given an FD to the logfile. This
      won't work in the future with virtlogd, so it needs to use the
      qemuDomainLogContextPtr instead, but it shouldn't directly
      access that object either. So define a callback that the
      monitor can use for reporting errors from the log file.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      a48539c0
    • D
      qemu: unify code for reporting errors from QEMU log files · 69b09921
      Daniel P. Berrange 提交于
      There are two pretty similar functions qemuProcessReadLog and
      qemuProcessReadChildErrors. Both read from the QEMU log file
      and try to strip out libvirt messages. The latter then reports
      an error, while the former lets the callers report an error.
      
      Re-write qemuProcessReadLog so that it uses a single read
      into a dynamically allocated buffer. Then introduce a new
      qemuProcessReportLogError that calls qemuProcessReadLog
      and reports an error.
      
      Convert all callers to use qemuProcessReportLogError.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      69b09921
  22. 25 11月, 2015 3 次提交
  23. 19 11月, 2015 3 次提交
    • J
      qemu: Use -incoming defer for migrations · 2c4ba8b4
      Jiri Denemark 提交于
      Traditionally, we pass incoming migration URI on QEMU command line,
      which has some drawbacks. Depending on the URI QEMU may initialize its
      migration state immediately without giving us a chance to set any
      additional migration parameters (this applies mainly for fd: URIs). For
      some URIs the monitor may be completely blocked from the beginning until
      migration is finished, which means we may be stuck in qmp_capabilities
      command without being able to send any QMP commands.
      
      QEMU solved this by introducing "defer" parameter for -incoming command
      line option. This will tell QEMU to prepare for an incoming migration
      while the actual incoming URI is sent using migrate-incoming QMP
      command. Before calling this command we can normally talk to the
      monitor and even set any migration parameters which will be honored by
      the incoming migration.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      2c4ba8b4
    • J
      qemu: Always set async job when starting a domain · 04c721f2
      Jiri Denemark 提交于
      We only started an async job for incoming migration from another host.
      When we were starting a domain from scratch or restoring from a saved
      state (migration from file) we didn't set any async job. Let's introduce
      a new QEMU_ASYNC_JOB_START for these cases.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      04c721f2
    • J
      qemu: Introduce qemuProcessIncomingDef · 2bf5333f
      Jiri Denemark 提交于
      Incoming migration may require quite a few parameters (URI, fd, path) to
      be considered while starting QEMU and we will soon add another one.
      Let's group all of them in a single struct.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      2bf5333f
  24. 26 4月, 2015 1 次提交
    • P
      qemu: Connect to guest agent after channel hotplug · a03e2d3a
      Peter Krempa 提交于
      If a user hot-attaches the guest agent channel libvirt would ignore it
      until the restart of libvirtd or shutdown/destroy and start of the VM
      itself.
      
      This patch adds code that opens or closes the guest agent connection
      according to the state of the guest agent channel according to
      connect/disconnect events.
      
      To allow opening the channel from the event handler qemuConnectAgent
      needed to be exported.
      a03e2d3a
  25. 02 4月, 2015 1 次提交
  26. 16 3月, 2015 1 次提交
  27. 03 3月, 2015 1 次提交
  28. 12 2月, 2015 1 次提交