- 20 6月, 2019 1 次提交
-
-
由 Peter Krempa 提交于
When testing stuff you might want to print the XML. Interlocking it with no metadata adds exactly 0 value to the user. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
- 19 6月, 2019 1 次提交
-
-
由 Jonathon Jongsma 提交于
Signed-off-by: NJonathon Jongsma <jjongsma@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
- 17 6月, 2019 1 次提交
-
-
由 Daniel P. Berrangé 提交于
Reviewed-by: NLaine Stump <laine@laine.org> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
- 10 6月, 2019 1 次提交
-
-
由 Johannes Holmberg 提交于
Signed-off-by: NJohannes Holmberg <johannes.holmberg@dataductus.se> Reviewed-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 06 6月, 2019 3 次提交
-
-
由 Peter Krempa 提交于
The flag causes undefine to fail if trying to remove a non-RBD disk. Add a warning about that. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NFabiano Fidêncio <fidencio@redhat.com> ACKed-by: NEric Blake <eblake@redhat.com>
-
由 Peter Krempa 提交于
The old flag name confused some users into thinking it's the correct way to undefine a VM with libvirt (not storage volume) snapshots. The correct flag in that case is way less obvious: --snapshots-metadata. Rename the flag (by adding an alias) to something which will promote looking up the actual purpose of the flag. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NFabiano Fidêncio <fidencio@redhat.com> ACKed-by: NEric Blake <eblake@redhat.com>
-
由 Peter Krempa 提交于
Reword the end of the help string to make it more obvious that the VM must be inactive. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NFabiano Fidêncio <fidencio@redhat.com> ACKed-by: NEric Blake <eblake@redhat.com>
-
- 20 5月, 2019 1 次提交
-
-
由 Han Han 提交于
Qemu added reporting of virtio balloon new statistics stat-htlb-pgalloc and stat-htlb-pgfail since qemu-3.0 commit b7b12644297. The value of stat-htlb-pgalloc represents the number of successful hugetlb page allocations while stat-htlb-pgfail represents the number of failed ones. Add this statistics reporting to libvirt. To enable this feature for vm, guest kenel >= 4.17 is required because the exporting hugetlb page allocation for virtio balloon is introduced since 6c64fe7f. Signed-off-by: NHan Han <hhan@redhat.com> Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 13 5月, 2019 1 次提交
-
-
由 Michal Privoznik 提交于
The virDomainGetDiskErrors() API copies disk targets into @disks array that we allocate. But we forgot to free it: ==140828== 16 bytes in 4 blocks are definitely lost in loss record 41 of 242 ==140828== at 0x4C2F08F: malloc (vg_replace_malloc.c:299) ==140828== by 0x8C406D9: strdup (in /lib64/libc-2.28.so) ==140828== by 0x5377DD3: virStrdup (virstring.c:966) ==140828== by 0x54C112F: testDomainGetDiskErrors (test_driver.c:3068) ==140828== by 0x55C863D: virDomainGetDiskErrors (libvirt-domain.c:10988) ==140828== by 0x15D1FA: cmdDomBlkError (virsh-domain-monitor.c:1215) ==140828== by 0x17F1A8: vshCommandRun (vsh.c:1335) ==140828== by 0x13489E: main (virsh.c:920) Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 30 4月, 2019 1 次提交
-
-
由 John Ferlan 提交于
Commit a3dbaa36 neglected to add the source-protocol-ver to the pool-define-as command. Signed-off-by: NJohn Ferlan <jferlan@redhat.com> ACKed-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 26 4月, 2019 1 次提交
-
-
由 Michal Privoznik 提交于
Each attribute is on its own line. We forgot to add new line character for <alias/> Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 16 4月, 2019 1 次提交
-
-
由 Andrea Bolognani 提交于
The table included in the sample output for 'list --title' is unnecessarily wide, which causes man to complain: warning [p 8, 0.5i]: can't break line Make the table narrower. Spotted by Lintian (manpage-has-errors-from-man tag). Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 15 4月, 2019 2 次提交
-
-
由 Andrea Bolognani 提交于
Apparently "allow(s) to frobnicate" is not correct English, and either "allow(s) one to frobnicate" or "allow(s) frobnicating" should be used instead. Spotted by Lintian (spelling-error-in-{binary,manpage} tags). Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com>
-
由 Andrea Bolognani 提交于
Though it used to be called "Mac OS X" and "OS X" in the past, it was never "MacOS X" nor "OS-X", and it's just "macOS" now. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 12 4月, 2019 2 次提交
-
-
由 Andrea Bolognani 提交于
This code is needed to use readline older than 4.1, but all our target platforms ship with at least 6.0 these days so we can safely get rid of it. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Cole Robinson 提交于
Standardize on putting the _LAST enum value on the second line of VIR_ENUM_IMPL invocations. Later patches that add string labels to VIR_ENUM_IMPL will push most of these to the second line anyways, so this saves some noise. Signed-off-by: NCole Robinson <crobinso@redhat.com>
-
- 11 4月, 2019 1 次提交
-
-
由 Michal Privoznik 提交于
This completer is used to offer shutdown/reboot modes. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NCole Robinson <crobinso@redhat.com>
-
- 10 4月, 2019 1 次提交
-
-
由 Peter Krempa 提交于
virutil.(c|h) is a very gross collection of random code. Remove the enum handlers from there so we can limit the scope where virtutil.h is used. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
- 04 4月, 2019 6 次提交
-
-
由 Nikolay Shirokovskiy 提交于
If the console was disconnected due to a connection problem or a problem on the server side it is convinient to provide the cause to the user. If the error come from the API then the error is saved in a virsh global variable. However, since success is returned from virshRunConsole after we reach the waiting stage, then the error is never reported. Let's track the error in the event loop. Next after failure we do a cleanup and this cleanup can overwrite root cause. Thus let's save root cause immediately and then set it to virsh error after all cleanup is done. Since we'll be sending the error to the consumer, each failure path from the event handlers needs to be augmented to provide what error generated the failure. Reviewed-by: NCole Robinson <crobinso@redhat.com> Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
On error in main thread virConsoleShutdown is called which deletes fd watches/stream callback and yet callbacks can be called after. Thus we can incorrectly allocate terminalToStream.data memory and get memory leak for example. Let's check if console was shutdown in the very beginning of callbacks. Reviewed-by: NCole Robinson <crobinso@redhat.com> Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
Stream/fd callbacks accessing console object are called from the event loop thread and the console object is also accessed from the main thread so we are better add locking to handlers. Reviewed-by: NCole Robinson <crobinso@redhat.com> Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
We only check now for virObjectWait failures in virshRunConsole but we'd better check and for other failures too. And we need to shutdown console on error in the main thread. Reviewed-by: NCole Robinson <crobinso@redhat.com> Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
We need to turn console into virObject object because stream/fd callbacks can be called from the event loop thread after freeing console in main thread. It is convinient to turn into virLockableObject as we have mutex in console object. Reviewed-by: NCole Robinson <crobinso@redhat.com> Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Han Han 提交于
Add native guest format of BSD hypervisor and VMware/ESX. Quote native guest format of domxml-from-native for domxml-to-native. Reviewed-by: NCole Robinson <crobinso@redhat.com> Signed-off-by: NHan Han <hhan@redhat.com>
-
- 03 4月, 2019 12 次提交
-
-
由 Peter Krempa 提交于
Refactor code paths which clear strings on cleanup paths to use the automatic helper. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
A helper function that takes a XML node with a "size" and "unit" attributes and converts it into a human-readable string. Reduce the size and number of variables in the parent function. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Now that we have a shared cleanup section everywhere, delete all the 'error' labels which all contain just 'goto cleanup' anyway. Also remove all the 'cleanup' labels that only 'return ret' - we can simply return NULL instead of jumping to that label. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
We've been open-coding virStringListFreeCount for cleaning up the completion list we're building. This had the advantage of zeoring the pointer afterwards, which is no longer needed now that we compile the list in 'tmp' instead of 'ret'. Since all our lists are NULL-terminated anyway, switch to using virStringListFree via the VIR_AUTOSTRINGLIST macro. Fixes nearly impossible NULL dereferences in virshNWFilterBindingNameCompleter virshNWFilterNameCompleter virshNodeDeviceNameCompleter virshNetworkNameCompleter virshInterfaceNameCompleter virshStoragePoolNameCompleter virshDomainNameCompleter which jumped on the error label after a failed allocation and a possible one in virshStorageVolNameCompleter which jumped there when we fail to fetch the list of volumes. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Merge the cleanup of fetched items for the success and the error paths. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Unify the cleanup paths for error and success. Now that 'ret' is only set (from tmp) on the success path, it is safe to jump right before 'return ret' after processing the error block. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Construct the potential return value in an array called 'tmp' and only assign it to 'ret' if we're going to return it. This will allow us to unify the error and success paths. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Use the posessive determiner instead of a contracted auxiliary. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
由 Ján Tomko 提交于
Use four spaces instead of three. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
- 30 3月, 2019 1 次提交
-
-
由 John Ferlan 提交于
Update the wording to note the values for polling are purely dynamic and won't be saved across domain stop/(re)start or save/restore. Signed-off-by: NJohn Ferlan <jferlan@redhat.com> Reviewed-by: NLaine Stump <laine@laine.org>
-
- 29 3月, 2019 1 次提交
-
-
由 Eric Blake 提交于
Most of our completers used the pattern: if ((nITEM = virITEMListAll()) < 0) return NULL; but the virDomainSnapshot and virStorageVolume completers were instead using goto error. If the ListAll fails with -1, the cleanup label was running a loop of 'size_t i < int nITEM', which is an extreme waste of CPU cycles. Broken since their introduction in v4.1. Fixes: f81f8b62 Fixes: 4cb4b649Reported-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 27 3月, 2019 1 次提交
-
-
由 Jiri Denemark 提交于
Signed-off-by: NJiri Denemark <jdenemar@redhat.com> Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
-
- 25 3月, 2019 1 次提交
-
-
由 Eric Blake 提交于
Since test:///default resets state on every connection, writing a test that covers a sequence of commands must be done from a single session. But if the test wants to exercise particular failure modes as well as successes, it can be nice to leave witnesses in the stderr stream immediately before and after the spot where the expected error should be, to ensure the rest of the script is not causing errors. Do this by adding an --err option. Signed-off-by: NEric Blake <eblake@redhat.com> Acked-by: NMichal Privoznik <mprivozn@redhat.com>
-