Commit Graph

506 Commits

Author SHA1 Message Date
Diego Elio Pettenò
25f7fa0583 Small change of RNG syntax for domain
* docs/schemas/domain.rng: As trang seems to bug with <optional><oneOrMore>
  replace it with <zeroOrMore>
2009-12-11 08:46:11 +01:00
Diego Elio Pettenò
51ea18a844 Fix a wellformedness problem in secret.rng
* docs/schemas/secret.rng: ref tag for usagevolume wasn't closed
2009-12-10 17:03:47 +01:00
Matthias Bolte
1b9d074493 Add virBufferFreeAndReset() and replace free()
Replace free(virBufferContentAndReset()) with virBufferFreeAndReset().
Update documentation and replace all remaining calls to free() with
calls to VIR_FREE(). Also add missing calls to virBufferFreeAndReset()
and virReportOOMError() in OOM error cases.
2009-12-10 00:00:50 +01:00
Richard Jones
16387171c0 Update location of C# bindings. 2009-12-09 12:51:35 +00:00
Daniel Veillard
604c70fd5d Fix the news file non-ascii characters
by adding an explicit HTML encoding meta description
2009-12-09 11:16:48 +01:00
Matthias Bolte
10616d7a1e Add missing commas to the 0.7.4 news section 2009-12-08 23:39:12 +01:00
Daniel Veillard
5362edd442 Change generated HTML to UTF-8 encoding
* docs/ChangeLog.xsl docs/newapi.xsl docs/site.xsl: change all
  stylesheets to output UTF-8 HTML instead of ISO Latin 1 which was
  breaking on some people names.
2009-12-08 16:09:33 +01:00
Daniel Veillard
816d79143b Fix missing background color 2009-12-03 15:27:24 +01:00
Daniel P. Berrange
e15bf04465 Fix typo in QEMU driver webpage
* docs/drvqemu.html.in: Fix typo describing URI driver protocol
2009-11-30 15:21:21 +00:00
Daniel P. Berrange
e7c78b0a94 Support QEMU's virtual FAT block device driver
Introduce a new type="dir"  mode for <disks> that allows use of
QEMU's  virtual FAT block device driver. eg

    <disk type='dir' device='floppy'>
      <source dir='/tmp/test'/>
      <target dev='fda' bus='fdc'/>
      <readonly/>
    </disk>

gets turned into

  -drive file=fat:floppy:/tmp/test,if=floppy,index=0

Only read-only disks are supported with virtual FAT mode

* src/conf/domain_conf.c, src/conf/domain_conf.h: Add type="dir"
* docs/schemas/domain.rng: Document new disk type
* src/xen/xend_internal.c, src/xen/xm_internal.c: Raise error for
  unsupported disk types
* tests/qemuxml2argvdata/qemuxml2argv-disk-cdrom-empty.args: Fix
  empty disk file handling
* tests/qemuxml2argvdata/qemuxml2argv-disk-drive-fat.args,
  tests/qemuxml2argvdata/qemuxml2argv-disk-drive-fat.xml,
  tests/qemuxml2argvdata/qemuxml2argv-floppy-drive-fat.args,
  tests/qemuxml2argvdata/qemuxml2argv-floppy-drive-fat.xml
  tests/qemuxml2argvtest.c: Test QEMU vitual FAT driver
* src/qemu/qemu_conf.c: Support generating fat:/some/dir type
  disk args
* src/security/security_selinux.c: Temporarily skip labelling
  of directory based disks
2009-11-23 12:17:16 +00:00
Dan Kenigsberg
79d2c5831a Fix news.html validation 2009-11-22 20:08:54 +01:00
Daniel Veillard
040e80f7e6 Release of libvirt-0.7.4
0.7.3 was broken

* configure.in docs/news.html.in: release of 0.7.4
* configure.in libvirt.spec.in: require netcf >= 0.1.4
* src/Makefile.am: node_device/node_device_udev.h was missing from
  NODE_DEVICE_DRIVER_UDEV_SOURCES breaking compilation on platforms with
  udev
2009-11-20 19:43:59 +01:00
Daniel Veillard
b8d4b6bec9 Release of libvirt-0.7.3
* configure.in docs/news.html.in libvirt.spec.in: describe new release
* po/*.po*: regenerate
2009-11-20 17:31:13 +01:00
Cole Robinson
eb81396863 Document overriding domain interface target
* docs/formatdomain.html.in: document that vnet and vif are reserved
  names and will be ignored if manually specified.
2009-11-20 16:25:58 +01:00
Daniel Veillard
2060a0a43e 512069 fix domain XML schemas for backward compatibility
For backward compatibility we used to add the tty path as
a tty attribute on console of type pty, duplicating the value
now found in source/@path, but the Relax-NG grammar wasn't
extended for this
    <console type='pty' tty='/dev/pts/8'>
      <source path='/dev/pts/8'/>
      <target port='0'/>
    </console>

* docs/schemas/domain.rng: allow an optional tty attribute
  containing a devicePath
2009-11-20 15:48:19 +01:00
Matthias Bolte
afec7cf1ff Whitespace cleanup for pre-tags on the website 2009-11-16 22:42:13 +01:00
Matthias Bolte
57dbe08e74 esx: Add documentation to the website
* docs/drivers.html.in: list the ESX driver
* docs/drvesx.html.in: the new ESX driver documentation
* docs/hvsupport.html.in: add the ESX driver to the matrix
* docs/index.html.in, docs/sitemap.html.in: list the ESX driver
* src/esx/esx_driver.c: fix and cleanup some comments
2009-11-15 15:21:13 +01:00
Matthias Bolte
dad6ecc6bf Change DTD references to use public instead of system identifier
Debian's /etc/xml/catalog doesn't contain system identifiers, so use
public identifiers instead.

* docs/Makefile.am: use public instead of system identifier
* docs/site.xsl: use matching public identifier
2009-11-15 15:13:03 +01:00
Matthew Booth
ddfd21f815 Small indentation cleanup of domain schema 2009-11-13 16:03:43 +01:00
Matthew Booth
457a10d91d Add documentation for <channel> domain element
* src/formatdomain.html.in: Add <channel> element documentation
2009-11-09 15:38:20 +01:00
Matthew Booth
624f0c68bc Separate character device doc guest and host parts
* docs/formatdomain.html.in: refactors the existing character device
  documentation to make it explicit which directives configure the guest
  interface, and which configure the host interface.
2009-11-09 15:35:21 +01:00
Matthew Booth
c6d5ac174e Cleanup whitespace in docs
This patch is the result of running the following command in the docs
directory: sed -i 's/\t/        /g; s/\s*$//' *.html.in

* docs/*.html.in:convert tabs into 8 spaces and remove trailing whitespace
2009-11-06 16:05:18 +01:00
Paolo Bonzini
649bcd72fe Add sentinel attribute for NULL terminated arg lists
* src/internal.h (ATTRIBUTE_SENTINEL): New, it's a ggc feature and
  protected as such
* src/util/buf.c (virBufferStrcat): Use it.
* src/util/ebtables.c (ebtablesAddRemoveRule): Use it.
* src/util/iptables.c (iptableAddRemoveRule: Use it.
* src/util/qparams.h (new_qparam_set, append_qparams): Use it.
* docs/apibuild.py: avoid breaking the API generator with that new
  internal keyword macro
2009-11-06 10:39:13 +01:00
Matthew Booth
af249ea468 Support for <channel> in domain and QEmu backend
allows the following to be specified in a domain:
<channel type='pipe'>
  <source path='/tmp/guestfwd'/>
  <target type='guestfwd' address='10.0.2.1' port='4600'/>
</channel>

* proxy/Makefile.am: add network.c as dep of domain_conf.c
* docs/schemas/domain.rng src/conf/domain_conf.[ch]: extend the domain
  schemas and the parsing/serialization side for the new construct

QEmu support will add the following on the qemu command line:
 -chardev pipe,id=channel0,path=/tmp/guestfwd
 -net user,guestfwd=tcp:10.0.2.1:4600-chardev:channel0

* src/qemu/qemu_conf.c: Add argument output for channel
* tests/qemuxml2(argv|xml)test.c: Add test for <channel> domain syntax
2009-11-05 15:31:03 +01:00
Cole Robinson
45bd290b64 docs: <clock> property is 'offset', not 'sync' 2009-11-04 14:31:34 -05:00
Paolo Bonzini
936565c701 Add support for an external TFTP boot server
This patch adds an optional attribute to the <bootp> tag, that
allows to specify a TFTP server address other than the address of
the DHCP server itself.

This can be used to forward the BOOTP settings of the host down to the
guest.  This is something that configurations such as Xen's default
network achieve naturally, but must be done manually for NAT.

* docs/formatnetwork.html.in: Document new attribute.
* docs/schemas/network.rng: Add it to schema.
* src/conf/network_conf.h: Add it to struct.
* src/conf/network_conf.c: Add it to parser and pretty printer.
* src/network/bridge_driver.c: Put it in the dnsmasq command line.
* tests/networkxml2xmlin/netboot-proxy-network.xml
  tests/networkxml2xmlout/netboot-proxy-network.xml
  tests/networkxml2xmltest.c: add new tests
2009-10-28 15:57:49 +01:00
Richard Jones
08bed02515 Support QEMU watchdog device.
This adds simple support for configuring a guest with a QEMU/KVM
virtual hardware watchdog device.
2009-10-21 16:37:44 +01:00
Cole Robinson
4027461865 schema: Update network schema.
Make things a bit more readable, and properly handle forward mode 'route'.
2009-10-16 10:52:10 -04:00
Jim Fehlig
e391595890 Add ocfs2 to list of fs pool types
* src/conf/storage_conf.c src/conf/storage_conf.h: extend the enums
  and values
* docs/schemas/storagepool.rng: add to the list of storage pool type
  formats
2009-10-14 17:03:22 +02:00
Daniel Veillard
a56ec4515b Release of 0.7.2 2009-10-14 11:16:13 +02:00
Cole Robinson
be2cd079af schema: Update storage pool schema.
- mpath pools weren't listed
- scsi pools were missing an adapter section
- iscsi pools were missing an auth section
- Logical pools do not require a source name to be specified
2009-10-13 10:56:43 -04:00
Daniel Veillard
b8b260dde9 Add a target for libvirt.devhelp
* docs/Makefile.am: the lack of a target for devhelp/libvirt.devhelp
  broke 'make dist'
2009-10-13 16:19:57 +02:00
Mark McLoughlin
33948c6844 Fix schema to allow missing machine type
The domain/os/type element may have an arch specified without having
a machine variant specified. In fact, this is what python-virtinst
does when defining a guest.

* docs/schemas/domain.rng: allow missing machine type
2009-10-12 10:47:01 +01:00
Daniel P. Berrange
35b5f84c50 Remove some auto-generated files
Removes some auto-generated files still under version control.
It also moves the rule for generating NEWS into the Makefile.am
that's in the same directory as the output file to avoid confusion

* docs/libvirt-api.xml, docs/libvirt-refs.xml, NEWS: Remove
  auto-generated files from source control
* Makefile.am: Add rule for generating NEWS file
* docs/Makefile.am: Remove rule for generating NEWS file
2009-10-09 13:01:22 +01:00
Daniel P. Berrange
0d5600fd2f Pull connection handling code out of doTunnelMigrate
Simplify the doTunnelMigrate() method by pulling out the code
which opens/closes the virConnectPtr  object into a parent
method

* qemu/qemu_driver.c: Add doPeer2PeerMigrate which then calls
  doTunnelMigrate with dconn & dom_xml
2009-10-09 12:35:07 +01:00
Jamie Strandboge
624a7927f0 Documentation and examples for SVirt Apparmor driver
* docs/drvqemu.html.in: include documentation for AppArmor sVirt
  confinement
* examples/apparmor/TEMPLATE examples/apparmor/libvirt-qemu
  examples/apparmor/usr.lib.libvirt.virt-aa-helper
  examples/apparmor/usr.sbin.libvirtd: example templates and
  configuration files for SVirt Apparmor when using KVM/QEmu
2009-10-08 16:42:05 +02:00
Daniel P. Berrange
e46f6309d5 Fix rebuilding of devhelp files
The devhelp/ directory files depend on libvirt-api.xml being
uptodate, but automake always processes SUBDIRS before the
current directory. So devhelp would be built and then the
libvirt-api.xml re-build, invalidating the devhelp data again.

To fix this all the rules for devhelp are moved directly
into the docs/Makefile.am allowing make to see the global
dependancy chain and thus build things in the correct order

* docs/Makefile.am: Add rules for devhelp rebuild
* docs/devhelp/Makefile.am: Remove devhelp rebuild
* configure.in: Remove docs/devhelp/Makefile.am
2009-10-06 11:12:53 +01:00
Daniel P. Berrange
e2b8f981c4 Fix ordering of <exports> in API description file
* docs/apibuild.py: Make uniq() function sort keys before returning
  them to ensure consitent ordering of <exports> in XML file
2009-10-06 11:12:53 +01:00
Daniel P. Berrange
ea6bc1e8c6 Fix typo in Makefile.am breaking NEWS file generation
* docs/Makefile.am: Fix syntax error in NEWS rule, '$' should be '$$'
  to escape correctly
2009-10-02 12:02:36 +01:00
Chris Lalancette
6e16575a37 Tunnelled migration.
Implementation of tunnelled migration, using a Unix Domain Socket
on the qemu backend.  Note that this requires very new versions of
qemu (0.10.7 at least) in order to get the appropriate bugfixes.

Signed-off-by: Chris Lalancette <clalance@redhat.com>
2009-10-02 11:43:26 +02:00
Paolo Bonzini
36e0372986 Fix documentation and comment typos
Fix a few mispellings :-) of "successfully" and regenerate
docs/libvirt-*.xml.
* src/libvirt.c: Fix typos.
* src/secret/secret_driver.c: Fix typos.
* docs/libvirt-api.xml: Regenerate.
* docs/libvirt-refs.xml: Regenerate.
2009-10-01 16:42:40 +02:00
Daniel Veillard
8fc469b3d5 523639 Allows a <description> tag for domains
* docs/schemas/domain.rng: allow one <description> tag in the top level
  of the <domain> to store user information as text
* src/conf/domain_conf.c src/conf/domain_conf.h: extend the structure
  to store this text, grab it at parse time and save it back when
  present after <uuid>
2009-09-30 16:10:16 +02:00
Chris Lalancette
47c8709564 Fix up a few typos in the tree.
Signed-off-by: Chris Lalancette <clalance@redhat.com>
2009-09-30 14:05:24 +02:00
Matthias Bolte
14bf7270aa Fix apibuild.py warnings
Function comments for virStreamEvent{Add,Update,Remove}Callback() are
missing a trailing ':'. Therefore apibuild.py fails to parse the comment
and warns about the missing ':'.

* docs/libvirt-api.xml, docs/libvirt-refs.xml: updated by apibuild.py
* src/libvirt.c: add missing ':' in function comments
2009-09-30 13:41:28 +02:00
Daniel P. Berrange
182eba1bc6 Add public API definition for data stream handling
* include/libvirt/libvirt.h.in: Public API contract for
  virStreamPtr object
* src/libvirt_public.syms: Export data stream APIs
* src/libvirt_private.syms: Export internal helper APIs
* src/libvirt.c: Data stream API driver dispatch
* src/datatypes.h, src/datatypes.c: Internal helpers for virStreamPtr
  object
* src/driver.h: Define internal driver API for streams
* .x-sc_avoid_write: Ignore src/libvirt.c because it trips
  up on comments including write()
* python/Makefile.am: Add libvirt-override-virStream.py
* python/generator.py: Add rules for virStreamPtr class
* python/typewrappers.h, python/typewrappers.c: Wrapper
  for virStreamPtr
* docs/libvirt-api.xml, docs/libvirt-refs.xml: Regenerate
  with new APIs
2009-09-29 15:48:52 +01:00
Daniel P. Berrange
5486abfe4e Fix API doc extractor to stop munging comment formatting
The python method help docs are copied across from the C
funtion comments, but in the process all line breaks and
indentation was being lost. This made the resulting text
and code examples completely unreadable. Both the API
doc extractor and the python generator were destroying
whitespace & this fixes them to preserve it exactly.

* docs/apibuild.py: Preserve all whitespace when extracting
  function comments. Print function comment inside a <![CDATA[
  section to fully preserve all whitespace. Look for the
  word 'returns' to describe return values, instead of 'return'
  to avoid getting confused with code examples including the
  C 'return' statement.
* python/generator.py: Preserve all whitespace when printing
  function help docs
* src/libvirt.c: Change any return parameter indicated by
  'return' to be 'returns', to avoid confusing the API extractor
* docs/libvirt-api.xml: Re-build for fixed descriptions
2009-09-28 14:08:25 +01:00
Paolo Bonzini
738ee810b4 network: add 'bootp' and 'tftp' config
Currently, libvirtd will start a dnsmasq process for the virtual
network, but (aside from killing the dnsmasq process and replacing it),
there's no way to define tftp boot options.

This change introduces the appropriate tags to the dhcp configuration:

 <network>
   <name>default</name>
   <bridge name="virbr%d" />
   <forward/>
   <ip address="192.168.122.1" netmask="255.255.255.0">
     <tftp root="/var/lib/tftproot" />
     <dhcp>
       <range start="192.168.122.2" end="192.168.122.254" />
       <bootp file="pxeboot.img"/>
     </dhcp>
   </ip>
 </network>

When the attributes are present, these are passed to the
arguments to dnsmasq:

 dnsmasq [...] --enable-tftp --tftp-root /srv/tftp --dhcp-boot pxeboot.img
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^
                      from <tftp />                     from <bootp />

At present, only local tftp servers are supported (ie, dnsmasq runs as
the tftp server), but we could improve this in future by adding a
server= attribute.

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>

2009-09-21  Paolo Bonzini  <pbonzini@redhat.com>
            Jeremy Kerr  <jk@ozlabs.org>

	* docs/formatnetwork.html.in: Document new tags.
	* docs/formatnetwork.html: Regenerate.
	* docs/schemas/network.rng: Update.
	* src/network_conf.c (virNetworkDefFree): Free new fields.
	(virNetworkDHCPRangeDefParseXML): Parse <bootp>.
	(virNetworkIPParseXML): New, parsing <dhcp> and <tftp>.
	(virNetworkDefParseXML): Use virNetworkIPParseXML instead of
	virNetworkDHCPRangeDefParseXML.
	(virNetworkDefFormat): Pretty print new fields.
	* src/network_conf.h (struct _virNetworkDef): Add netboot fields.
	* src/network_driver.c (networkBuildDnsmasqArgv): Add
	TFTP and BOOTP arguments.

	* tests/Makefile.am (EXTRA_DIST): Add networkschemadata.
	* tests/networkschematest: Look in networkschemadata.
	* tests/networkschemadata/netboot-network.xml: New.
2009-09-23 09:47:10 +02:00
Dan Kenigsberg
27a1f781bc Fix a number of small typos 2009-09-22 12:55:39 +02:00
Florian Vichot
24e0171b86 add doc for graphic and video elements
* docs/formatdomain.html.in: explain the new syntax of the video and
  graphic elements in the domain XML
2009-09-22 10:32:14 +02:00
Daniel P. Berrange
13f59ad733 Move example XML files into examples/xml
* docs/storage/: Move to examples/xml/storage/
* docs/test*.xml: Move to examples/xml/test/
* docs/Makefile.am: Remove example XML files from dist
* Makefile.am: Add examples/xml to EXTRA_DIST
* tests/virshtest.c: Update for moved test XML
* libvirt.spec.in: Include example XML files as docs
* tests/int-overflow: UPdate for moved XML
2009-09-21 14:41:48 +01:00