- 16 4月, 2012 1 次提交
-
-
由 Michal Privoznik 提交于
Currently, we have 3 boolean arguments we have to pass to qemuProcessStart(). As libvirt grows it is harder and harder to remember them and their position. Therefore we should switch to flags instead.
-
- 13 4月, 2012 1 次提交
-
-
由 D. Herrendoerfer 提交于
This patch adds a netlink callback when migrating a VEPA enabled virtual machine. It fixes a Bug where a VM would not request a port association when it was cleared by lldpad. This patch requires the latest git version of lldpad to work. Signed-off-by: ND. Herrendoerfer <d.herrendoerfer@herrendoerfer.name>
-
- 11 4月, 2012 1 次提交
-
-
由 Jiri Denemark 提交于
In case an API fails with "cannot acquire state change lock", searching for the API that possibly forgot to end its job is not always easy. Let's keep track of the job owner and print it out for easier identification.
-
- 30 3月, 2012 1 次提交
-
-
由 Daniel P. Berrange 提交于
The code is splattered with a mix of sizeof foo sizeof (foo) sizeof(foo) Standardize on sizeof(foo) and add a syntax check rule to enforce it Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 29 3月, 2012 1 次提交
-
-
由 Christian Benvenuti 提交于
In the current V3 migration protocol, Libvirt does not check the result of the function qemuMigrationVPAssociatePortProfiles This means that it is possible for a migration to complete successfully even when the VM loses network connectivity on the destination host. With this change libvirt aborts the migration (during the "finish" step) when the above function fails, that is to say when at least one of the port profile associations fails. Signed-off by: Christian Benvenuti <benve@cisco.com>
-
- 23 3月, 2012 2 次提交
-
-
由 Daniel P. Berrange 提交于
Move error reporting out of the callers, into virURIParse and virURIFormat, to get consistency. * include/libvirt/virterror.h, src/util/virterror.c: Add VIR_FROM_URI * src/util/viruri.c, src/util/viruri.h: Add error reporting * src/esx/esx_driver.c, src/libvirt.c, src/libxl/libxl_driver.c, src/lxc/lxc_driver.c, src/openvz/openvz_driver.c, src/qemu/qemu_driver.c, src/qemu/qemu_migration.c, src/remote/remote_driver.c, src/uml/uml_driver.c, src/vbox/vbox_tmpl.c, src/vmx/vmx.c, src/xen/xen_driver.c, src/xen/xend_internal.c, tests/viruritest.c: Remove error reporting Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Since we defined a custom virURIPtr type, we should use a virURIFree method instead of assuming it will always be a typedef for xmlURIPtr * src/util/viruri.c, src/util/viruri.h, src/libvirt_private.syms: Add a virURIFree method * src/datatypes.c, src/esx/esx_driver.c, src/libvirt.c, src/qemu/qemu_migration.c, src/vmx/vmx.c, src/xen/xend_internal.c, tests/viruritest.c: s/xmlFreeURI/virURIFree/ Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 22 3月, 2012 3 次提交
-
-
由 Jiri Denemark 提交于
When a client which started non-p2p migration dies in a bad time, the source libvirtd never clears the migration job and almost nothing can be done with the domain without restarting the daemon. This patch makes use of connection close callbacks and ensures that migration job is properly discarded when the client disconnects.
-
由 Jiri Denemark 提交于
Destination daemon should not rely on the client or source daemon (depending on the type of migration) to call Finish when migration fails, because the client may crash before it can do so. The domain prepared for incoming migration is set to be destroyed (and migration job cleaned up) when connection with the client closes but this is not enough. If the associated qemu process crashes after Prepare step and the domain is cleaned up before the connection gets closed, autodestroy is not called for the domain and migration jobs remains set. In case the domain is defined on destination host (i.e., it is not completely removed once destroyed) we keep the job set for ever. To fix this, we register a cleanup callback which is responsible to clean migration-in job when a domain dies anywhere between Prepare and Finish steps. Note that we can't blindly clean any job when spotting EOF on monitor since normally an API is running at that time.
-
由 Jiri Denemark 提交于
This reverts commit 61f2b6ba and most of commit d8916dc8, which effectively brings back commit ef1065cf written by Jim Fehlig: The qemu migration speed default is 32MiB/s as defined in migration.c /* Migration speed throttling */ static int64_t max_throttle = (32 << 20); There's no need to throttle migration when targeting a file, so set migration speed to unlimited prior to migration, and restore to libvirt default value after migration. Default units is MB for migrate_set_speed monitor command, so (INT64_MAX / (1024 * 1024)) is used for unlimited migration speed. This was reverted because migration to file could not be canceled and even monitored since qemu was not processing any monitor commands until the migration finished. This is now different as we make sure the file descriptor we pass to qemu is able to properly report EAGAIN. Recent qemu changes might have helped as well. I tested managedsave with this patch in and indeed, it is 10x faster while I can still monitor its progress.
-
- 13 3月, 2012 1 次提交
-
-
由 Jiri Denemark 提交于
When host-model and host-passthrouh CPU modes were introduced, qemu driver was properly modify to update guest CPU definition during migration so that we use the right CPU at the destination. However, similar treatment is needed for (managed)save and snapshots since they need to save the exact CPU so that a domain can be properly restored. To avoid repetition of such situation, all places that need live XML share the code which generates it. As a side effect, this patch fixes error reporting from qemuDomainSnapshotWriteMetadata().
-
- 08 3月, 2012 1 次提交
-
-
由 Michal Privoznik 提交于
Currently, startupPolicy='requisite' was determining cold boot by migrateFrom != NULL. That means, if domain was started up with migrateFrom set we didn't require disk source path and allowed it to be dropped. However, on snapshot-revert domain wasn't migrated but according to documentation, requisite should drop disk source as well.
-
- 06 3月, 2012 1 次提交
-
-
由 Roopa Prabhu 提交于
This patch includes the following changes to virnetdevmacvlan.c and virnetdevvportprofile.c: - removes some netlink functions which are now available in virnetdev.c - Adds a vf argument to all port profile functions. For 802.1Qbh devices, the port profile calls can use a vf argument if passed by the caller. If the vf argument is -1 it will try to derive the vf if the device passed is a virtual function. For 802.1Qbg devices, This patch introduces a null check for the device argument because during port profile assignment on a hostdev, this argument can be null. Signed-off-by: NRoopa Prabhu <roprabhu@cisco.com>
-
- 05 3月, 2012 1 次提交
-
-
由 Jiri Denemark 提交于
No matter what cache mode is used, readonly disks are always safe wrt migration. Shared disks are required to be readonly or to disable host-side cache, which makes them safe as well.
-
- 29 2月, 2012 2 次提交
-
-
由 D. Herrendoerfer 提交于
Add de-association handling for 802.1qbg (vepa) via lldpad netlink messages. Also adds the possibility to perform an association request without waiting for a confirmation. Signed-off-by: ND. Herrendoerfer <d.herrendoerfer@herrendoerfer.name>
-
由 Jiri Denemark 提交于
This hook is called during the Prepare phase on destination host and may be used for changing domain XML.
-
- 25 2月, 2012 1 次提交
-
-
由 Martin Kletzander 提交于
Function xmlParseURI does not remove square brackets around IPv6 address when parsing. One of the solutions is making wrappers around functions working with xmlURI*. This assures that uri->server will be always properly assigned and it doesn't have to be changed when used on some new place in the code. For this purpose, functions virParseURI and virSaveURI were added. These function are wrappers around xmlParseURI and xmlSaveUri respectively. Also there is one new syntax check function to prohibit these functions anywhere else. File changes: - src/util/viruri.h -- declaration - src/util/viruri.c -- definition - src/libvirt_private.syms -- symbol export - src/Makefile.am -- added source and header files - cfg.mk -- added sc_prohibit_xmlURI - all others -- ID name and include fixes
-
- 23 2月, 2012 1 次提交
-
-
由 Jiri Denemark 提交于
Migrating domains with disks using cache != none is unsafe unless the disk images are stored on coherent clustered filesystem. Thus we forbid migrating such domains unless VIR_MIGRATE_UNSAFE flags is used.
-
- 16 2月, 2012 2 次提交
-
-
由 Jiri Denemark 提交于
When migrating a qemu domain, we enter the monitor, send some commands, try to connect to destination qemu, send other commands, end exit the monitor. However, if we couldn't connect to destination qemu we forgot to exit the monitor. Bug introduced by commit d9d518b1.
-
由 Laine Stump 提交于
An upcoming patch will add a <virtualport> element to interfaces of type='bridge', so it makes sense to give this function a more generic name.
-
- 06 2月, 2012 1 次提交
-
-
由 Jiri Denemark 提交于
Calling qemuDomainMigrateGraphicsRelocate notifies spice clients to connect to destination qemu so that they can seamlessly switch streams once migration is done. Unfortunately, current qemu is not able to accept any connections while incoming migration connection is open. Thus, we need to delay opening the migration connection to the point spice client is already connected to the destination qemu.
-
- 04 2月, 2012 1 次提交
-
-
由 Philipp Hahn 提交于
compat{a->i}bility erron{->e}ous nec{c->}essary. Either "the" or "a". Signed-off-by: NPhilipp Hahn <hahn@univention.de>
-
- 17 1月, 2012 1 次提交
-
-
由 Jiri Denemark 提交于
Commit 5d784bd6 was a nice attempt to clarify the semantics by requiring domain name from dxml to either match original name or dname. However, setting dxml domain name to dname doesn't really work since destination host needs to know the original domain name to be able to use it in migration cookies. This patch requires domain name in dxml to match the original domain name. The change should be safe and backward compatible since migration would fail just a bit later in the process.
-
- 11 1月, 2012 1 次提交
-
-
由 Daniel P. Berrange 提交于
When sVirt is integrated with the LXC driver, it will be neccessary to invoke the security driver APIs using only a virDomainDefPtr since the lxc_container.c code has no virDomainObjPtr available. Aside from two functions which want obj->pid, every bit of the security driver code only touches obj->def. So we don't need to pass a virDomainObjPtr into the security drivers, a virDomainDefPtr is sufficient. Two functions also gain a 'pid_t pid' argument. * src/qemu/qemu_driver.c, src/qemu/qemu_hotplug.c, src/qemu/qemu_migration.c, src/qemu/qemu_process.c, src/security/security_apparmor.c, src/security/security_dac.c, src/security/security_driver.h, src/security/security_manager.c, src/security/security_manager.h, src/security/security_nop.c, src/security/security_selinux.c, src/security/security_stack.c: Change all security APIs to use a virDomainDefPtr instead of virDomainObjPtr
-
- 16 12月, 2011 1 次提交
-
-
由 Peter Krempa 提交于
A generic error code was returned, if the user aborted a migration job. This made it hard to distinguish between a user requested abort and an error that might have occured. This patch introduces a new error code, which is returned in the specific case of a user abort, while leaving all other failures with their existing code. This makes it easier to distinguish between failure while mirgrating and an user requested abort. * include/libvirt/virterror.h: - add new error code * src/util/virterror.c: - add message for the new error code * src/qemu/qemu_migration.h: - Emit operation aborted error instead of operation failed, on migration abort
-
- 30 11月, 2011 1 次提交
-
-
由 Daniel P. Berrange 提交于
The virTimestamp and virTimeMs functions in src/util/util.h duplicate functionality from virtime.h, in a non-async signal safe manner. Remove them, and convert all code over to the new APIs. * src/util/util.c, src/util/util.h: Delete virTimeMs and virTimestamp * src/lxc/lxc_driver.c, src/qemu/qemu_domain.c, src/qemu/qemu_driver.c, src/qemu/qemu_migration.c, src/qemu/qemu_process.c, src/util/event_poll.c: Convert to use virtime APIs
-
- 24 11月, 2011 2 次提交
-
-
由 Jiri Denemark 提交于
If a connection to destination host is lost during peer-to-peer migration (because keepalive protocol timed out), we won't be able to finish the migration and it doesn't make sense to wait for qemu to transmit all data. This patch automatically cancels such migration without waiting for virDomainAbortJob to be called.
-
由 Jiri Denemark 提交于
-
- 19 11月, 2011 2 次提交
-
-
由 Daniel P. Berrange 提交于
Rename the macvtap.c file to virnetdevmacvlan.c to reflect its functionality. Move the port profile association code out into virnetdevvportprofile.c. Make the APIs available unconditionally to callers * src/util/macvtap.h: rename to src/util/virnetdevmacvlan.h, * src/util/macvtap.c: rename to src/util/virnetdevmacvlan.c * src/util/virnetdevvportprofile.c, src/util/virnetdevvportprofile.h: Pull in vport association code * src/Makefile.am, src/conf/domain_conf.h, src/qemu/qemu_conf.c, src/qemu/qemu_conf.h, src/qemu/qemu_driver.c: Update include paths & remove conditional compilation
-
由 Daniel P. Berrange 提交于
In preparation for code re-organization, rename the Macvtap management APIs to have the following patterns virNetDevMacVLanXXXXX - macvlan/macvtap interface management virNetDevVPortProfileXXXX - virtual port profile management * src/util/macvtap.c, src/util/macvtap.h: Rename APIs * src/conf/domain_conf.c, src/network/bridge_driver.c, src/qemu/qemu_command.c, src/qemu/qemu_command.h, src/qemu/qemu_driver.c, src/qemu/qemu_hotplug.c, src/qemu/qemu_migration.c, src/qemu/qemu_process.c, src/qemu/qemu_process.h: Update for renamed APIs
-
- 12 11月, 2011 1 次提交
-
-
由 Eric Blake 提交于
This reverts commit ef1065cf; see also this bug report: https://bugzilla.redhat.com/show_bug.cgi?id=751900 In qemu 0.15.1 and earlier, during migration to file, the qemu_savevm_state_begin and qemu_savevm_state_iterate methods will both process as much migration data as possible until either 1. The file descriptor returns EAGAIN 2. The bandwidth rate limit is reached If we set the rate limit to ULONG_MAX, test 2 never becomes true. We're passing a plain file descriptor to QEMU and POSIX does not support EAGAIN on regular files / block devices, so test 1 never becomes true either. In the 'virsh save --bypass-cache' case, we pass a pipe instead of a regular fd, but using a pipe adds I/O overhead, so always passing a pipe just so qemu can see EAGAIN doesn't seem nice. The ultimate fix needs to come from qemu - background migration must respect asynchronous abort requests, or else periodically return control to the main handling loop without an EAGAIN and without waiting to hit an insanely large amount of data. But until a version of qemu is fixed to support "unlimited" data rates while still allowing cancellation, the best we can do is avoid the automatic use of unlimited rates from within libvirt (users can still explicitly change the migration rates, if they are aware that they are giving up the ability to cancel a job). Reverting the lone use of QEMU_DOMAIN_FILE_MIG_BANDWIDTH_MAX is the simplest patch; this slows migration back down to a default 32M/sec cap, but also ensures that the main qemu processing loop will still be responsive to cancellation requests. Hopefully upstream qemu will provide us a means of safely using unlimited speed, including a runtime probe of that capability. * src/qemu/qemu_migration.c (qemuMigrationToFile): Revert attempt to use unlimited migration bandwidth when migrating to file. Signed-off-by: NDaniel Veillard <veillard@redhat.com> Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 29 10月, 2011 1 次提交
-
-
由 Roopa Prabhu 提交于
- changed some return 1's to return -1 - changed if (rc) error checks to if (rc < 0) - fixed some other minor convention violations I might have missed some. Can fix in another patch or can respin Signed-off-by: NRoopa Prabhu <roprabhu@cisco.com> Reported-by: NEric Blake <eblake@redhat.com> Reported-by: NLaine Stump <laine@laine.org> Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 21 10月, 2011 1 次提交
-
-
由 Eric Blake 提交于
<domainsnapshot> is the first public instance of <domain> being used as a sub-element, although we have two other private uses (runtime state, and migration cookie). Although indentation has no effect on XML parsing, using it makes the output more consistent. This uses virBuffer auto-indentation to obtain the effect, for all but the portions of <domain> that are not generated a line at a time into the same virBuffer. Further patches will clean up the remaining problems. * src/conf/domain_conf.h (virDomainDefFormatInternal): New prototype. * src/conf/domain_conf.c (virDomainDefFormatInternal): Export. (virDomainObjFormat, virDomainSnapshotDefFormat): Update callers. * src/libvirt_private.syms (domain_conf.h): Add new export. * src/qemu/qemu_migration.c (qemuMigrationCookieXMLFormat): Use new function. (qemuMigrationCookieXMLFormatStr): Update caller.
-
- 15 10月, 2011 1 次提交
-
-
由 Jiri Denemark 提交于
Explicitly disallow conflicts between domain name from dxml and dname.
-
- 14 10月, 2011 1 次提交
-
-
由 Eric Blake 提交于
Detected by Coverity. Leak introduced in commit 72de0d28. * src/qemu/qemu_migration.c (qemuMigrationCookieGraphicsXMLParse): Clean up on success.
-
- 04 10月, 2011 1 次提交
-
-
由 Jiri Denemark 提交于
Destination libvirtd remembers the original name in the prepare phase and clears it in the finish phase. The original name is used when comparing domain name in migration cookie.
-
- 29 9月, 2011 1 次提交
-
-
由 Alex Jia 提交于
* src/qemu/qemu_migration.c: if 'vmdef' is NULL, the function virDomainSaveConfig still dereferences it, it doesn't make sense, so should add return value check to make sure 'vmdef' is non-NULL before calling virDomainSaveConfig, in addition, in order to debug later, also should record error information into log. Signed-off-by: NAlex Jia <ajia@redhat.com>
-
- 28 9月, 2011 1 次提交
-
-
由 Jiri Denemark 提交于
If migration failed in Prepare phase after virDomainAssignDef and before a job was started, the domain object was not properly removed.
-
- 27 9月, 2011 1 次提交
-
-
由 Michal Privoznik 提交于
as they are not used with debugging turned off.
-
- 22 9月, 2011 1 次提交
-
-
由 Michal Privoznik 提交于
If a domain has inactive XML we want to transfer it to destination when migrating with VIR_MIGRATE_PERSIST_DEST. In order to harm the migration protocol as least as possible, a optional cookie was chosen.
-