1. 02 4月, 2010 6 次提交
    • C
      Make virDomainLoadConfig static. · fba3dfd1
      Chris Lalancette 提交于
      Signed-off-by: NChris Lalancette <clalance@redhat.com>
      fba3dfd1
    • J
      VBox: Fix use of uninitialized value · f76c3493
      Jiri Denemark 提交于
      f76c3493
    • L
      Changes to clock timer XML to match final design. · 4ee2b318
      Laine Stump 提交于
      The clock timer XML is being updated in the following ways (based on
      further off-list discussion that was missed during the initial
      implementation):
      
      1) 'wallclock' is changed to 'track', and the possible values are 'boot'
       (corresponds to old 'host'), 'guest', and 'wall'.
      
      2) 'mode' has an additional value 'smpsafe'
      
      3) when tickpolicy='catchup', there can be an optional sub-element of
         timer called 'catchup':
      
         <catchup threshold=123 slew=120 limit=10000/>
      
      Those three values are all longs, always optional, and if they are present,
      they are positive. Internally, 0 indicates "unspecified".
      
      * docs/schemas/domain.rng: updated RNG definition to account for changes
      
      * src/conf/domain_conf.h: change the C struct and enums to match changes.
      
      * src/conf/domain_conf.c: timer parse and format functions changed to
                                handle the new selections and new element.
      
      * src/libvirt_private.syms: *TimerWallclock* changes to *TimerTrack*
      
      * src/qemu/qemu_conf.c: again, account for Wallclock --> Track change.
      4ee2b318
    • L
      Allow domain disk images on root-squash NFS to coexist with security driver. · 8a7b4be5
      Laine Stump 提交于
      (suggested by Daniel Berrange, tested by Dan Kenigsberg)
      
      virStorageFileGetMetadata will fail for disk images that are stored on
      a root-squash NFS share that isn't world-readable.
      SELinuxSetSecurityImageLabel is called during the startup of every
      domain (as long as security_driver != "none"), and it will propogate
      the error from virStorageFileGetMetadata, causing the domain startup
      to fail. This is, however, a common scenario when qemu is run as a
      non-root user and the disk image is stored on NFS.
      
      Ignoring this failure (which doesn't matter in this case, since the
      next thing done by SELinuxSetSecurityImageLabel - setting the file
      context - will also fail (and that function already ignores failures
      due to root-squash NFS) will allow us to continue bringing up the
      domain. The result is that we don't need to disable the entire
      security driver just because a domain's disk image is stored on
      root-squashed NFS.
      8a7b4be5
    • L
      78151ec9
    • C
      Don't use virFileReadLimFD in qemuDomainRestore. · d62f4c36
      Chris Lalancette 提交于
      virFileReadLimFD is a poor fit for reading the header
      of the restore file.  The problem is that virFileReadLimFD
      returns an error when there is more data after the amount
      you ask to read, but that is *expected* in this case.
      
      This patch is essentially a revert of
      1a4d5c95, but I don't think
      that commit does what it says anyway.  It purports to prevent
      an unwarranted OOM error, but since virFileReadLimFD will
      allocate memory up to the maximum anyway, the upper limit
      on the total amount of memory allocated is the same for either
      the old version or the new version.  Since the old saferead
      actually works and virFileReadLimFD does not, revert to
      using saferead.
      Signed-off-by: NChris Lalancette <clalance@redhat.com>
      d62f4c36
  2. 01 4月, 2010 19 次提交
    • J
      Only parse 'CPU XML' in virCPUDefParseXML() · 320ea3a4
      Jim Fehlig 提交于
      Received report of user crashing libvirtd with
      
      virsh capabilities > capabilities.xml
      virsh cpu-compare capabilities.xml
      
      While user has been informed about proper usage of cpu-compare,
      segfaulting libvirt should be avoided.
      
      Do not parse CPU definition in virCPUDefParseXML() if XML is not
      a 'cpu' node.
      320ea3a4
    • D
      Keep build quiet for generated file · f983c326
      Daniel P. Berrange 提交于
      Adds $(AM_V_GEN) to many more manual makefile.am rules that
      were generating files
      f983c326
    • D
      Keep track of guest paused state after disk IO / watchdog events · cd2404a3
      Daniel P. Berrange 提交于
      When a watchdog/IO error occurs, one of the possible actions that
      QEMU might take is to pause the guest. In this scenario libvirt
      needs to update its internal state for the VM, and emit a
      lifecycle event:
      
        VIR_DOMAIN_EVENT_SUSPENDED
      
      with a detail being one of:
      
        VIR_DOMAIN_EVENT_SUSPENDED_IOERROR
        VIR_DOMAIN_EVENT_SUSPENDED_WATCHDOG
      
      To future proof against possible QEMU support for multiple monitor
      consoles, this patch also hooks into the 'STOPPED' event in QEMU
      and emits a generic VIR_DOMAIN_EVENT_SUSPENDED_PAUSED event
      
      * include/libvirt/libvirt.h.in: Add VIR_DOMAIN_EVENT_SUSPENDED_IOERROR
      * src/qemu/qemu_driver.c: Update VM state to paused when IO error
        or watchdog events occurrs
      * src/qemu/qemu_monitor_json.c: Fix typo in disk IO event name
      cd2404a3
    • M
      Replace sscanf in PCI device address parsing · d13eb9fc
      Matthias Bolte 提交于
      This also fixes a problem with MinGW's GCC on Windows. GCC complains
      about the L modifier being unknown.
      
      Parsing in pciIterDevices is stricter now and doesn't accept trailing
      characters after the actual <domain>:<bus>:<slot>.<function> sequence
      anymore.
      
      Parsing in pciWaitForDeviceCleanup is also stricter now and expects
      the <start>-<end> : <domain>:<bus>:<slot>.<function> sequence to be
      terminated by \n.
      
      Change domain from unsigned long long to unsigned int in
      pciWaitForDeviceCleanup, because everywhere else domain is handled as
      unsigned int too.
      d13eb9fc
    • M
      xen: Use virStrToLong_i instead of sscanf for XenD port parsing · 57dab748
      Matthias Bolte 提交于
      Parsing is stricter now and doesn't accept trailing characters
      after the actual value anymore.
      57dab748
    • M
      xenapi: Use virStrToLong_i instead of sscanf for CPU map parsing · 82cb2e73
      Matthias Bolte 提交于
      Parsing is stricter now and doesn't accept trailing characters
      after the actual value anymore.
      82cb2e73
    • M
      openvz: Use strtok_r instead of sscanf for VPS UUID parsing · 1778da71
      Matthias Bolte 提交于
      Also free 2k stack space.
      1778da71
    • M
      xen: Use virParseMacAddr instead of sscanf · 00e00510
      Matthias Bolte 提交于
      This also fixes a bug in xenXMDomainConfigParse where uninitialized
      memory would be used as MAC address if sscanf fails.
      00e00510
    • M
      vbox: Replace atoi with virStrToLong_i · 2f047d48
      Matthias Bolte 提交于
      Parsing is stricter now and doesn't accept trailing characters
      after the actual value or non-number strings anymore. atoi just
      returns 0 in case it cannot parse a number from the given string.
      Now an error is reported for such a string.
      2f047d48
    • M
      cgroup: Replace sscanf with virStrToLong_ll · 73b45bfb
      Matthias Bolte 提交于
      The switch from %lli to %lld in virCgroupGetValueI64 is intended,
      as virCgroupGetValueU64 uses base 10 too, and virCgroupSetValueI64
      uses %lld to format the number to string.
      
      Parsing is stricter now and doesn't accept trailing characters
      after the actual value anymore.
      73b45bfb
    • M
      Refactor major.minor.micro version parsing into a function · 56bac4a2
      Matthias Bolte 提交于
      virParseVersionString uses virStrToLong_ui instead of sscanf.
      
      This also fixes a bug in the UML driver, that always returned 0
      as version number.
      
      Introduce STRSKIP to check if a string has a certain prefix and
      to skip this prefix.
      56bac4a2
    • M
      Replace sscanf in nwfilter rule parsing · ea54570e
      Matthias Bolte 提交于
      Parsing is stricter now and doesn't accept trailing characters
      after the actual value anymore.
      ea54570e
    • M
      Replace sscanf in legacy device address parsing · 2072d63c
      Matthias Bolte 提交于
      Parsing is stricter now and doesn't accept trailing characters
      after the actual <domain>:<bus>:<slot> sequence anymore.
      2072d63c
    • S
      While writing a couple of test cases for the nwfilter's XML parser I · e8132007
      Stefan Berger 提交于
      found some cases where the output ended up not looking as expected. So
      the following changes are in the patch below:
      
      - if the protocol ID in the MAC header is an integer, just write it into
      the datastructure without trying to find a corresponding string for it
      and if none is found failing
      - when writing the protocol ID as string, simply write it as integer if
      no corresponding string can be found
      - same changes for arpOpcode parsing and printing
      - same changes for protocol ID in an IP packet
      - DSCP value needs to be written into the data structure
      - IP protocol version number is redundant at this level, so remove it
      - parse the protocol ID found inside an IP packet not only as string but
      also as uint8
      - arrange the display of the src and destination masks to be shown after
      the src and destination ip address respectively in the XML
      - the existing libvirt IP address parser accepts for example '25' as an
      IP address. I want this to be parsed as a CIDR type netmask. So try to
      parse it as an integer first (CIDR netmask) and if that doesn't work as
      a dotted IP address style netmask.
      - instantiation of rules with MAC masks didn't work because they weren't
      printed into a buffer, yet.
      e8132007
    • S
      ESX test case needs '/' in interface name · 6cbc3306
      Stefan Berger 提交于
      To fix an ESX test case, valid interface names need '/' as valid letter.
      Signed-off-by: NStefan Berger <stefanb@us.ibm.com>
      6cbc3306
    • M
      Fix linker errors in proxy · a77821c8
      Matthias Bolte 提交于
      domain_conf.c:494: undefined reference to 'virNWFilterHashTableFree'
      domain_conf.c:5107: undefined reference to 'virNWFilterFormatParamAttributes'
      
      Add missing source to the proxy and disable XML parsing code in
      nwfilter_params.c for a proxy build.
      a77821c8
    • E
      build: more fallout from test -a · a792bf24
      Eric Blake 提交于
      * cfg.mk (sc_prohibit_test_minus_ao): Also check for [.
      * docs/Makefile.am (%.html, html/index.html): Avoid non-portable
      test usage.
      * libvirt.spec.in (%post): Likewise.
      * tools/virt-pki-validate.in (servercert.pem): Likewise.
      * configure.ac (LOGNAME): Use test, not [, in files processed by
      autoconf.
      Detected by Matthias Bolte.
      a792bf24
    • M
      Fix apibuild.py warning about virNWFilterLookupByUUIDString · eff24046
      Matthias Bolte 提交于
      The function name was written with capital I in the Filter part.
      eff24046
    • M
      website: Add archive link for libvirt-users list · 6fc93f1e
      Matthias Bolte 提交于
      6fc93f1e
  3. 31 3月, 2010 14 次提交
  4. 30 3月, 2010 1 次提交