1. 28 4月, 2010 9 次提交
    • S
      nwfilter: allow to mix filterrefs and rules in the schema · 42f8b25b
      Stefan Berger 提交于
      So far the references to other filters needed to appear before filtering
      rules. With the below patch they can now appear in any order.
      
      Also I forgot to add a couple of 'rarp's.
      42f8b25b
    • D
      Fix handling of security driver restore failures in QEMU domain save · 51cd0196
      Daniel P. Berrange 提交于
      In cases where the security driver failed to restore a label after a
      guest has saved, we mistakenly jumped to the error cleanup paths.
      This is not good, because the operation has in fact completed and
      cannot be rolled back completely. Label restore is non-critical, so
      just log the problem instead. Also add a missing restore call in
      the error cleanup path
      
      * src/qemu/qemu_driver.c: Fix handling of security driver
        restore failures in QEMU domain save
      51cd0196
    • D
      Fix QEMU domain save to block devices with cgroups enabled · 712048bd
      Daniel P. Berrange 提交于
      When cgroups is enabled, access to block devices is likely to be
      restricted to a whitelist. Prior to saving a guest to a block device,
      it is necessary to add the block device to the whitelist. This is
      not required upon restore, since QEMU reads from stdin
      
      * src/qemu/qemu_driver.c: Add block device to cgroups whitelist
        if neccessary during domain save.
      712048bd
    • D
      Fix QEMU save/restore with block devices · 93e0b3c8
      Daniel P. Berrange 提交于
      The save process was relying on use of the shell >> append
      operator to ensure the save data was placed after the libvirt
      header + XML. This doesn't work for block devices though.
      Replace this code with use of 'dd' and its 'seek' parameter.
      This means that we need to pad the header + XML out to a
      multiple of dd block size (in this case we choose 512).
      
      The qemuMonitorMigateToCommand() monitor API is used for both
      save/coredump, and migration via UNIX socket. We can't simply
      switch this to use 'dd' since this causes problems with the
      migration usage. Thus, create a dedicated qemuMonitorMigateToFile
      which can accept an filename + offset, and remove the filename
      from the current qemuMonitorMigateToCommand() API
      
      * src/qemu/qemu_driver.c: Switch to qemuMonitorMigateToFile
        for save and core dump
      * src/qemu/qemu_monitor.c, src/qemu/qemu_monitor.h,
        src/qemu/qemu_monitor_json.c, src/qemu/qemu_monitor_json.h,
        src/qemu/qemu_monitor_text.c, src/qemu/qemu_monitor_text.h: Create
        a new qemuMonitorMigateToFile, separate from the existing
        qemuMonitorMigateToCommand to allow handling file offsets
      93e0b3c8
    • D
      Avoid create/unlink with block devs used for QEMU save · ae42979a
      Daniel P. Berrange 提交于
      It is possible to use block devices with domain save/restore. Upon
      failure QEMU unlinks the path being saved to. This isn't good when
      it is a block device !
      
      * src/qemu/qemu_driver.c: Don't unlink block devices if save fails
      ae42979a
    • D
      Fix crash when cleaning up from failed save attempt · d7e0fe6e
      Daniel P. Berrange 提交于
      If a transient QEMU crashes during save attempt, then the virDomainPtr
      object may be freed. If a persistent QEMU crashes during save, then
      the 'priv->mon' field is no longer valid since it will be inactive.
      
      * src/qemu/qemu_driver.c: Fix two crashes when QEMU exits
        during a save attempt
      d7e0fe6e
    • S
      nwfilter: let qemu's after-migration packet pass · ed7813d2
      Stefan Berger 提交于
      Qemu currently sends an Ethernet packet with protocol id 0x835 once a VM
      was successfully migrated. The content of the packet looks like a
      gratuitous RARP, just with the wrong protocol ID, which should be
      0x8035. I wrote some filters to let either one of the packets pass and
      am adapting the clean-traffic sample filter to use it. I am also
      doing some changes on the existing ARP filter which was lacking a
      test for source MAC address.
      ed7813d2
    • C
    • K
      75d88455
  2. 27 4月, 2010 11 次提交
    • C
      Fix up the locking in the snapshot code. · b69bbebb
      Chris Lalancette 提交于
      In particular I was forgetting to take the qemuMonitorPrivatePtr
      lock (via qemuDomainObjBeginJob), which would cause problems
      if two users tried to access the same domain at the same time.
      This patch also fixes a problem where I was forgetting to remove
      a transient domain from the list of domains.
      
      Thanks to Stephen Shaw for pointing out the problem and testing
      out the initial patch.
      Signed-off-by: NChris Lalancette <clalance@redhat.com>
      b69bbebb
    • D
      cleanup the download section of the documentation · 0c4010a1
      Daniel Veillard 提交于
      Just removing reverences to the deprecated CVS server and the old git
      on et.redhat.com
      0c4010a1
    • S
      nwfilter: add support for RAPR protocol · aea68ce9
      Stefan Berger 提交于
      This patch adds support for the RARP protocol. This may be needed due to
      qemu sending out a RARP packet (at least that's what it seems to want to
      do even though the protocol id is wrong) when migration finishes and
      we'd need a rule to let the packets pass.
      
      Unfortunately my installation of ebtables does not understand -p RARP
      and also seems to otherwise depend on strings in /etc/ethertype
      translated to protocol identifiers. Therefore I need to pass -p 0x8035
      for RARP. To generally get rid of the dependency of that file I switch
      all so far supported protocols to use their protocol identifier in the
      -p parameter rather than the string.
      
      I am also extending the schema and added a test case.
      
      changes from v1 to v2:
      - added test case into patch
      aea68ce9
    • J
      Ignore qemu STOP event when stopping CPUs · 35b61376
      Jiri Denemark 提交于
      With JSON qemu monitor, we get a STOP event from qemu whenever qemu
      stops guests CPUs. The downside of it is that vm->state is changed to
      PAUSED and a new generic paused event is send to applications. However,
      when we ask qemu to stop the CPUs we are not really interested in qemu
      event and we usually want to issue a more specific event.
      
      By setting vm->status to PAUSED before actually sending the request to
      qemu (and resetting it back if the request fails) we can ignore the
      event since the event handler does nothing when the guest is already
      paused. This solution is quite hacky but unfortunately it's the best
      solution which I was able to come up with and it doesn't introduce a
      race condition.
      35b61376
    • J
      Fix build with DEBUG_RAW_IO=1 · 29bca037
      Jiri Denemark 提交于
      29bca037
    • D
      Fix indentation for storage conf XML · 1b9347b5
      David Allan 提交于
      * virStorageEncryptionFormat is called from both
        virDomainDiskDefFormat and virStorageVolTargetDefFormat.  The proper
        indentation in the generated XML depends on the caller.  My earlier
        patch to fix the incorrect indentation for the domain XML broke the
        indentation for the storage XML.  This patch adopts Laine's
        suggestion of requring the caller of virStorageEncryptionFormat to
        provide an unsigned int with the number of spaces the output should
        be indented.  The patch modifies both callers to provide the
        additional argument.
      
      * Add a regression test for the domain XML
      
      * src/conf/domain_conf.c src/conf/storage_conf.c
        src/conf/storage_encryption_conf.c src/conf/storage_encryption_conf.h:
        change the indentation code
      * tests/qemuxml2xmltest.c
        tests/qemuxml2argvdata/qemuxml2argv-encrypted-disk.args
        tests/qemuxml2argvdata/qemuxml2argv-encrypted-disk.xml: add a regression test
      1b9347b5
    • D
      Don't try to build qemu and lxc on non-Linux platforms · 6b3ce82d
      Daniel Veillard 提交于
      as their drivers requires linux only headers
      6b3ce82d
    • M
      cygwin: Handle differences in the XDR implementation · d707c866
      Matthias Bolte 提交于
      Cygwin's XDR implementation defines xdr_u_int64_t instead of
      xdr_uint64_t and lacks IXDR_PUT_INT32/IXDR_GET_INT32.
      
      Alter the IXDR_GET_LONG regex in rpcgen_fix.pl so it doesn't destroy
      the #define IXDR_GET_INT32 IXDR_GET_LONG in remote_protocol.x.
      
      Also fix the remote_protocol.h regex in rpcgen_fix.pl.
      d707c866
    • M
    • M
      fe4ff24a
    • S
      nwfilter: enable hex number inputs in filter XML · 5c7c755f
      Stefan Berger 提交于
      With this patch I want to enable hex number inputs in the filter XML. A
      number that was entered as hex is also printed as hex unless a string
      representing the meaning can be found.
      
      I am also extending the schema and adding a test case. A problem with
      the DSCP value is fixed on the way as well.
      
      Changes from V1 to V2:
      
      - using asHex boolean in all printf type of functions to select the
      output format in hex or decimal format
      5c7c755f
  3. 26 4月, 2010 4 次提交
    • S
      Starts dnsmasq from libvirtd with --dhcp-hostsfile option · 8fa9c221
      Satoru SATOH 提交于
      This patch makes libvirtd start the dnsmasq daemon with a
      --dhcp-hostsfile option instead of --dhcp-host options for each
      '//ip/dhcp/host' entries defined in network xml file.
      
      the dnsmasq host file is stored into /var/lib/libvirt/network
      
      * src/network/bridge_driver.c: define the directory for the hostfiles
        and save/delete them to be used by dnsmasq
      8fa9c221
    • S
      Add build support for dnsmasq module · 51d203c6
      Satoru SATOH 提交于
      * po/POTFILES.in: the new module contains translatable strings
      * src/Makefile.am: include the files in the utils set
      * src/libvirt_private.syms: exports the symbols internally
      51d203c6
    • S
      Add dnsmasq module files · 4ad65ab8
      Satoru SATOH 提交于
      It implements an idea to save dhcp hosts' macaddr vs. ipaddr mappings to
      static file and make dnsmasq loading it with "--dhcp-hostsfile" option,
      originally suggested by Dan, and can address the problem that too
      many "--dhcp-host" args hitting ARG_MAX limit
      
      * src/util/dnsmasq.h src/util/dnsmasq.c: adds the 2 new files
      4ad65ab8
    • D
      Fix make dist missing ESX generated files · 4ce54ef5
      Daniel Veillard 提交于
      new method generated files are missing from dist tarball.
      4ce54ef5
  4. 24 4月, 2010 13 次提交
  5. 23 4月, 2010 3 次提交