1. 13 8月, 2019 1 次提交
  2. 12 8月, 2019 2 次提交
  3. 10 8月, 2019 1 次提交
    • D
      build: bump min libxml2 to 2.9.1 · e4c05240
      Daniel P. Berrangé 提交于
      The various distros have the following libxml2 vesions:
      
              CentOS 7: 2.9.1
        Debian Stretch: 2.9.4
         FreeBSD Ports: 2.9.9
      Ubuntu 16.04 LTS: 2.9.3
      
      Based on this sampling, we can reasonably bump libxml2 min
      version to 2.9.1
      
      The 'query_raw' struct field was added in version 2.6.28,
      so can be assumed to exist.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      e4c05240
  4. 09 8月, 2019 4 次提交
    • J
      qemu: Pass correct qemuCaps to virDomainDeviceDefPostParse · b449c270
      Jiri Denemark 提交于
      Since qemuDomainDeviceDefPostParse callback requires qemuCaps, we need
      to make sure it gets the capabilities stored in the domain's private
      data if the domain is running. Passing NULL may cause QEMU capabilities
      probing to be triggered in case QEMU binary changed in the meantime.
      When this happens while a running domain object is locked, QMP event
      delivered to the domain before QEMU capabilities probing finishes will
      deadlock the event loop.
      
      QEMU capabilities lookup (via domainPostParseDataAlloc callback) is
      hidden inside virDomainDeviceDefPostParseOne with no way to pass
      qemuCaps to virDomainDeviceDef* functions. This patch fixes all
      remaining paths leading to virDomainDeviceDefPostParse.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      b449c270
    • J
      qemu: Pass correct qemuCaps to virDomainDefParseNode · 577a1f98
      Jiri Denemark 提交于
      Since qemuDomainDefPostParse callback requires qemuCaps, we need to make
      sure it gets the capabilities stored in the domain's private data if the
      domain is running. Passing NULL may cause QEMU capabilities probing to
      be triggered in case QEMU binary changed in the meantime. When this
      happens while a running domain object is locked, QMP event delivered to
      the domain before QEMU capabilities probing finishes will deadlock the
      event loop.
      
      Several general snapshot and checkpoint APIs were lazily passing NULL as
      the parseOpaque pointer instead of letting their callers pass the right
      data. This patch fixes all paths leading to virDomainDefParseNode.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      577a1f98
    • J
      qemu: Pass correct qemuCaps to virDomainDefCopy · bbcfa07b
      Jiri Denemark 提交于
      Since qemuDomainDefPostParse callback requires qemuCaps, we need to make
      sure it gets the capabilities stored in the domain's private data if the
      domain is running. Passing NULL may cause QEMU capabilities probing to
      be triggered in case QEMU binary changed in the meantime. When this
      happens while a running domain object is locked, QMP event delivered to
      the domain before QEMU capabilities probing finishes will deadlock the
      event loop.
      
      Several general functions from domain_conf.c were lazily passing NULL as
      the parseOpaque pointer instead of letting their callers pass the right
      data. This patch fixes all paths leading to virDomainDefCopy to do the
      right thing.
      Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      bbcfa07b
    • M
      nss: Don't stop parsing on unexpected key · 8be0ab63
      Michal Privoznik 提交于
      Due to latest rewrite of NSS module, we are doing yajl parsing
      ourselves. This means, we had to introduce couple of callback
      that yajl calls. According to its documentation, a callback can
      cancel parsing if it returns a zero value. Well, we do just that
      in the string callback (findLeasesParserString()). If the JSON
      file we are parsing contains a key that we are not interested in,
      zero is returned meaning stop all parsing. This is not correct,
      because the JSON file can contain some other keys which are not
      harmful for our address translation (e.g. 'client-id').
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
      8be0ab63
  5. 08 8月, 2019 1 次提交
  6. 07 8月, 2019 3 次提交
  7. 06 8月, 2019 4 次提交
  8. 02 8月, 2019 1 次提交
    • E
      tests: Fix virsh-snapshot/checkpoint without readline-devel · 8bfb1371
      Eric Blake 提交于
      readline-devel is an optional build dependency; when it is not
      present, the output of 'virsh <<EOF ... EOF' is different in that the
      input provided by the user is not echoed, and prompts become
      interleaved on the same line as actual output, which in turn causes
      the sed doing prompt filtering to mess up:
      
      | ./virsh-snapshot
      | --- exp	2019-07-31 18:42:31.107399428 -0300
      | +++ out.cooked	2019-07-31 18:42:31.108399437 -0300
      | @@ -1,8 +1,3 @@
      | -
      | -
      | -Domain snapshot s3 created from 's3.xml'
      | -Domain snapshot s2 created from 's2.xml'
      | -Name:           s2
      |  Domain:         test
      |  Current:        yes
      |  State:          running
      
      Maybe we should fix virsh in interactive mode to echo regardless of
      whether readline-devel was used, but the quicker fix is to make the
      test use 'virsh "..."' rather than reading its input from stdin.
      Reported-by: NDaniel Henrique Barboza <danielhb413@gmail.com>
      Signed-off-by: NEric Blake <eblake@redhat.com>
      Tested-by: NDaniel Henrique Barboza <danielhb413@gmail.com>
      8bfb1371
  9. 29 7月, 2019 7 次提交
  10. 27 7月, 2019 5 次提交
    • E
      backup: Add virsh-checkpoints test · 43686f36
      Eric Blake 提交于
      Similar to virsh-snapshots. Provides decent coverage of the checkpoint
      API, the test driver implementation, and the virsh access to the API.
      A later patch will worry about testing that snapshots and checkpoints
      are mutually exclusive (in part so it is easier to revert that when we
      finally implement the interaction and lift that restriction).
      Signed-off-by: NEric Blake <eblake@redhat.com>
      Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
      43686f36
    • E
      backup: Parse and output checkpoint XML · 1a4df34a
      Eric Blake 提交于
      Add a new file checkpoint_conf.c that performs the translation to and
      from new XML describing a checkpoint. The code shares a common base
      class with snapshots, since a checkpoint similarly represents the
      domain state at a moment in time. Add some basic testing of round trip
      XML handling through the new code.
      
      Of note - this code intentionally differs from snapshots in that XML
      schema validation is unconditional, rather than based on a public API
      flag.  We have many existing interfaces that still need to add a flag
      for opt-in schema validation, but those interfaces have existing
      clients that may not have been producing strictly-compliant XML, or we
      may still uncover bugs where our RNG grammar is inconsistent with our
      code (where omitting the opt-in flag allows existing apps to keep
      working while waiting for an RNG patch).  But since checkpoints are
      brand-new, it's easier to ensure the code matches the schema by always
      using the schema.  If needed, a later patch could extend the API and
      add a flag to turn on to request schema validation, rather than having
      it forced (possibly just the validation of the <domain> sub-element
      during REDEFINE) - but if a user encounters XML that looks like it
      should be good but fails to validate with our RNG schema, they would
      either have to upgrade to a new libvirt that adds the new flag, or
      upgrade to a new libvirt that fixes the RNG schema, which implies
      adding such a flag won't help much.
      
      Also, the redefine flag requires the <domain> sub-element to be
      present, rather than catering to historical back-compat to older
      versions.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      1a4df34a
    • E
      backup: Document new XML for checkpoints · d85842cf
      Eric Blake 提交于
      Prepare for new checkpoint APIs by describing the XML that will
      represent a checkpoint.  The checkpoint XML is modeled heavily after
      virDomainSnapshotPtr. See the docs for more details.
      
      Add testsuite coverage for some minimal uses of the XML (bare minimum,
      the sample from html, and a full dumpxml, and some counter-examples
      that should fail schema validation). Although use of the REDEFINE flag
      will require the <domain> subelement to be present, it is easier for
      most of the tests to provide counterpart output produced with the
      NO_DOMAIN flag (particularly since synthesizing a valid <domain>
      during testing is not trivial).
      Signed-off-by: NEric Blake <eblake@redhat.com>
      Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
      d85842cf
    • S
      tests: Call virCommandFree() in cleanup section · 9b4bc795
      Stefan Berger 提交于
      Fix a potential memory leak by calling virCommandFree() in the cleanup
      section.
      Signed-off-by: NStefan Berger <stefanb@linux.ibm.com>
      Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
      Message-Id: <20190726205633.2041912-3-stefanb@linux.vnet.ibm.com>
      9b4bc795
    • E
      snapshot: Fix tests/virsh-snapshot · 0dbfc396
      Eric Blake 提交于
      Creating an 'exp' output file, but never comparing it against the
      actual output, does not actually constitute testing the output. :)
      
      Fixes: 280a2b41Signed-off-by: NEric Blake <eblake@redhat.com>
      0dbfc396
  11. 26 7月, 2019 5 次提交
  12. 25 7月, 2019 6 次提交