Commit Graph

864 Commits

Author SHA1 Message Date
Osier Yang
99c8a5c8af docs: Add doc for video element
For backwards compatibility, if no <video> is set but there is a
<graphics> tag, then we add a default <video> according to the
guest type. Add docs to tell the user about this to not make
them confused. Especially if they remove the video (such as via
"virsh edit"), it will be surprised for them to see the video
element is still in domain XML.
2011-06-07 16:56:06 +08:00
Matthias Bolte
4bf1f33b7e docs: Make hvsupport.pl pick up the host device drivers
Annotate the ESX device driver dummy.

Refactor the udev and hal device driver strcuts to match the
common annotation pattern.
2011-06-06 10:45:59 +02:00
Daniel Veillard
2c5ded6e82 Release of libvirt-0.9.2
* configure.ac docs/news.html.in libvirt.spec.in: update for release
* po/*.po*: updated translations and regenerated
2011-06-06 11:46:37 +08:00
Neil Wilson
5b8d2e6d92 Correct 'cputune' documentation example.
Signed-off-by: Neil Wilson <neil@aldur.co.uk>
2011-06-03 08:40:51 -06:00
Eric Blake
a2f9bd5b80 build: fix VPATH build break from previous patch
Partial revert of commit c3c30d4de9.

* docs/Makefile.am (internals/%.html.tmp): Restore MKDIR_P; it is
needed for intermediate file after all.
Reported by Daniel P. Berrange.
2011-06-02 08:18:26 -06:00
Daniel P. Berrange
395793a8ec Add initial docs about the lock managers 2011-06-02 10:54:01 +01:00
Daniel P. Berrange
1ea83207c8 Support leases in guest XML and lock manager
A lock manager may operate in various modes. The direct mode of
operation is to obtain locks based on the resources associated
with devices in the XML. The indirect mode is where the app
creating the domain provides explicit leases for each resource
that needs to be locked. This XML extension allows for listing
resources in the XML

  <devices>
     ...
     <lease>
       <lockspace>somearea</lockspace>
       <key>thequickbrownfoxjumpsoverthelazydog</key>
       <target path='/some/lease/path' offset='23432'/>
     </lease>
     ...
  </devices>

The 'lockspace' is a unique identifier for the lockspace which
the lease is associated

The 'key' is a unique identifier for the resource associated
with the lease.

The 'target' is the file on disk where the leases are held.

* docs/schemas/domain.rng: Add lease schema
* src/conf/domain_conf.c, src/conf/domain_conf.h: parsing and
  formatting for leases
* tests/qemuxml2argvdata/qemuxml2argv-lease.args,
  tests/qemuxml2argvdata/qemuxml2argv-lease.xml,
  tests/qemuxml2xmltest.c: Test XML handling for leases
2011-06-02 10:54:00 +01:00
Eric Blake
c3c30d4de9 build: avoid corrupting / in RHEL 5
I noticed this while building from libvirt.git on RHEL 5.6:

Generating internals/command.html.tmp
mkdir: cannot create directory `/internals': Permission denied

If I had been building as root instead, this pollutes /.

Older autoconf lacks $(builddir), but it is rigorously equal to '.'
in newer autoconf, so we could use '$(MKDIR_P) internals' instead.

However, since internals/command.html is part of the tarball, we
_already_ build it in $(srcdir), not $(builddir) during VPATH
builds, so the mkdir is wasted effort!

* docs/Makefile.am (internals/%.html.tmp): Drop unused mkdir.
2011-06-01 15:26:13 -06:00
Matthias Bolte
43e8aeab43 apibuild: Restrict long usage to existing functions and structs
New APIs have to use long long instead of long.

Also make apibuild errors fatal.
2011-06-01 17:37:15 +02:00
Matthias Bolte
1767c8d79e Ignore backward compatibility macros in apibuild.py
This fixes this three warnings from the parser by allowing the parser
to ignore some macros in the same way as it can ignore functions.

Parsing ./../include/libvirt/libvirt.h
Misformatted macro comment for _virSchedParameter
 Expecting '* _virSchedParameter:' got '* virSchedParameter:'
Misformatted macro comment for _virBlkioParameter
 Expecting '* _virBlkioParameter:' got '* virBlkioParameter:'
Misformatted macro comment for _virMemoryParameter
 Expecting '* _virMemoryParameter:' got '* virMemoryParameter:'
2011-05-31 16:17:34 +02:00
Daniel P. Berrange
7cbbf61bd4 Ensure hvsupport.html.in is built before HTML validation
In a parallel make, HTML validation tries to run before
hvsupport.html.in has been built.

* docs/Makefile.am: List hvsupport.html.in as a built source
2011-05-31 12:20:29 +01:00
Michal Privoznik
b468f50477 schema: Add graphics element passwdValidTo attribute to schema
We support this in code, but forgot to add this to RNG schema as well.
According to documentation, the value match the dateTime type.
2011-05-26 16:23:07 +02:00
Daniel P. Berrange
58765b58a3 Fix QEMU -vnc arg generation with raw IPv6 addresses
Since -vnc uses ':' to separate the address from the port, raw
IPv6 addresses need to be escaped like [addr]:port

* src/qemu/qemu_command.c: Escape raw IPv6 addresses with []
* tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.args,
  tests/qemuxml2argvdata/qemuxml2argv-graphics-vnc.xml: Tweak
  to test Ipv6 escaping
* docs/schemas/domain.rng: Allow Ipv6 addresses, or hostnames
  in <graphics> listen attributes
2011-05-24 10:33:53 -04:00
Alon Levy
bb1c5423b9 spice: support streaming-video parameter
This adds a streaming-video=filter|all|off attribute. It is used to change
the behavior of video stream detection in spice, the default is filter (the
default for libvirt is not to specify it - the actual default is defined in
libspice-server.so).

Usage:

    <graphics type='spice' autoport='yes'>
      <streaming mode='off'/>
    </graphics>

Tested with the above and with tests/qemuxml2argvtest.

Signed-off-by: Alon Levy <alevy@redhat.com>
2011-05-23 20:53:59 -06:00
Stefan Berger
fcb0e8c227 nwfilter: enable filtering of gratuitous ARP packets
This patch enables filtering of gratuitous ARP packets using the following XML:

<rule action='accept' direction='in' priority='425'>
<arp gratuitous='true'/>
</rule>
2011-05-23 19:41:18 -04:00
Osier Yang
2d3fac19e1 docs: Fix error syntax of vcpupin example XML
Lacks of "/", push this directly in trivial rule.
2011-05-21 17:12:23 +08:00
Dirk Herrendorefer
5252a06d65 Add support for 'passthru' mode for direct network interfaces
starting with kernel 2.6.38 macvtap supports a 'passthru' mode for
attaching virtual functions of a SRIOV capable network card directly to a VM.
This patch adds the capability to configure such a device.

Signed-off-by: Dirk Herrendoerfer <d.herrendoerfer@herrendoerfer.name>
2011-05-18 08:15:08 -06:00
Eric Blake
aceb31aa80 maint: mark perl script executable
* docs/hvsupport.pl: Add execute bit.
2011-05-16 10:09:36 -06:00
Daniel P. Berrange
65043d2dff Introduce yet another migration version in API.
Migration just seems to go from bad to worse. We already had to
introduce a second migration protocol when adding the QEMU driver,
since the one from Xen was insufficiently flexible to cope with
passing the data the QEMU driver required.

It turns out that this protocol still has some flaws that we
need to address. The current sequence is

 *  Src: DumpXML
          - Generate XML to pass to dst

 *  Dst: Prepare
          - Get ready to accept incoming VM
          - Generate optional cookie to pass to src

 *  Src: Perform
          - Start migration and wait for send completion
          - Kill off VM if successful, resume if failed

 *  Dst: Finish
          - Wait for recv completion and check status
          - Kill off VM if unsuccessful

The problems with this are:

 - Since the first step is a generic 'DumpXML' call, we can't
   add in other migration specific data. eg, we can't include
   any VM lease data from lock manager plugins
 - Since the first step is a generic 'DumpXML' call, we can't
   emit any 'migration begin' event on the source, or have
   any hook that runs right at the start of the process
 - Since there is no final step on the source, if the Finish
   method fails to receive all migration data & has to kill
   the VM, then there's no way to resume the original VM
   on the source

This patch attempts to introduce a version 3 that uses the
improved 5 step sequence

 *  Src: Begin
          - Generate XML to pass to dst
          - Generate optional cookie to pass to dst

 *  Dst: Prepare
          - Get ready to accept incoming VM
          - Generate optional cookie to pass to src

 *  Src: Perform
          - Start migration and wait for send completion
          - Generate optional cookie to pass to dst

 *  Dst: Finish
          - Wait for recv completion and check status
          - Kill off VM if failed, resume if success
          - Generate optional cookie to pass to src

 *  Src: Confirm
          - Kill off VM if success, resume if failed

The API is designed to allow both input and output cookies
in all methods where applicable. This lets us pass around
arbitrary extra driver specific data between src & dst during
migration. Combined with the extra 'Begin' method this lets
us pass lease information from source to dst at the start of
migration

Moving the killing of the source VM out of Perform and
into Confirm, means we can now recover if the dst host
can't successfully Finish receiving migration data.
2011-05-16 15:09:19 +01:00
Daniel P. Berrange
4ffc6d173a Automatically generate the hvsupport.html.in file from source files
The hvsupport.html.in file is forever out of date. By annotating
the driver struct tables in each driver with version information,
we can auto-generate the hvsupport.html.in file. Annotating the
drivers will be mandatory for new patches, ensuring hvsupport.html.in
is never out of date again.

* docs/hvsupport.html.in: Delete
* hvsupport.pl: Script to generate hvsupport.html.in
* Makefile.am: Autogenerate hvsupport.html.in
2011-05-16 14:20:52 +01:00
Osier Yang
81cfe71998 docs: Fix documentation for cputune parameters
This re-adds the example section originally written by Osier Yang,
and indicates the version in which the cputune parameters became
available in libvirt.

Signed-off-by: Igor Serebryany <igor47@moomers.org>
2011-05-12 18:48:23 +08:00
Eric Blake
2c28717522 docs: avoid double 'the'
* docs/testsuites.html.in: Keep 'make syntax-check' happy.
2011-05-11 08:18:04 -06:00
Daniel Veillard
ef82932bb5 Add documentation about test suites
Create a new top level entry, add a new page listing the 3
test suites, and then one page for the TCK and one page for
libvirt-test-API
2011-05-11 19:18:38 +08:00
Doug Goldstein
fa4732724e docs: updates to CA cert and client cert/key info
Update the documentation to mention that the CA certificate and the
client cert/key pair can come from the user's location or the global
location independent of each other.

Signed-off-by: Doug Goldstein <cardoe@gentoo.org>
2011-05-10 14:56:53 -06:00
Eric Blake
68ea80cfdd maint: rename virBufferVSprintf to virBufferAsprintf
We already have virAsprintf, so picking a similar name helps for
seeing a similar purpose.  Furthermore, the prefix V before printf
generally implies 'va_list', even though this variant was '...', and
the old name got in the way of adding a new va_list version.

global rename performed with:

$ git grep -l virBufferVSprintf \
  | xargs -L1 sed -i 's/virBufferVSprintf/virBufferAsprintf/g'

then revert the changes in ChangeLog-old.
2011-05-05 13:47:40 -06:00
Cole Robinson
79b914e8f6 docs: <filesystem> attr is 'accessmode', not 'mode' 2011-05-05 15:28:23 -04:00
Daniel Veillard
9b889aacef Release of libvirt-0.9.1
* configure.ac libvirt.spec.in docs/news.html.in: update and document
  the release
* po/*.po*: update localizations for german, polish, spanish, ukrainian
  and vietnamese coming from transifex, regenerate
2011-05-05 11:25:13 +08:00
Gerhard Stenzel
170f2a8747 fix missing VLAN id for Qbg example
For IEEE 802.1Qbg, it is necessary to use a VLAN interface.
vepa itself does not require a VLAN interface.

Signed-off-by: Gerhard Stenzel <stenzel at de.ibm.com>
2011-05-02 09:13:54 -06:00
Cole Robinson
41a7835fa0 docs: Document <filesystem> device
Tried to dredge through old changelogs and commits to come up with it, so
may not be completely accurate.

v2:
Drop ambiguous 'containers'
Use same mail archive for all links
2011-04-29 14:35:23 -04:00
Stefan Berger
973b681bdf nwfilter: no support for direct type of interface
Ebtables filtering doesn't work on macvtap device. Remove support for direct type of interface.
2011-04-19 16:23:59 -04:00
Michal Privoznik
abb1570eac Spice: support audio, images and stream compression
This extends the SPICE XML to allow variable compression settings for audio,
images and streaming:
    <graphics type='spice' port='5901' tlsPort='-1' autoport='yes'>
        <image compression='auto_glz'/>
        <jpeg compression='auto'/>
        <zlib compression='auto'/>
        <playback compression='on'/>
    </graphics>

All new elements are optional.
2011-04-14 10:23:59 -06:00
Matthias Bolte
1ef5a3d37e docs: Serial and parallel device target ports actually start from 0
Reported by Igor Galić
2011-04-14 16:36:25 +02:00
Eric Blake
99fa30804b maint: fix grammar errors
Jim Meyering recently improved gnulib to catch various grammar
errors during 'make syntax-check'.

* .gnulib: Update to latest, for syntax-check improvements.
* include/libvirt/libvirt.h.in (virConnectAuthCallbackPtr): Use
cannot rather than two words.
* src/driver.c: Likewise.
* src/driver.h (VIR_SECRET_GET_VALUE_INTERNAL_CALL): Likewise.
* src/remote/remote_driver.c (initialize_gnutls): Likewise.
* src/util/pci.c (pciBindDeviceToStub): Likewise.
* src/storage/storage_backend.c (virStorageBackendCreateQemuImg):
Likewise.
(virStorageBackendUpdateVolTargetInfoFD): Avoid doubled word.
* docs/formatdomain.html.in: Likewise.
* src/qemu/qemu_process.c (qemuProcessStart): Likewise.
* cfg.mk (exclude_file_name_regexp--sc_prohibit_can_not)
(exclude_file_name_regexp--sc_prohibit_doubled_word): Exclude
existing translation problems.
2011-04-12 09:06:14 -06:00
Stefan Berger
6ab24feb44 nwfilters: support for TCP flags evaluation
This patch adds support for the evaluation of TCP flags in nwfilters.

It adds documentation to the web page and extends the tests as well.
Also, the nwfilter schema is extended.

The following are some example for rules using the tcp flags:

<rule action='accept' direction='in'>
    <tcp state='NONE' flags='SYN/ALL' dsptportstart='80'/>
</rule>
<rule action='drop' direction='in'>
    <tcp state='NONE' flags='SYN/ALL'/>
</rule>
2011-04-07 20:13:38 -04:00
Laine Stump
f25d064ead docs: add an IPv6 address to network XML examples
It was just pointed out that, although I added documentation for the
IPv6 additions to the network XML, I neglected to use those additions
in the examples. This patch adds an IPv6 address to each of the
examples except for the "default" network, since that is a faithful
reproduction of the default network config that's automatically
installed, which doesn't include any IPv6 address (for good reason -
because there is no such thing as IPv6 NAT, there is no one IPv6
address that would work for all installations).
2011-04-07 12:51:47 -04:00
Daniel Veillard
d17e438ad3 Release of libvirt-0.9.0
* configure.ac docs/news.html.in libvirt.spec.in: update for the release
* po/*.po*: update polish translation and regenerate
2011-04-04 20:15:45 +08:00
Eric Blake
d958874780 docs: fix typo
* docs/formatdomain.html.in: Fix KVM name.
2011-04-01 16:18:18 -06:00
Eric Blake
b5ec89d955 docs: correct invalid xml
* docs/internals.html.in: Fix xml errors.
* docs/formatstorageencryption.html.in: Likewise.
* docs/drvesx.html.in: Likewise.
* docs/archnetwork.html.in: Likewise.
* docs/logging.html.in: Likewise.
* docs/drvvmware.html.in: Likewise.
* docs/api.html.in: Likewise.
* docs/formatnwfilter.html.in: Likewise.
* docs/formatdomain.html.in: Likewise.
* docs/windows.html.in: Likewise.
2011-04-01 16:03:11 -06:00
Jiri Denemark
1e8f20799c virsh: Fix documentation for memtune command
Commit 78ba748ef1 claims to fix
documentation for swap_hard_limit virsh memtune option but it only fixes
documentation in formatdomain.html and libvirt.h. This patch completes
the task by fixing "virsh help memtune" output and memtune section of
virsh man page.
2011-04-01 11:31:10 +02:00
Michal Privoznik
51434d3bef Fix several formatting mistakes in doc 2011-03-31 14:36:19 -06:00
Eric Blake
06732e1a7d docs: mention C89 syntax preferences
* docs/hacking.html.in (Code formatting): Document that // comment
and declaration-after-statement are discouraged.
* HACKING: Regenerate.
2011-03-30 13:51:22 -06:00
Daniel Veillard
6c8f24751e The next release is 0.9.0 not 0.8.9
Fix this which went into documentation
2011-03-30 21:30:54 +08:00
Osier Yang
6b3644202a cputune: Add document for cputune XML
v1 - v3:
  * More clear document for "cpu shares", adopted suggestions from
    Matthias Bottle and Daniel Veillard.
2011-03-29 22:13:45 +08:00
Osier Yang
e3ea882821 cputune: Add XML schema for cputune xml
v1 - v2:
  * Remove upper limit of cpu shares. (Suggested by Matthias Bottle)
2011-03-29 22:13:45 +08:00
Eric Blake
ef701fd8cb docs: document recent hook additions
* src/qemu/qemu_process.c (qemuProcessStart, qemuProcessStop): Fix
typos.
* docs/hooks.html.in: Document 'prepare' and 'release' hooks.
2011-03-28 09:51:04 -06:00
Daniel P. Berrange
4591df766d Remove the Open Nebula driver
The Open Nebula driver has been unmaintained since it was first
introduced. The only commits have been for tree-wide cleanups.
It also has a major design flaw, in that it only knows about guests
that it has created itself, which makes it of very limited use.

Discussions wrt evolution of the VMWare ESX driver, concluded that
it should limit itself to single-node ESX operation and not try to
manage the multi-node architecture of VirtualCenter. Open Nebula
is a cluster like Virtual Center, not a single node system, so
the same reasoning applies.

The DeltaCloud project includes an Open Nebula driver and is a much
better fit architecturally, since it is explicitly targetting the
distributed multihost cluster scenario.

Thus this patch deletes the libvirt Open Nebula driver with the
recommendation that people use DeltaCloud for managing it instead.

* configure.ac: Remove probe for xmlrpc & --with-one arg
* daemon/Makefile.am, daemon/libvirtd.c, src/Makefile.am: Remove
  ONE driver build
* src/opennebula/one_client.c, src/opennebula/one_client.h,
  src/opennebula/one_conf.c, src/opennebula/one_conf.h,
  src/opennebula/one_driver.c, src/opennebula/one_driver.c: Delete
  files
* autobuild.sh, libvirt.spec.in, mingw32-libvirt.spec.in: Remove
  build rules for Open Nebula
* docs/drivers.html.in, docs/sitemap.html.in: Remove reference
  to OpenNebula
* docs/drvone.html.in: Delete file
2011-03-28 14:09:11 +01:00
Daniel Veillard
50d8ad828d Update on the goal page
Some things to note in this patch:
   - we do extend libvirt scope beyond purely managing domains, there is
     already a number of blocks which are here as helpr functions to
     manage the resources on the host.
   - we are expanding in the direction of libvirt being sufficient to do
     most of the management on the Host (but within the limits of the need
     for virtualization, e.g. managing users on the host is out of scope)
   - we don't require anymore APIs to be supported by multiple
     hypervisors to get in, it's already the case in practice, but we
     should still make sure the semantic of those APIs are clear. We
     added quite a bit for QEmu, but for example I saw on IRC that VBox
     could emulate a network unplug/replug on a domain interface, and
     that would be a good addition even if a priori no other hypervisor
     supports it.
   - Make clear that all libvirt APIs are available remotely, which is
     key to use libvirt for building management tools.
   - link the goal page from the project main page

As for libvirt project directions, I think it just reflects the natural
evolution in the last couple of years. We are less hypervisor agnostic
and extending in the Host management. Clearly there is interest in
making sure libvirt is complete in term of features for the hypervisors
supported, especially the ones like KVM or LXC which don't really have
integrated management library.

* docs/goals.html.in: update the goals page
* docs/index.html.in: link it from the top page
2011-03-28 10:40:24 +08:00
Cole Robinson
4179f8e988 docs: Document first release with spice and qxl 2011-03-21 11:05:53 -04:00
Osier Yang
918c8193e2 doc: Add schema definition for imagelabel
<imagelable> is not generated by running domain, actually we parse
it in src/conf/domain_conf.c, this patch is to fix it, otherwise any
validation (virt-xml-validate) on the domain xml dumped from shutoff
domain containing <imagelable> will fail.

* docs/schemas/domain.rng
2011-03-21 16:30:06 +08:00
Daniel Veillard
08ddbe61f6 Improve logging documentation including the debug buffer
* docs/logging.html.in: document the fact that starting from
  0.9.0 the server logs goes to libvirtd.log instead of syslog
  by default, describe the debug buffer, restructure the page
  and add a couple more examples
2011-03-18 10:06:31 +08:00