Commit Graph

670 Commits

Author SHA1 Message Date
Stefan Berger
5c0e525c1c web docs -- macvtap mode explanation
This adds more information about the different macvtap device modes,
spells out VEPA and adds a link to a pdf at the ieee site.
2010-03-05 15:41:38 +01:00
Jim Meyering
aa7847d3ad maint: convert leading TABs in *.rng files to equivalent spaces
* docs/schemas/capability.rng: Likewise.
* docs/schemas/network.rng: Likewise.
* docs/schemas/nodedev.rng: Likewise.
* docs/schemas/storagepool.rng: Likewise.
* docs/schemas/storagevol.rng: Likewise.
Use these commands:
t=$'\t'
git ls-files | grep '\.rng$' | xargs grep -lE "^ *$t" \
  | xargs perl -MText::Tabs -ni -le \
    '$m=/^( *\t[ \t]*)(.*)/; print $m ? expand($1) . $2 : $_'
2010-03-01 20:19:20 +01:00
Daniel P. Berrange
20578bda74 Expand docs about clock modes
* formatdomain.html.in: Document new clock options
2010-03-01 18:43:04 +00:00
Daniel P. Berrange
e4d7433ef0 Allow a timezone to be specified instead of sync to host timezone
This extends the XML to allow for

  <clock offset='timezone' timezone='Europe/Paris'/>

This is useful if the admin has not configured any timezone on the
host OS, but still wants to synchronize a guest to a specific one.

* src/conf/domain_conf.h, src/conf/domain_conf.c: Support extra
  'timezone' attribute on clock configuration
* docs/schemas/domain.rng: Add 'timezone' attribute
* src/xen/xend_internal.c, src/xen/xm_internal.c: Reject configs
  with a configurable timezone
2010-03-01 18:42:55 +00:00
Daniel P. Berrange
b9e2967a5e Add new clock mode allowing variable adjustments
This introduces a third option for clock offset synchronization,
that allows an arbitrary / variable adjustment to be set. In
essence the XML contains the time delta in seconds, relative to
UTC.

  <clock offset='variable' adjustment='123465'/>

The difference from 'utc' mode, is that management apps should
track adjustments and preserve them at next reboot.

* docs/schemas/domain.rng: Schema for new clock mode
* src/conf/domain_conf.c, src/conf/domain_conf.h: Parse
  new clock time delta
* src/libvirt_private.syms, src/util/xml.c, src/util/xml.h: Add
  virXPathLongLong() method
2010-03-01 18:36:01 +00:00
Jim Meyering
a79fb1c491 build: avoid "make rpm" failure in docs/
Add missing rule to build html/libvirt-libvirt.html.
Use a GNU Make pattern rule to avoid running apibuild.py once
for each out-of-date target, in a parallel build.
* docs/Makefile.am
2010-02-25 14:14:51 +01:00
Jim Meyering
ace4dca5df build: teach apibuild.py to work in a non-srcdir build
* docs/Makefile.am (libvirt-api.xml libvirt-refs.xml): Generalize
apibuild.py to work in a non-srcdir build.  Pass "srcdir" to it.
* docs/apibuild.py (rebuild): Honor the $srcdir envvar.
2010-02-25 14:14:42 +01:00
Jim Meyering
f064dca7ea build: avoid non-srcdir "make distcheck" failures (CLEANFILES)
* docs/Makefile.am (MAINTAINERCLEANFILES): Use this variable
for generated-and-distributed files, not "CLEANFILES".
Besides, "make clean" and "make distclean" should not delete
distributed files.
2010-02-25 13:46:27 +01:00
Jim Meyering
0a42b9e2c5 build: avoid non-srcdir installation failure (sitemap.html.in)
* docs/Makefile.am (EXTRA_DIST): Add sitemap.html.in.
2010-02-25 10:49:58 +01:00
Jim Meyering
53ed2c4c58 build: avoid non-srcdir installation failure (apibuild.py)
* docs/Makefile.am (libvirt-api.xml): Insert missing "$(srcdir)/".
Also, remove unnecessary sub-shell.
2010-02-25 10:49:51 +01:00
Stefan Berger
c7b85e3710 Add descriptions for macvtap direct type interfaces
This adds a description about the 'direct' type of interface recently
added for macvtap device type support on the host.
2010-02-24 10:29:23 +01:00
Cole Robinson
1edc59e71b docs: Fix syntax warnings from recent changes. 2010-02-23 10:25:17 -05:00
Cole Robinson
e530940e47 docs: network: Document <domain> element 2010-02-23 09:44:40 -05:00
Cole Robinson
f51e01f47d docs: network: Document STP and delay attributes 2010-02-23 09:44:39 -05:00
Cole Robinson
9b9e52a1cb docs: domain: Document <description> element 2010-02-23 09:44:39 -05:00
Cole Robinson
582f04f064 docs: storage: Document multipath pools 2010-02-23 09:44:39 -05:00
Cole Robinson
c5bad3ad21 docs: storage: Document SCSI pools 2010-02-23 09:44:38 -05:00
Cole Robinson
e563b3b326 docs: storage: Fix backingStore <format> docs 2010-02-23 09:44:38 -05:00
Cole Robinson
f66dcd044f docs: storage: <volume><key> is always generated. 2010-02-23 09:44:38 -05:00
Cole Robinson
3a6555b345 docs: storage: Document capacity/alloc 'unit' 2010-02-23 09:44:38 -05:00
Dan Kenigsberg
d5739ab56a docs: add 3 missing spaces 2010-02-21 14:56:23 +01:00
Matthew Booth
7813a0f81c Add domain support for virtio channel
Add support for virtio-serial by defining a new 'virtio' channel target type
and a virtio-serial controller. Allows the following to be specified in a
domain:

<controller type='virtio-serial' index='0' ports='16' vectors='4'/>
<channel type='pty'>
  <target type='virtio' name='org.linux-kvm.port.0'/>
  <address type='virtio-serial' controller='0' bus='0'/>
</channel>

* docs/schemas/domain.rng: Add virtio-serial controller and virtio
  channel type.
* src/conf/domain_conf.[ch]: Domain parsing/serialization for
  virtio-serial controller and virtio channel.
* tests/qemuxml2xmltest.c
  tests/qemuxml2argvdata/qemuxml2argv-channel-virtio.xml: add domain xml
  parsing test
* src/libvirt_private.syms src/qemu/qemu_conf.c:
  virDomainDefAddDiskControllers() renamed to
  virDomainDefAddImplicitControllers()
2010-02-18 17:52:03 +01:00
Matthew Booth
ad4dde3d50 Fix whitespace in domain.rng
* src/schemas/domain.rng: Replace tabs with 8 spaces
2010-02-18 15:03:42 +01:00
Stefan Berger
c841a1fa7f macvtap support for libvirt -- schema extensions
* docs/schemas/domain.rng: extends the domain xml schema to support the
  new interface type 'direct'
2010-02-15 17:47:29 +01:00
Jiri Denemark
2073ed6f20 Fix <cpu> element in domain XML schema
The current schema is more permissive than the XML parsing code in
libvirt. Precisely, 'match' attribute is optional in schema while in
reality its use is bound to <model> element:

- <cpu> element without 'match' attribute is allowed only if <topology>
  element is the only child element of <cpu>

- <cpu> element with 'match' attribute requires <model> element to be
  present; <topology> and <feature> elements are optional

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
2010-02-11 16:46:20 +01:00
Matthias Bolte
f972dc2d5c Remove conn parameter from util functions
It was used for error reporting only.
2010-02-09 01:04:54 +01:00
Matthias Bolte
d5c6183def Remove conn parameter from virXPath* functions
It was used for error reporting only.
2010-02-09 01:04:54 +01:00
Matthias Bolte
a5ab900d26 Remove conn parameter from virReportSystemError 2010-02-09 01:04:54 +01:00
Matthias Bolte
8ce5e2c1ab Remove conn parameter from virReportOOMError 2010-02-09 01:04:54 +01:00
Matthias Bolte
b56fbbad0b website: Add a 1em right margin
This stops the text and pre-boxes from touching the right border.
2010-02-04 19:09:28 +01:00
Matthias Bolte
b1cd474c77 docs: Refer to virReportOOMError in the HACKING file
Instead of refering to __virRaiseError(VIR_ERROR_NO_MEMORY).
2010-02-04 19:09:28 +01:00
Matthias Bolte
ce71bfa817 docs: Emphasize that devices have to be inside the <devices> element
Also cleanup indentation of domain XML examples.
2010-02-04 19:09:28 +01:00
Daniel Veillard
31a5ee922a Release of libvirt-0.7.6
* configure.ac docs/news.html.in libvirt.spec.in: version bump and doc
  updates
* po/*.po*: updated and regenerated the localizations
2010-02-03 18:16:25 +01:00
Daniel P. Berrange
23d6abd23b Tweak USB hostdevice XML handling
When attaching a USB host device based on vendor/product, libvirt
will resolve the vendor/product into a device/bus pair. This means
that when printing XML we should allow device/bus info to be printed
at any time if present

* src/conf/domain_conf.c, docs/schemas/domain.rng: Allow USB device
  bus info alongside vendor/product
2010-02-02 16:31:47 +00:00
Eric Blake
3fc974209a maint: fix spelling error in hacking
* HACKING: STRCASEEQ is case insensitive.
* docs/hacking.html.in: Likewise.
2010-01-29 21:48:39 +01:00
Matthew Booth
6f4ca18d83 Add missing sata controller type to domain.rng
* docs/schemas/domain.rng: Add sata controller type
2010-01-27 14:26:49 +01:00
Chris Lalancette
a7d17c6187 Fix two instances of misspelled 'pseudo'
Signed-off-by: Chris Lalancette <clalance@redhat.com>
2010-01-25 16:25:28 -05:00
Daniel P. Berrange
e2c03da940 Add docs about new mailing list
* docs/contact.html.in: Document new users mailing list
2010-01-21 16:48:11 +01:00
David Allan
6aabcb5bd8 Implement support for multi IQN
Allows the initiator to use a variety of IQNs rather than just the
system IQN when creating iSCSI pools.
* docs/schemas/storagepool.rng: extends the syntax with <iqn name="..."/>
* src/conf/storage_conf.[ch]: read and stores the iqn name
* src/storage/storage_backend_iscsi.[ch]: implement the IQN selection
  when detected
2010-01-21 12:50:52 +01:00
Jiri Denemark
39d883bb3d Let make fail when XHTML validation fails
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
2010-01-21 09:45:59 +01:00
Jiri Denemark
f0088c1bfa Document <cpu> elements in capabilities and domain XML
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
2010-01-20 11:04:01 +01:00
Matthias Bolte
d392f4db9d docs: Remove outdated information about remote limitations 2010-01-20 10:03:17 +01:00
Laine Stump
77dd67087b Update interface.rng and xml test files to match netcf 0.1.5
The RNG now supports IPv6 and bonds attached to bridges, along with
some other minor tweaks. All test files from netcf have been copied to
the test directory and added to the xml2xml and schema tests (and they
all pass, of course ;-)
2010-01-19 21:13:03 +01:00
Jiri Denemark
ce4896fb65 Allow for CPU topology specification without model
Currently CPU topology may only be specified together with CPU model:
    <cpu match='exact'>
        <model>name</model>
        <topology sockets='1' cores='2' threads='3'/>
    </cpu>

This patch allows for CPU topology specification without the need for
also specifying CPU model:
    <cpu>
        <topology sockets='1' cores='2' threads='3'/>
    </cpu>

'match' attribute and 'model' element are made optional with the
restriction that 'match' attribute has to be set when 'model' is
present.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
2010-01-19 12:35:22 +01:00
Daniel P. Berrange
4ac290cc33 Add device info to serial, parallel, channel, input & fs devices
Although the serial, parallel, chanel, input & fs devices do
not have PCI address info, they can all have device aliases.
Thus it neccessary to associate the virDomainDeviceInfo data
with them all.

* src/conf/domain_conf.c, src/conf/domain_conf.h: Add hooks for
  parsing / formatting device info for serial, parallel, channel
  input and fs devices.
* docs/schemas/domain.rng: Associate device info with character
  devices, input & fs device
2010-01-18 13:38:56 +00:00
Jim Meyering
eabb98b0a8 gnulib added a new syntax-check test: use $(VAR), not @VAR@
The latter is not officially "wrong", but *is* terribly anachronistic.
I think automake documentation or comments call that syntax obsolescent.
* cfg.mk (_makefile_at_at_check_exceptions): Exempt @SCHEMADIR@
and @SYSCONFDIR@ uses -- there are no Makefile variables for those.
* docs/Makefile.am: Use $(INSTALL), not @INSTALL@.
* examples/dominfo/Makefile.am: Similar.
* examples/domsuspend/Makefile.am: Similar.
* proxy/Makefile.am: Similar.
* python/Makefile.am: Similar.
* python/tests/Makefile.am: Similar.
* src/Makefile.am: Similar.
* tests/Makefile.am: Similar.
2010-01-18 09:50:08 +01:00
Matthias Bolte
cebc4b8921 Fix validation of news.html 2010-01-15 19:29:50 +01:00
Jim Fehlig
8d6af63a8a Minor fixes for API extension doc
Update the API Extensions doc to reflect new source directory layout.
2010-01-15 10:45:18 -07:00
Wolfgang Mauerer
74ec5e65ce Add new domain device: "controller"
This augments virDomainDevice with a <controller> element
that is used to represent disk controllers (e.g., scsi
controllers). The XML format is given by

  <controller type="scsi" index="<num>">
     <address type="pci" domain="0xNUM" bus="0xNUM" slot="0xNUM"/>
  </controller>

where type denotes the disk interface (scsi, ide,...), index
is an integer that identifies the controller for association
with disks, and the <address> element specifies the controller
address on the PCI bus as described in previous commits
The address element can be omitted; in this case, an address
will be assigned automatically.

Most of the code in this patch is from Wolfgang Mauerer's
previous disk controller series

 * docs/schemas/domain.rng: Define syntax for <controller>
   XML element
 * src/conf/domain_conf.c, src/conf/domain_conf.h: Define
   virDomainControllerDef struct, and routines for parsing
   and formatting XML
* src/libvirt_private.syms: Add virDomainControllerInsert
   and virDomainControllerDefFree
2010-01-15 16:38:59 +00:00
Daniel P. Berrange
a9e4ea94f1 Add address info to sound, video and watchdog devices
Add the virDomainDeviceAddress information to the sound, video
and watchdog devices. This means all of them gain the new XML
element

  <address .... />

This brings them upto par with disk/net/hostdev devices which
already have address info

* src/conf/domain_conf.h: Add virDomainDeviceAddress to sound,
  video & watchdog device struts.
* src/conf/domain_conf.c: Hook up parsing/formatting for
  virDomainDeviceAddress in sound, video & watchdog devices
* docs/schemas/domain.rng: Associate device address info
  with sound, video & watchdog
2010-01-15 16:38:08 +00:00
Daniel P. Berrange
d812e7aeb8 Extend the virDomainDeviceAddress struture to allow disk controller addresses
Introduce a new structure

      struct _virDomainDeviceDriveAddress {
        unsigned int controller;
        unsigned int bus;
        unsigned int unit;
      };

and plug that into virDomainDeviceAddress and generates XML that
looks like

  <address type='drive' controller='1' bus='0' unit='5'/>

This syntax will be used by the QEMU driver to explicitly control
how drives are attached to the bus

* src/conf/domain_conf.h, src/conf/domain_conf.c: Parsing and
  formatting of drive addresses
* docs/schemas/domain.rng: Define new address format for drives
2010-01-15 16:37:57 +00:00
Daniel P. Berrange
1b0cce7d3a Introduce a standardized data structure for device addresses
All guest devices now use a common device address structure
summarized by:

  enum virDomainDeviceAddressType {
    VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE,
    VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI,
  };

  struct _virDomainDevicePCIAddress {
    unsigned int domain;
    unsigned int bus;
    unsigned int slot;
    unsigned int function;
  };

  struct _virDomainDeviceInfo {
    int type;
    union {
        virDomainDevicePCIAddress pci;
    } addr;
  };

This replaces the anonymous structs in Disk/Net/Hostdev data
structures. Where available, the address is *always* printed
in the XML file, instead of being hidden in the internal state
file.

  <address type='pci' domain='0x0000' bus='0x1e' slot='0x07' function='0x0'/>

The structure definition is based on Wolfgang Mauerer's disk
controller patch series.

* docs/schemas/domain.rng: Define the <address> syntax and
  associate it with disk/net/hostdev devices
* src/conf/domain_conf.h, src/conf/domain_conf.c,
  src/libvirt_private.syms: APIs for parsing/formatting address
  information. Also remove the QEMU specific 'pci_addr' attributes
* src/qemu/qemu_driver.c: Replace use of 'pci_addr' attrs with
  new standardized format.
2010-01-15 16:37:44 +00:00
Matthias Bolte
ddcee85f7c Document the domain XML cache attribute for disk devices 2010-01-11 23:58:56 +01:00
Jim Meyering
0418fa2e72 avoid another "make distcheck" failure
* docs/Makefile.am (uninstall-local): Separate $$f from preceding
dir name with a "/" and use $$(basename $$f) rather than $$f, since
some values of $$f are prefixed with devhelp/.
2010-01-09 09:56:20 +01:00
Matthias Bolte
728e9229b1 Replace old CVS references with GIT 2010-01-08 18:08:22 +01:00
Matthias Bolte
96ceb12443 esx: Fix 'vpx' MAC address range and allow arbitrary MAC addresses
The MAC addresses with 00:50:56 prefix are split into several ranges:

  00:50:56:00:00:00 - 00:50:56:3f:ff:ff  'static' range (manually assigned)
  00:50:56:80:00:00 - 00:50:56:bf:ff:ff  'vpx' range (assigned by a VI Client)

Erroneously the 'vpx' range was assumed to be larger and to occupy the
remaining addresses of the 00:50:56 prefix that are not part of the 'static'
range.

00:50:56 was used as prefix for generated MAC addresses, this is not possible
anymore, because there are gaps in the allowed ranges. Therefore, change the
prefix to 00:0c:29 which is the prefix for auto generated MAC addresses anyway.

Allow arbitrary MAC addresses to be used and set the checkMACAddress VMX option
to false in case the MAC address doesn't fall into any predefined range.

* docs/drvesx.html.in: update website accordingly
* src/esx/esx_driver.c: set the auto generation prefix to 00:0c:29
* src/esx/esx_vmx.c: fix MAC address range handling and allow arbitrary MAC
  addresses
* tests/vmx2xml*, tests/xml2vmx*: add some basic MAC address range tests
2010-01-07 01:38:19 +01:00
Daniel Veillard
3f24ae2eb9 Release of libvirt-0.7.5 2009-12-23 17:00:22 +01:00
Matthias Bolte
49e261d14e esx: Extend documentation about 'vcenter' and add some about 'auto_answer' 2009-12-18 19:29:38 +01:00
Jiri Denemark
6df8b363f7 XML schema for CPU flags
XML schema for CPU flags

Firstly, CPU topology and model with optional features have to be
advertised in host capabilities:

    <host>
        <cpu>
            <arch>ARCHITECTURE</arch>
            <features>
                <!-- old-style features are here -->
            </features>
            <model>NAME</model>
            <topology sockets="S" cores="C" threads="T"/>
            <feature name="NAME"/>
        </cpu>
        ...
    </host>

Secondly, drivers which support detailed CPU specification have to
advertise
it in guest capabilities:

    <guest>
    ...
    <features>
            <cpuselection/>
        </features>
    </guest>

And finally, CPU may be configured in domain XML configuration:

<domain>
    ...
    <cpu match="MATCH">
        <model>NAME</model>
        <topology sockets="S" cores="C" threads="T"/>
        <feature policy="POLICY" name="NAME"/>
    </cpu>
</domain>

Where MATCH can be one of:
    - 'minimum'     specified CPU is the minimum requested CPU
    - 'exact'       disable all additional features provided by host CPU
    - 'strict'      fail if host CPU doesn't exactly match

POLICY can be one of:
    - 'force'       turn on the feature, even if host doesn't have it
    - 'require'     fail if host doesn't have the feature
    - 'optional'    match host
    - 'disable'     turn off the feature, even if host has it
    - 'forbid'      fail if host has the feature

'force' and 'disable' policies turn on/off the feature regardless of its
availability on host. 'force' is unlikely to be used but its there for
completeness since Xen and VMWare allow it.

'require' and 'forbid' policies prevent a guest from being started on a host
which doesn't/does have the feature. 'forbid' is for cases where you disable
the feature but a guest may still try to access it anyway and you don't want
it to succeed.

'optional' policy sets the feature according to its availability on host.
When a guest is booted on a host that has the feature and then migrated to
another host, the policy changes to 'require' as we can't take the feature
away from a running guest.

Default policy for features provided by host CPU but not specified in domain
configuration is set using match attribute of cpu tag. If 'minimum' match is
requested, additional features will be treated as if they were specified
with 'optional' policy. 'exact' match implies 'disable' policy and 'strict'
match stands for 'forbid' policy.

* docs/schemas/capability.rng docs/schemas/domain.rng: extend the
  RelaxNG schemas to add CPU flags support
2009-12-18 14:37:09 +01:00
Matthias Bolte
52a18abd94 Fix and improve domain xml video element description
The description mismatched the actual structure since the video element
was introduced. The nvram attribute is actually called vram. Specify the
unit of the vram attribute.
2009-12-14 22:14:06 +01:00
Daniel Veillard
803d320430 Relax the allowed values for machine type in schema
* docs/schemas/domain.rng: don't try to validate based on a list, open
  up the machine type to a regexp allowing a-z A-Z 0-9 _ - and .
2009-12-14 16:59:06 +01:00
Matthew Booth
042956d558 Fix owner and group in example volume XML
The owner and group in the documentation examples were confusingly given as
'0744'. They should be numeric uid and gid. Changed the examples to use the
default uid and gid assigned to qemu in F12.

* docs/formatstorage.html.in: Change example owner and group in volume XML
2009-12-14 16:23:26 +01:00
Daniel Veillard
2aec15bc5a add missing doc for device <shareable/> option 2009-12-14 16:20:55 +01:00
Cole Robinson
deae2bb57f nodedev: Add removable storage 'media_label' prop
Provides the CDROM label for current media. Only implemented for the
udev backend.
2009-12-14 14:58:23 +01:00
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
Daniel P. Berrange
bde4589189 Remove all generated docs from source control
* docs/*.html, docs/devhelp/*.html, docs/html/*.html: Delete
* docs/.gitignore, docs/devhelp/.gitignore, docs/html/.gitignore:
  Ignore generated docs files
* docs/Makefile.am: Rebuild all HTML docs for 'all' target
  and include them in EXTRA_DIST and CLEANFILES
* docs/devhelp/Makefile.am: Include HTML in CLEANFILES
2009-09-21 14:41:47 +01:00
Daniel P. Berrange
1355e0552e Move all shared utility files to src/util/
* src/bridge.c, src/bridge.h, src/buf.c, src/buf.h, src/cgroup.c,
  src/cgroup.h, src/conf.c, src/conf.h, src/event.c, src/event.h,
  src/hash.c, src/hash.h, src/hostusb.c, src/hostusb.h,
  src/iptables.c, src/iptables.h, src/logging.c, src/logging.h,
  src/memory.c, src/memory.h, src/pci.c, src/pci.h, src/qparams.c,
  src/qparams.h, src/stats_linux.c, src/stats_linux.h,
  src/threads-pthread.c, src/threads-pthread.h, src/threads-win32.c,
  src/threads-win32.h, src/threads.c, src/threads.h, src/util.c,
  src/util.h, src/uuid.c, src/uuid.h, src/virterror.c,
  src/virterror_internal.h, src/xml.c, src/xml.h: Move all files
  into src/util/
* daemon/Makefile.am: Add -Isrc/util/ to build flags
* src/Makefile.am: Add -Isrc/util/ to build flags and update for
  moved files
* src/libvirt_private.syms: Export cgroup APIs since they're now
  in util rather than linking directly to drivers
* src/xen/xs_internal.c: Disable bogus virEventRemoveHandle call
  when built under PROXY
* proxy/Makefile.am: Update for changed file locations. Remove
  bogus build of event.c
* tools/Makefile.am, tests/Makefile.am: Add -Isrc/util/ to build flags
2009-09-21 14:41:47 +01:00
Daniel P. Berrange
3decd4f9f1 Make pki_check.sh into an installed & supported tool
* docs/pki_check.sh: Move to tool/virt-pki-validate.in and add
  in POD man page documentation
* tools/.gitignore: Ignore generated virt-pki-validate file
* tools/Makefile.am: Install & build virt-pki-validate and
  virt-pki-validate.1
* docs/remote.html, docs/remote.html.in: Refer to new tool
  name virt-pki-validate
* libvirt.spec.in, mingw32-libvirt.spec.in: Add virt-pki-validate
  and virt-pki-validate.1 to files list
2009-09-21 14:41:46 +01:00
Daniel P. Berrange
81c28325aa Remove obsolete files
* docs/Goals, RENAMES, mylibtool: Removed
2009-09-21 14:41:46 +01:00
Daniel P. Berrange
cebeba7bd7 Move docs/examples into examples/
* Makefile.am: Add examples/dominfo examples/domsuspend examples/python
  as SUBDIRS
* configure.in: Update AC_OUTPUT for new/old Makefiles
* docs/Makefile.am: Remove examples from SUBDIRS
* docs/examples/info1.c: Move to examples/dominfo/info1.c
* docs/examples/suspend.c: Move to examples/domsuspend/suspend.c
* docs/examples: Remove all remaining files
* docs/examples/python: Moved to examples/python/
* examples/dominfo/Makefile.am, examples/domsuspend/Makefile.am: New
  build files
* libvirt.spec.in: Update to take account of moved examples
2009-09-21 14:41:46 +01:00
Daniel P. Berrange
d6d528ca25 Remove unused images from docs/ directory
* 16favicon.png, Libxml2-Logo-90x34.gif, libvirHeader.png,
  libvirLogo.png, windows-cygwin-1.png, windows-cygwin-2.png,
  windows-cygwin-3.png: Remove unreferenced files
* Makefile.am: Remove deleted files from EXTRA_DIST
2009-09-21 14:41:45 +01:00
Daniel P. Berrange
7ff256ec98 Move virsh into tools/ directory
Move the virsh tool and its man page into the tools directory

* Makefile.am: Remove rules for virsh.1 man page
* virsh.1: Remove auto-generated file
* docs/Makefile.am: Remove rules for virsh.pod man page
* docs/virsh.pod: Move to tools/ directory
* src/Makefile.am, src/.gitignore: Remove rules for virsh
* src/console.c, src/console.h, src/*.ico, src/virsh_win_icon.rc,
  src/virsh.c: Move into tools/ directory
* tools/Makefile.am: Add rules for building virsh
* tools/.gitignore: Ignore virsh built files
* tests/virshtest.c, tests/int-overflow: Update for new
  virsh location
2009-09-21 14:41:45 +01:00
Jim Meyering
8110d304f4 doc: don't emit trailing blanks into generated and VC'd NEWS file
* docs/Makefile.am ($(top_builddir)/NEWS): Filter out trailing
white space.
2009-09-15 15:01:26 +02:00
Daniel Veillard
c4f6e80671 Release of libvirt 0.7.1
* configure.in docs/news.html.in libvirt.spec.in src/libvirt_public.syms:
  updates to new release
* NEWS docs/devhelp/libvirt-libvirt.html docs/html/libvirt-libvirt.html
  docs/libvirt-api.xml docs/libvirt-refs.xml docs/news.html
  include/libvirt/libvirt.h: regenerated
2009-09-15 14:24:51 +02:00
Daniel P. Berrange
6c02fa7bd9 Add UUID definition required by storage encryption import
* docs/schemas/storagevol.rng: storage encryption rules require
  that UUID type be defined
2009-09-14 21:09:49 +01:00
Daniel P. Berrange
fac3f4cd54 Remove accidentally added UUID re-definition in storage schema
* docs/schemas/storageencryption.rng: Remove UUID definition
  since its provided by the domain.rng/storagevol.rng schemas
  that import this
2009-09-14 19:11:13 +01:00
Daniel P. Berrange
e1d715ef7d Rebuild API docs 2009-09-14 17:49:37 +01:00
Daniel P. Berrange
67b2d5e0bf Make secrets RNG more strict
* docs/schemas/secret.rng: Require volume element to be an absolute
  path. Fix whitespace indentation
2009-09-14 17:49:37 +01:00
Daniel P. Berrange
47e7a258db Fix UUID handling in secrets/storage encryption APIs
Convert all the secret/storage encryption APIs / wire format to
handle UUIDs in raw format instead of non-canonical printable
format. Guarentees data format correctness.

* docs/schemas/storageencryption.rng: Make UUID mandatory for a secret
  and validate fully
* docs/schemas/secret.rng: Fully validate UUID
* include/libvirt/libvirt.h, include/libvirt/libvirt.h.in, Add
  virSecretLookupByUUID and virSecretGetUUID. Make
  virSecretGetUUIDString follow normal API design pattern
* python/generator.py: Skip generation of virSecretGetUUID,
  virSecretGetUUIDString and virSecretLookupByUUID
* python/libvir.c, python/libvirt-python-api.xml: Manual impl
  of virSecretGetUUID,virSecretGetUUIDString and virSecretLookupByUUID
* qemud/remote.c: s/virSecretLookupByUUIDString/virSecretLookupByUUID/
  Fix get_nonnull_secret/make_nonnull_secret to use unsigned char
* qemud/remote_protocol.x: Fix remote_nonnull_secret to use a
  remote_uuid instead of remote_nonnull_string for UUID field.
  Rename REMOTE_PROC_SECRET_LOOKUP_BY_UUID_STRING to
  REMOTE_PROC_SECRET_LOOKUP_BY_UUID_STRING and make it take an
  remote_uuid  value
* qemud/remote_dispatch_args.h, qemud/remote_dispatch_prototypes.h,
  qemud/remote_dispatch_ret.h, qemud/remote_dispatch_table.h,
  qemud/remote_protocol.c, qemud/remote_protocol.h: Re-generate
* src/datatypes.h, src/datatypes.c: Store UUID in raw format instead
  of printable. Change virGetSecret to use raw format UUID
* src/driver.h: Rename virDrvSecretLookupByUUIDString to
  virDrvSecretLookupByUUID and use raw format UUID
* src/libvirt.c: Add virSecretLookupByUUID and virSecretGetUUID
  and re-implement virSecretLookupByUUIDString and
  virSecretGetUUIDString in terms of those
* src/libvirt_public.syms: Add virSecretLookupByUUID and
  virSecretGetUUID
* src/remote_internal.c: Rename remoteSecretLookupByUUIDString
  to remoteSecretLookupByUUID. Fix typo in args for
  remoteSecretDefineXML impl. Use raw UUID format for
  get_nonnull_secret and make_nonnull_secret
* src/storage_encryption_conf.c, src/storage_encryption_conf.h:
  Storage UUID in raw format, and require it to be present in
  XML. Use UUID parser to validate.
* secret_conf.h, secret_conf.c: Generate a UUID if none is provided.
  Storage UUID in raw format.
* src/secret_driver.c: Adjust to deal with raw UUIDs. Save secrets
  in a filed with printable UUID, instead of base64 UUID.
* src/virsh.c: Adjust for changed public API contract of
  virSecretGetUUIDString.
* src/storage_Backend.c: DOn't undefine secret we just generated
  upon successful volume creation. Fix to handle raw UUIDs. Generate
  a non-clashing UUID
* src/qemu_driver.c: Change to use lookupByUUID instead of
  lookupByUUIDString
2009-09-14 17:48:29 +01:00
Miloslav Trmač
2db2c5a186 Add virsh commands for secrets APIs
* src/virsh.c: Add virsh commands.
* docs/virsh.pod, virsh.1: Update documentation.
2009-09-11 14:54:57 +01:00
Miloslav Trmač
78811ae572 Add <usage> to <secret> docs
* docs/formatsecret.html.in, docs/formatsecret.html: Document <usage
  type='volume'>, replacing stand-alone <volume>.
* docs/schemas/secret.rng: Update schema to require <usage
  type='volume'>
2009-09-10 15:30:47 +01:00
Mark McLoughlin
22d990f138 Add arm arch to capabilities schema
* docs/schemas/capabilities.rng: add arm and sort arches
2009-09-10 12:25:42 +01:00
Mark McLoughlin
e45b13d248 Update capabilities schema to allow multiple machines per domain
* docs/schemas/capabilities.rng: allow multiple machines per domain
  just like they are allowed for guests
2009-09-10 12:25:42 +01:00
Mark McLoughlin
db4137ba02 Add esx and tcp migration uri transports to capabilities schema
* docs/schemas/capabilities.rng: include esx and tcp uri_transport
2009-09-10 12:25:42 +01:00
Daniel P. Berrange
85d15b5143 Add support for setting disk drive serial numbers
* docs/schemas/domain.rng: Add <serial> element to disks
* src/domain_conf.h, src/domain_conf.c: XML parsing and
  formatting for disk serial numbers
* src/qemu_conf.c: Set serial number when launching guests
* tests/qemuxml2argvdata/qemuxml2argv-disk-drive-shared.args,
  tests/qemuxml2argvdata/qemuxml2argv-disk-drive-shared.xml: Add
  serial number to XML test
2009-09-03 13:53:34 +01:00
Daniel P. Berrange
d823a05aef Support configuration of huge pages in guests
Add option to domain XML for

     <memoryBacking>
        <hugepages/>
     </memoryBacking>

* configure.in: Add check for mntent.h
* qemud/libvirtd_qemu.aug, qemud/test_libvirtd_qemu.aug, src/qemu.conf
  Add 'hugetlbfs_mount' config parameter
* src/qemu_conf.c, src/qemu_conf.h: Check for -mem-path flag in QEMU,
  and pass it when hugepages are requested.
  Load hugetlbfs_mount config parameter, search for mount if not given.
* src/qemu_driver.c: Free hugetlbfs_mount/path parameter in driver shutdown.
  Create directory for QEMU hugepage usage, chowning if required.
* docs/formatdomain.html.in: Document memoryBacking/hugepages elements
* docs/schemas/domain.rng: Add memoryBacking/hugepages elements to schema
* src/util.c, src/util.h, src/libvirt_private.syms: Add virFileFindMountPoint
  helper API
* tests/qemuhelptest.c: Add -mem-path constants
* tests/qemuxml2argvtest.c, tests/qemuxml2xmltest.c: Add tests for hugepage
  handling
* tests/qemuxml2argvdata/qemuxml2argv-hugepages.xml,
  tests/qemuxml2argvdata/qemuxml2argv-hugepages.args: Data files for
  hugepage tests
2009-09-03 13:51:55 +01:00
Pritesh Kothari
6aa576cda7 Generic parsing support for video acceleration
* docs/schemas/domain.rng: augment the video model with an optional
  acceleration element with optional accel2d and accel3d flags
* src/domain_conf.c src/domain_conf.h: exten the virDomainVideoDef
  structure with an optional accel field, virDomainVideoAccelDefParseXML
  and virDomainVideoAccelDefFormat functions to parse and serialize
  the structure.
2009-09-03 10:29:35 +02:00
Miloslav Trmač
f340964dc9 Attach encryption information to virDomainDiskDef.
The XML allows <encryption format='unencrypted'/>, this implementation
canonicalizes the internal representation so that "disk->encryption" is
non-NULL iff encryption information is available.

A domain with partial encryption information can be defined,
completeness of the information is not verified.  The domain won't
start until the remaining information is added, of course.

* docs/formatdomain.html, docs/formatdomain.html.in: Document
  new encryption options for disks
* docs/schemas/domain.rng: Pull in storage encryption schema
  rules
* src/domain_conf.h, src/domain_conf.c: Wire up storage encryption
  XML parsing/formatting APIs
2009-09-01 18:36:53 +01:00
Miloslav Trmač
eda3af2488 Attach encryption information to virStorageVolDef.
The XML allows <encryption format='unencrypted'/>, this implementation
canonicalizes the internal representation so that "vol->encryption" is
non-NULL iff the volume is encrypted.

Note that partial encryption information (e.g. specifying an encryption
format, but not the key/passphrase) is valid, libvirt will automatically
choose value for the missing information during volume creation.  The
user can read the volume XML, and use the unmodified <encryption> tag in
future operations (without having to be able to understand) its contents.

* docs/formatstorage.html, docs/formatstorage.html.in: Document
  storage volume encryption options
* src/storage_conf.c, src/storage_conf.h: Hook up storage
  encryption XML handling
* tests/storagevolschemadata/vol-qcow2.xml: Test case for encryption
  schema changes
2009-09-01 18:27:38 +01:00
Miloslav Trmač
05b9b8fda3 Add volume encryption information handling.
Define an <encryption> tag specifying volume encryption format and
format-depenedent parameters (e.g. passphrase, cipher name, key
length, key).

Currently the only defined parameter is a reference to a "secret"
(passphrase/key) managed using the virSecret* API.

Only the qcow/qcow2 encryption format, and a "default" format used to
let libvirt choose the format during volume creation, is currently
supported.

This patch does not add any users; the <encryption> tag is added in
the following patches to both volumes (to support encrypted volume
creation) and domains.

* docs/*.html: Re-generate
* docs/formatstorageencryption.html.in, docs/sitemap.html.in:
  Add page describing storage encryption data format
* docs/schemas/Makefile.am, docs/schemas/storageencryption.rng:
  Add RNG schema for storage encryption format
* po/POTFILES.in: Add src/storage_encryption_conf.c
* src/libvirt_private.syms: Export virStorageEncryption* functions
* src/storage_encryption_conf.h, src/storage_encryption_conf.c: Internal
  helper APIs for dealing with storage encryption format
* libvirt.spec.in, mingw32-libvirt.spec.in: Add storageencryption.rng
  RNG schema
2009-09-01 18:27:28 +01:00
Miloslav Trmač
9dc3b99345 Secret manipulation API docs refresh & wire up python generator
Sample session:

>>> import libvirt
>>> c = libvirt.open('qemu:///session')

>>> c.listSecrets()
['12247729-47d2-a783-88ce-b329d4781cd3', 'reee', 'abc']

>>> s = c.secretDefineXML("<secret ephemeral='no' private='no'>\n<description>Something for use</description>\n<volume>/foo/bar</volume>\n</secret>\n")

>>> s.UUIDString()
'340c2dfb-811b-eda8-da9e-25ccd7bfd650'

>>> s.XMLDesc()
"<secret ephemeral='no' private='no'>\n  <uuid>340c2dfb-811b-eda8-da9e-25ccd7bfd650</uuid>\n  <description>Something for use</description>\n  <volume>/foo/bar</volume>\n</secret>\n"

>>> s.setValue('abc\0xx\xffx')
0

>>> s.value()
'abc\x00xx\xffx'

>>> s.undefine()
0

* python/generator.py: Add rules for virSecret APIs
* python/libvir.c, python/libvirt-python-api.xml: Manual impl of
  virSecretSetValue, virSecretGetValue$ and virConnectListSecrets APIs
* python/libvirt_wrap.h, python/types.c: Wrapper for virSecret objects
* docs/libvirt-api.xml, docs/libvirt-refs.xml,
  docs/html/libvirt-virterror.html, docs/html/libvirt-libvirt.html,
  docs/devhelp/libvirt-virterror.html, docs/devhelp/libvirt-libvirt.html:
  Re-generate with 'make api'
2009-09-01 18:27:06 +01:00
Miloslav Trmač
6acc17af8c Secret manipulation public API
This patch adds a "secret" as a separately managed object, using a
special-purpose API to transfer the secret values between nodes and
libvirt users.

* docs/schemas/secret.rng, docs/schemas/Makefilem.am: Add new
  schema for virSecret objects
* docs/*html: Re-generated
* docs/formatsecret.html.in, docs/sitemap.html.in: Add page
  describing the virSecret XML schema
* include/libvirt/libvirt.h.in: Define the new virSecret public
  API
* src/libvirt_public.syms: Export symbols for new public APIs
* mingw32-libvirt.spec.in, libvirt.spec.in: Add secret.rng to
  files list
2009-09-01 17:38:52 +01:00
Chris Lalancette
bf878aa97e Fix up virNodeGetCellsFreeMemory
The documentation for virNodeGetCellsFreeMemory claims the values
returned are in kilobytes, but that's actually wrong; the value
returned is actually in bytes.  Fix up the documentation to be
correct.

Signed-off-by: Chris Lalancette <clalance@redhat.com>
2009-08-31 21:01:00 +02:00
Daniel P. Berrange
14194f1d56 Fix some typos & remove unhelpful acronyms in QEMU docs 2009-08-19 17:02:45 +01:00
Daniel P. Berrange
690b4ad329 Add documentation about the QEMU driver security features
* docs/drvqemu.html.in: Document DAC usage, SELinux integration,
  Linux capabilities, and Cgroups device ACLs
2009-08-19 14:19:16 +01:00
Daniel P. Berrange
444647d1e3 Remove 'the the' typo in docs 2009-08-14 12:01:27 +01:00
Mark McLoughlin
43b3851975 Fix some URLs in virsh manpage
* docs/virsh.pod: don't reference format.html anymore, reference
  the formatdomain.html etc. pages

* virsh.1: re-generate
2009-08-11 15:39:28 +01:00
Daniel P. Berrange
f2144a3063 Add link to AbiCloud web management system 2009-08-07 14:12:22 +01:00
Amy Griffis
7534be6fbc Update logging documentation
* docs/logging.html[.in] try to include a little more description about
  the corner cases, things someone might get hung up on on.
2009-08-06 15:58:38 +02:00
Daniel Veillard
22a5ebe44b Release of libvirt-0.7.0
* configure.in NEWS docs/* libvirt.spec.in include/libvirt/libvirt.h:
  Release of 0.7.0
* po/*.po*: updated and regenerated the localization pool
2009-08-05 16:00:41 +02:00
Aron Griffis
3879b33447 Typo and comment fixes
* docs/schemas/*.rng: the comments were wrong
* src/qemu_conf.c: typo in an error message
2009-08-05 11:56:56 +02:00