1. 03 8月, 2012 5 次提交
    • O
      qemu: Allow to attach/detach controller device persistently · ed1e711b
      Osier Yang 提交于
      * src/conf/domain_conf.c:
        - Add virDomainControllerFind to find controller device by type
          and index.
        - Add virDomainControllerRemove to remove the controller device
          from maintained controler list.
      
      * src/conf/domain_conf.h:
        - Declare the two new helpers.
      
      * src/libvirt_private.syms:
        - Expose private symbols for the two new helpers.
      
      * src/qemu/qemu_driver.c:
        - Support attach/detach controller device persistently
      
      * src/qemu/qemu_hotplug.c:
        - Use the two helpers to simplify the codes.
      ed1e711b
    • H
      Added timestamps to storage volumes · 7383c1d7
      Hendrik Schwartke 提交于
      The access, birth, modification and change times are added to
      storage volumes and corresponding xml representations.  This
      shows up in the XML in this format:
      
      <timestamps>
        <atime>1341933637.027319099</atime>
        <mtime>1341933637.027319099</mtime>
      </timestamps>
      Signed-off-by: NEric Blake <eblake@redhat.com>
      7383c1d7
    • J
      Update xml schemas according to libvirt source · 37a10129
      Ján Tomko 提交于
      capability.rng: Guest features can be in any order.
      nodedev.rng: Added <driver> element, <capability> phys_function and
      virt_functions for PCI devices.
      storagepool.rng: Owner or group ID can be -1.
      
      schema tests: New capabilities and nodedev files; changed owner and
      group to -1 in pool-dir.xml.
      storage_conf: Print uid_t and gid_t as signed to storage pool XML.
      37a10129
    • E
      build: add stubs so mdns code can be unconditionally compiled · 1f6f723c
      Eric Blake 提交于
      The recent changes to the testsuite to validate exported symbols
      flushed out a case of unconditionally exporting symbols that
      were only conditionally compiled under HAVE_AVAHI.
      
      * src/Makefile.am (libvirt_net_rpc_server_la_SOURCES): Compile
      virnetservermdns unconditionally.
      * configure.ac (HAVE_AVAHI): Drop unused automake conditional.
      * src/rpc/virnetservermdns.c: Add fallbacks when Avahi is not
      present.
      1f6f723c
    • M
      virsh: Switch to close callback · 54b63347
      Michal Privoznik 提交于
      Since we've introduced close callbacks we can drop this SIGINT magic
      (which doesn't work now neither) and fully utilize the new feature.
      54b63347
  2. 02 8月, 2012 15 次提交
    • M
      qemu: Fix typo in qemuDomainModifyDeviceFlags · e94c0a09
      Michal Privoznik 提交于
      One of our latest commits fbe87126 introduced this nasty typo:
      func(vmdef, ...); where func() dereference vmdef->ncontrollers,
      and vmdef was initialized to NULL. This leaves us with unconditional
      immediate segfault. It should be vm->def instead.
      e94c0a09
    • J
      daemon: Portable auto-detection of driver module directory · b5c5ad36
      Jiri Denemark 提交于
      When running libvirtd from a build directory on a system with unmodified
      libtool, libvirtd's binary is not renamed as "lt-libvirtd". Check for
      "/daemon/.libs/libvirtd" in addition to "lt-libvirtd".
      b5c5ad36
    • J
      build: Rename security manager library · d3084c2a
      Jiri Denemark 提交于
      Security manager is not a dynamically loadable driver. Let's avoid the
      confusion by renaming libvirt_driver_security library as
      libvirt_security_manager.
      d3084c2a
    • J
      build: Link security manager into libvirt.so · 2f2ca021
      Jiri Denemark 提交于
      Security manager is not a dynamically loadable driver, it's a common
      infrastructure similar to util, conf, cpu, etc. used by individual
      drivers. Such code is allowed to be linked into libvirt.so.
      
      This reverts commit ec5b7bd2 and most of
      aae5cfb6.
      
      This patch is supposed to fix virdrivermoduletest failures for qemu and
      lxc drivers as well as libvirtd's ability to load qemu and lxc drivers.
      2f2ca021
    • D
      Avoid clash of base64 symbols · 7a054e99
      Daniel P. Berrange 提交于
      On Debian/Ubuntu, one of the libraries libvirt (indirectly) links
      with exports a symbol named 'base64_encode'. This takes precedence
      over GNULIB's base64_encode function during linking. Unfortunately
      they of course have different API semantics. To avoid this problem
      use a few #defines in config.h to rename the GNULIB provided
      function to have a 'libvirt_gl_' prefix
      7a054e99
    • E
      build: commit to 0.10.0 release naming · 1d170d3f
      Eric Blake 提交于
      With 0.10.0-rc0 out the door, we are committed to the next version
      number.
      
      * src/libvirt_public.syms (LIBVIRT_0.9.14): Rename...
      (LIBVIRT_0.10.0): ...to this.
      * docs/formatdomain.html.in: Fix fallout.
      * src/openvz/openvz_driver.c (openvzDriver): Likewise.
      * src/remote/remote_driver.c (remote_driver): Likewise.
      1d170d3f
    • D
      Remove unused uuidstr variable from datatypes.c · 03be7ab5
      Daniel P. Berrange 提交于
      Several APIs in src/datatypes.c were formatting an UUID to a
      uuidstr variable and then not using it.
      03be7ab5
    • D
      Rewrite virAtomic APIs using GLib's atomic ops code · 0c9fd4cf
      Daniel P. Berrange 提交于
      There are a few issues with the current virAtomic APIs
      
       - They require use of a virAtomicInt struct instead of a plain
         int type
       - Several of the methods do not implement memory barriers
       - The methods do not implement compiler re-ordering barriers
       - There is no Win32 native impl
      
      The GLib library has a nice LGPLv2+ licensed impl of atomic
      ops that works with GCC, Win32, or pthreads.h that addresses
      all these problems. The main downside to their code is that
      the pthreads impl uses a single global mutex, instead of
      a per-variable mutex. Given that it does have a Win32 impl
      though, we don't expect anyone to seriously use the pthread.h
      impl, so this downside is not significant.
      
      * .gitignore: Ignore test case
      * configure.ac: Check for which atomic ops impl to use
      * src/Makefile.am: Add viratomic.c
      * src/nwfilter/nwfilter_dhcpsnoop.c: Switch to new atomic
        ops APIs and plain int datatype
      * src/util/viratomic.h: inline impls of all atomic ops
        for GCC, Win32 and pthreads
      * src/util/viratomic.c: Global pthreads mutex for atomic
        ops
      * tests/viratomictest.c: Test validate to validate safety
        of atomic ops.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      0c9fd4cf
    • D
      Remove manual one-shot global initializers · b49890de
      Daniel P. Berrange 提交于
      Remove the use of a manually run virLogStartup and
      virNodeSuspendInitialize methods. Instead make sure they
      are automatically run using VIR_ONCE_GLOBAL_INIT
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      b49890de
    • P
      qemu: Add support for "none" USB controller · fbe87126
      Peter Krempa 提交于
      This patch enables the "none" USB controller for qemu guests and adds
      valdiation on hot-plugged devices if the guest has USB disabled.
      
      This patch also adds a set of tests to check parsing of domain XMLs that
      use the "none" controller and some forbidden situations concerning it.
      fbe87126
    • P
      domain_conf: Add helpers to verify if device configuration is valid · 317badb2
      Peter Krempa 提交于
      This patch adds helpers that validate domain's device configuration.
      This will be needed later on to verify devices being hot-plugged to
      guests. If the guest has no USB bus, then it's not valid to plug a USB
      device to that guest.
      317badb2
    • P
      domain_conf: Add USB controler model "none" · 09251897
      Peter Krempa 提交于
      Libvirt adds a USB controller to the guest even if the user does not
      specify any in the XML. This is due to back-compat reasons.
      
      To allow disabling USB for a guest this patch adds a new USB controller
      type "none" that disables USB support for the guest.
      09251897
    • O
      Fix indentions · 7ee395a8
      Osier Yang 提交于
      Some of the macros use tab, while the left use spaces, this patch
      change it to always use the spaces. And a few aligning fixes.
      7ee395a8
    • G
      storage: netfs and iscsi need option srcSpec for resource discovery · 40570488
      Guannan Ren 提交于
      The option 'srcSpec' to virsh command find-storage-pool-sources
      is optional for logical type of storage pool, but mandatory for
      netfs and iscsi type.
      When missing the option for netfs and iscsi, libvirt reports XML
      parsing error due to null string option srcSpec.
      
      before
      error: Failed to find any netfs pool sources
      error: (storage_source_specification):1: Document is empty
      (null)
      
      after:
      error: pool type 'iscsi' requires option --srcSpec for source discovery
      40570488
    • G
      57fb8d53
  3. 01 8月, 2012 18 次提交
    • M
      gitignore: Reorder alphabetically · 6c0cf395
      Michal Privoznik 提交于
      One of our latest patches added some files to .gitignore. However,
      not in the right place leaving the file not sorted. Since my git
      is set up to sort these files contents, fix this issue as it keeps
      showing up in git status.
      6c0cf395
    • J
      spec: Remove extra () with return statement · 1371cc52
      Jiri Denemark 提交于
      1371cc52
    • J
      build: Link security driver into daemon · ec5b7bd2
      Jiri Denemark 提交于
      Commit aae5cfb6 removed security driver
      from libvirt_la but forgot to link it into libvirtd in case libvirt is
      built without modules.
      ec5b7bd2
    • D
      Fix rpm build failures · 27df13f4
      Daniel Veillard 提交于
      The 'make check' was rebuilding the binaries just overrided,
      so for more safety also override the C program
      Also daemon-conf isn't built anymore so remove it from the list
      27df13f4
    • D
      Add missing parallels_utils.h to Makefile.am · 04cd70bf
      Daniel Veillard 提交于
      Otherwise the file is missing from the dist tarball and distcheck fails
      04cd70bf
    • D
      parallels: implement VM creation · 7024ddfc
      Dmitry Guryanov 提交于
      To create a new VM in Parallels Clud Server we should issue
      "prlctl create" command, and give path to the directory,
      where VM should be created. VM's storage will be in that
      directory later. So in this first version find out location
      of first VM's hard disk and create VM there.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      7024ddfc
    • D
      parallels: add storage driver · aa296e6c
      Dmitry Guryanov 提交于
      Parallels Cloud Server has one serious discrepancy with libvirt:
      libvirt stores domain configuration files in one place, and storage
      files in other places (with the API of storage pools and storage volumes).
      Parallels Cloud Server stores all domain data in a single directory,
      for example, you may have domain with name fedora-15, which will be
      located in '/var/parallels/fedora-15.pvm', and it's hard disk image will be
      in '/var/parallels/fedora-15.pvm/harddisk1.hdd'.
      
      I've decided to create storage driver, which produces pseudo-volumes
      (xml files with volume description), and they will be 'converted' to
      real disk images after attaching to a VM.
      
      So if someone creates VM with one hard disk using virt-manager,
      at first virt-manager creates a new volume, and then defines a
      domain. We can lookup a volume by path in XML domain definition
      and find out location of new domain and size of its hard disk.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      aa296e6c
    • D
      parallels: implement virDomainDefineXML operation for existing domains · e356f610
      Dmitry Guryanov 提交于
      Add parallelsDomainDefineXML function, it works only for existing
      domains for the present.
      
      It's too hard to convert libvirt's XML domain configuration into
      Parallel's one, so I've decided to compare virDomainDef structures:
      current domain definition and the one created from XML, given to
      the function. And change only different parameters.
      
      Currently only name, description, number of cpus, memory amount
      and video memory can be changed.
      
      Video device and console added, because libvirt supposes that
      VM must always have one video device, if there are some
      graphics and one console.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      e356f610
    • D
      parallels: add support of VNC remote display · d71145ad
      Dmitry Guryanov 提交于
      Add support for reading VNC parameters of the VM.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      d71145ad
    • D
      parallels: get info about serial ports · e172cd50
      Dmitry Guryanov 提交于
      Add support of collecting information about serial
      ports. This change is needed mostly as an example,
      support of other devices will be added later.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      e172cd50
    • D
      parallels: implement functions for domain life cycle management · 0740e1bb
      Dmitry Guryanov 提交于
      Add functions for create/shutdown/destroy and suspend/resume domain.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      0740e1bb
    • D
      parallels: add functions to list domains and get info · e93c33a9
      Dmitry Guryanov 提交于
      Parallels driver is 'stateless', like vmware or openvz drivers.
      It collects information about domains during startup using
      command-line utility prlctl. VMs in Parallels are identified by UUIDs
      or unique names, which can be used as respective fields in
      virDomainDef structure. Currently only basic info, like
      description, virtual cpus number and memory amount, is implemented.
      Querying devices information will be added in the next patches.
      
      Parallels doesn't support non-persistent domains - you can't run
      a domain having only disk image, it must always be registered
      in system.
      
      Functions for querying domain info have been just copied from
      test driver with some changes - they extract needed data from
      previously created list of virDomainObj objects.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      e93c33a9
    • D
      add function virCommandNewVAList · 4033df7e
      Dmitry Guryanov 提交于
      Add function virCommandNewVAList which is equivalent to the
      virCommandNewArgList but with va_list instead of a variable number
      of arguments.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      4033df7e
    • D
      parallels: add driver skeleton · cafc26ff
      Dmitry Guryanov 提交于
      Parallels Cloud Server is a cloud-ready virtualization
      solution that allows users to simultaneously run multiple virtual
      machines and containers on the same physical server.
      
      More information can be found here: http://www.parallels.com/products/pcs/
      Also beta version of Parallels Cloud Server can be downloaded there.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      cafc26ff
    • M
      qemu: syntax fix · 2beed2da
      Marc-André Lureau 提交于
      Pushed without ack, under the trivial rule.
      2beed2da
    • D
      Only perform symbol check against libvirt.so · 8c63ff39
      Daniel P. Berrange 提交于
      The 'check-symfile' test case was checking the contents of
      libvirt.syms against libvirt.so + all of libvirt_driver_XXX.so
      This was in fact bogus - libvirt.syms should only refer to
      stuff in libvirt.so, but it had some symbols from the various
      driver modules in it too. Now that libvirt.syms has been
      fixed, the check-symfile test can be simplified to only
      consider libvirt.so
      8c63ff39
    • D
      Don't link nwfilter or secrets driver to libvirt.so · aae5cfb6
      Daniel P. Berrange 提交于
      The nwfilter and secrets drivers are both stateful and are already
      linked directly to libvirtd. Linking them to libvirt.so is thus
      wrong, likewise exporting their symbols in libvirt.so is wrong
      aae5cfb6
    • D
      Remove bogus libvirt_network.syms file · 5830c72e
      Daniel P. Berrange 提交于
      The network driver is stateful, so it is linked directly to libvirtd,
      rather than libvirt.so. Thus there are no network symbols to be exported
      in libvirt.so, and libvirt_network.syms can be deleted
      5830c72e
  4. 31 7月, 2012 2 次提交