1. 17 5月, 2010 1 次提交
  2. 15 5月, 2010 5 次提交
    • J
      qemudDomainSetVcpus: avoid NULL-deref · b48fb801
      Jim Meyering 提交于
      * src/qemu/qemu_driver.c (qemudDomainSetVcpus): Avoid NULL-deref
      upon unknown UUID.  Call qemuDomainObjBeginJob(vm) only after
      ensuring that vm != NULL, not before.  This potential NULL-deref
      was introduced by commit 2c555d87.
      b48fb801
    • E
      Revert "build: fix cygwin build" · 39b3845f
      Eric Blake 提交于
      This reverts commit 2d550542.
      
      The patch worked for incremental builds, but broke fresh
      builds, because it interfered with automake's automatic
      dependency generation.  Until I figure out how to make
      automake do what we want, I'd rather leave cygwin broken
      but fresh Linux builds working.
      39b3845f
    • E
      build: fix cygwin build · 2d550542
      Eric Blake 提交于
      make[3]: *** No rule to make target `-lxml2', needed by `libvirt.la'.  Stop.
      
      Due to treating the wrong string as a dependency.
      
      * src/Makefile.am (libvirt_la_DEPENDENCIES): Depend only on
      locally-built file, not on strings that might resolve as '-lxml2'.
      2d550542
    • S
      nwfilter: Add missing driver lock in qemu driver · ba99a1b6
      Stefan Berger 提交于
      This adds a missing driver lock in the qemu driver to protect
      the list of domains.
      ba99a1b6
    • R
      Fix a misuse of virAsprintf in qemudDomainMemoryPeek · d6644013
      Ryota Ozaki 提交于
      The code specifies driver->cacheDir as the format string,
      but it usually doesn't contain '%s', so the subsequent
      argument, "/qemu.mem.XXXXXX", is always ignored.
      
      The patch fixes the misuse.
      d6644013
  3. 14 5月, 2010 5 次提交
    • D
      Make domain save work when dynamic_ownership=0 · de4d7087
      Daniel P. Berrange 提交于
      Setting dynamic_ownership=0 in /etc/libvirt/qemu.conf prevents
      libvirt's DAC security driver from setting uid/gid on disk
      files when starting/stopping QEMU, allowing the admin to manage
      this manually. As a side effect it also stopped setting of
      uid/gid when saving guests to a file, which completely breaks
      save when QEMU is running non-root. Thus saved state labelling
      code must ignore the dynamic_ownership parameter
      
      * src/qemu/qemu_security_dac.c: Ignore dynamic_ownership=0 when
        doing save/restore image labelling
      de4d7087
    • D
      Don't reset user/group/security label on shared filesystems during migrate · 02ddaddf
      Daniel P. Berrange 提交于
      When QEMU runs with its disk on NFS, and as a non-root user, the
      disk is chownd to that non-root user. When migration completes
      the last step is shutting down the QEMU on the source host. THis
      normally resets user/group/security label. This is bad when the
      VM was just migrated because the file is still in use on the dest
      host. It is thus neccessary to skip the reset step for any files
      found to be on a shared filesystem
      
      * src/libvirt_private.syms: Export virStorageFileIsSharedFS
      * src/util/storage_file.c, src/util/storage_file.h: Add a new
        method virStorageFileIsSharedFS() to determine if a file is
        on a shared filesystem (NFS, GFS, OCFS2, etc)
      * src/qemu/qemu_driver.c: Tell security driver not to reset
        disk labels on migration completion
      * src/qemu/qemu_security_dac.c, src/qemu/qemu_security_stacked.c,
        src/security/security_selinux.c, src/security/security_driver.h,
        src/security/security_apparmor.c: Add ability to skip disk
        restore step for files on shared filesystems.
      02ddaddf
    • D
      Fix handling of disk backing stores with cgroups · 117d04fb
      Daniel P. Berrange 提交于
      The cgroups ACL code was only allowing the primary disk image.
      It is possible to chain images together, so we need to search
      for backing stores and add them to the ACL too. Since the ACL
      only handles block devices, we ignore the EINVAL we get from
      plain files. In addition it was missing code to teardown the
      cgroup when hot-unplugging a disk
      
      * src/qemu/qemu_driver.c: Allow backing stores in cgroup ACLs
        and add missing teardown code in unplug path
      117d04fb
    • D
      Fix possible crash in handling IO Error event · abb76942
      Daniel P. Berrange 提交于
      If the IO error event does not include a reason, then there
      is a possible crash dispatching the event
      
      * src/conf/domain_event.c: Missing check for a NULL reason before
        strduping allows for a crash
      abb76942
    • D
      Add support for NIC hotplug using netdev_add in QEMU · ff45b4c2
      Daniel P. Berrange 提交于
      QEMU is gaining a new monitor command netdev_add for hotplugging
      NICs using the netdev backend code. We already support this on
      the command this, though it is disabled. This adds support for
      hotplug too, also to remain disabled until 0.13 QEMU is released
      
      * src/qemu/qemu_driver.c: Support netdev hotplug for NICs
      * 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: Add
        support for netdev_add and netdev_remove commands
      ff45b4c2
  4. 13 5月, 2010 1 次提交
  5. 12 5月, 2010 8 次提交
    • J
      Fix monitor ref counting when adding event handle · d84bb6d6
      Jiri Denemark 提交于
      When closing a monitor using qemuMonitorClose(), we are aware of
      the possibility the monitor is still being used somewhere:
      
          /* NB: ordinarily one might immediately set mon->watch to -1
           * and mon->fd to -1, but there may be a callback active
           * that is still relying on these fields being valid. So
           * we merely close them, but not clear their values and
           * use this explicit 'closed' flag to track this state */
      
      but since we call virEventAddHandle() on that monitor without increasing
      its ref counter, the monitor is still freed which makes possible users
      of it quite unhappy. The unhappiness can lead to a hang if qemuMonitorIO
      tries to lock mutex which no longer exists.
      d84bb6d6
    • J
      Remove watches before calling REMOTE_PROC_CLOSE · 6ef9d9da
      Jiri Denemark 提交于
      First calling REMOTE_PROC_CLOSE and then removing watches might lead to
      a hang as HANGUP event can be triggered before the watches are actually
      removed but after virConnectPtr is already freed. As a result of that
      remoteDomainEventFired() would try to lock uninitialized mutex, which
      would hang for ever.
      6ef9d9da
    • J
      tests: use GPLv2+, not GPLv3 · c2c4abb4
      Jim Meyering 提交于
      * tests/cpuset: Change from GPLv3 to GPLv2+
      * tests/read-bufsiz: Likewise.
      * tests/read-non-seekable: Likewise.
      * tests/start: Likewise.
      * tests/undefine: Likewise.
      * tests/vcpupin: Likewise.
      * tests/virsh-all: Likewise.
      * tests/virsh-schedinfo: Likewise.
      * tests/virsh-synopsis: Likewise.
      c2c4abb4
    • E
      libvirt_proxy: link with -lpthread if needed · ff1d6f85
      Eric Blake 提交于
      Continuation of earlier patches to fix LIB_PTHREAD, only
      triggered by ./configure --with-xen-proxy (a la autobuild.sh).
      
      * proxy/Makefile.am (libvirt_proxy_LDADD): Add LIB_PTHREAD.
      ff1d6f85
    • C
      node_device: udev: Fix PCI product/vendor swappage · 74c7a346
      Cole Robinson 提交于
      Product and vendor values were swapped in the XML, which made virt-manager
      PCI device listing kinda useless.
      74c7a346
    • E
      build: update gnulib · e8a1a730
      Eric Blake 提交于
      * .gnulib: Update to latest.
      * bootstrap.conf (gnulib_modules): Import netdb.
      * src/esx/esx_util.c (AI_ADDRCONFIG): Rely on gnulib.
      * src/remote/remote_driver.c (AI_ADDRCONFIG): Likewise.
      * tools/virsh.c (WEXITSTATUS, O_SYNC): Likewise.
      e8a1a730
    • E
      build: allow older gettext · 03ae900f
      Eric Blake 提交于
      * bootstrap.conf (gnulib_modules): Use gettext-h, not gettext,
      since the latter drags in a depedency on gettext 0.18.
      Suggested by Bruno Haible.
      03ae900f
    • J
      tests: correct PATH in new test, for when running manually · e915962a
      Jim Meyering 提交于
      * tests/virsh-schedinfo: This test sets PATH internally, just in
      case you're running it manually.  Normally, the PATH setting from
      tests/Makefile.am's TESTS_ENVIRONMENT is sufficient.  Prepend the
      correct directory, and take advantage of the PATH setting in one
      more case.
      e915962a
  6. 11 5月, 2010 9 次提交
    • D
      Add env variable for debugging gnutls usage · 36a03bd2
      Daniel P. Berrange 提交于
      Allow debugging of GNUTLS interactions by setting
      
        LIBVIRT_GNUTLS_DEBUG=10 LIBVIRT_DEBUG=1 virsh
      
      * src/remote/remote_driver.c: Use LIBVIRT_GNUTLS_DEBUG to
        enable gnutls debugging
      36a03bd2
    • J
      tests: adjust copyrights on scripts: s/FSF/Red Hat/ · c5be8bcb
      Jim Meyering 提交于
      * tests/cpuset: Change copyright holder from FSF to Red Hat, Inc.
      * tests/read-bufsiz: Likewise.
      * tests/read-non-seekable: Likewise.
      * tests/start: Likewise.
      * tests/undefine: Likewise.
      * tests/vcpupin: Likewise.
      * tests/virsh-all: Likewise.
      * tests/virsh-synopsis: Likewise.
      c5be8bcb
    • J
      virsh: schedinfo --set invalid=value would simply ignore the option · 9a641564
      Jim Meyering 提交于
      For example, virsh -c test:///default schedinfo 1 --set P=k would
      mistakenly exit successfully, giving no indication that it had failed
      to set the scheduling parameter "P".
      * tools/virsh.c (cmdSchedinfo): Diagnose an invalid --set j=k option,
      rather than silently ignoring it.
      * tests/virsh-schedinfo: New test for the above.
      * tests/Makefile.am (test_scripts): Add it.
      Reported by Jintao Yang in http://bugzilla.redhat.com/586632
      9a641564
    • J
      virsh: fix a typo in a diagnostic · 56035151
      Jim Meyering 提交于
      * tools/virsh.c (cmdSchedInfoUpdate): Fix typo in a diagnostic:
      s/an long long/a long long/.  One in a comment, too.
      56035151
    • E
      delMacvtap: typo fix · 78a6af1f
      Eric Blake 提交于
      * src/util/macvtap.c (delMacvtap): Fix documentation.
      78a6af1f
    • E
      maint: allow VPATH use of remote_protocol-structs · 3876e010
      Eric Blake 提交于
      * src/Makefile.am (remote_protocol-structs): Ensure file lives in srcdir.
      3876e010
    • E
      docs/Makefile.am: remove unnecessary subshells · 1c589120
      Eric Blake 提交于
      * docs/Makefile.am (ChangeLog.html.in, %.html.tmp, %.html)
      (html/index.html, $(devhelphtml)): Avoid spurious subshells.
      1c589120
    • E
      maint: avoid spurious output if program not present · 7cdf2663
      Eric Blake 提交于
      Some shells warn about missing programs before redirection;
      the idiomatic way to silence them is to run the program check
      inside a subshell, with the redirections outside the subshell.
      But a subshell is only needed in places where it is reasonable
      to expect the use of such a noisy shell in the first place.
      
      * src/Makefile.am (remote_protocol-structs): Use subshell, for
      FreeBSD 8.0 /bin/sh.
      * cfg.mk (sc_preprocessor_indentation): Avoid subshell, since the
      only users running cfg.mk can be assumed to have decent tools.
      7cdf2663
    • E
      storage_encryption: silence clang warning · 23958aed
      Eric Blake 提交于
      For printf("%*s",foo,bar), clang complains if foo is not int:
      
      warning: field width should have type 'int', but argument has
      type 'unsigned int' [-Wformat]
      
      * src/conf/storage_encryption_conf.c
      (virStorageEncryptionSecretFormat, virStorageEncryptionFormat):
      Use correct type.
      * src/conf/storage_encryption_conf.h (virStorageEncryptionFormat):
      Likewise.
      23958aed
  7. 08 5月, 2010 6 次提交
    • J
      help avoid accidental remote_protocol.x changes · 180d4b2b
      Jim Meyering 提交于
      Now, if you update remote_protocol.x without also updating
      remote_protocol-structs to match, then "make check" will fail.
      * src/Makefile.am (remote_protocol-structs): Extract list of
      structs and member names from remote_protocol.o.
      (check-local): Depend on it.
      * src/remote_protocol-structs: New file.
      180d4b2b
    • E
      mingw32-libvirt.spec: bring up to date · d0616e35
      Eric Blake 提交于
      Right now, mingw32-portablexdr is not available in Fedora, but is
      present in fedora-mingw.git.  With that package, plus
      redhat-rpm-config and this patch, it is once again possible to build
      mingw32-libvirt from a Fedora 12 host.
      
      * mingw32-libvirt.spec.in (__debug_install_post): Override.
      (%files): Mention recent additions.
      d0616e35
    • M
      Manually revert "Fix pthread related link error for virt-aa-helper" · cc04c4ca
      Matthias Bolte 提交于
      This reverts commit b5b8a6db.
      
      That commit was not necessary. The problem is fixed by commit
      0e9b3a26, but I didn't rebuild
      it properly after pulling in the commit and didn't notice it.
      cc04c4ca
    • E
      Fix a typo in docs · 563d7ee3
      Ersek Laszlo 提交于
      563d7ee3
    • E
      build: use LIBADD, not LDFLAGS, for adding libraries · 48445ccf
      Eric Blake 提交于
      Per automake, LDFLAGS is used early in the line, and LIBADD
      (libraries) or LDADD (programs) is used late.  On platforms like
      cygwin, without lazy linking, this order matters.  Therefore, libtool
      commands, -L, and similar should be in LDFLAGS, but -l should be in
      L*ADD.
      
      * src/Makefile.am (*_LDFLAGS): Move libraries...
      (*_LIBADD): ...to their LIBADD counterpart.
      48445ccf
    • E
      maint: whitespace cleanups · e6125e49
      Eric Blake 提交于
      * src/Makefile.am: Fix some space-tab issues.
      e6125e49
  8. 07 5月, 2010 5 次提交