- 21 5月, 2019 16 次提交
-
-
由 Peter Krempa 提交于
Use VIR_AUTOFREE and VIR_AUTOUNREF. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Peter Krempa 提交于
Use VIR_AUTOFREE and VIR_AUTOUNREF. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Peter Krempa 提交于
Use VIR_AUTOFREE, VIR_AUTOUNREF, and VIR_STEAL_PTR. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Peter Krempa 提交于
When aborting or pivoting a block job we record which operation we do for the mirror in the virDomainDiskDef structure. As everything is synchronized by a job it's not necessary to modify the state prior to calling the monitor and resetting the state on failure. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Peter Krempa 提交于
All blockjobs get their status updated by events from qemu, so this code no longer makes sense. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Peter Krempa 提交于
When used with the new job handler the values will also include some of the non-public values from qemuBlockjobState. Modify the comment to clarify this. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Peter Krempa 提交于
As of commit d1a44634 this field is unused. Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Daniel P. Berrangé 提交于
The virtlogd daemon's only intended client is the libvirtd daemon. As such it should never allow clients from other user accounts to connect. The code already enforces this and drops clients from other UIDs, but we can get earlier (and thus stronger) protection against DoS by setting the socket permissions to 0600 Fixes CVE-2019-10132 Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Daniel P. Berrangé 提交于
The virtlockd daemon's only intended client is the libvirtd daemon. As such it should never allow clients from other user accounts to connect. The code already enforces this and drops clients from other UIDs, but we can get earlier (and thus stronger) protection against DoS by setting the socket permissions to 0600 Fixes CVE-2019-10132 Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Daniel P. Berrangé 提交于
The admin protocol RPC messages are only intended for use by the user running the daemon. As such they should not be allowed for any client UID that does not match the server UID. Fixes CVE-2019-10132 Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Michal Privoznik 提交于
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
由 Michal Privoznik 提交于
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
由 Michal Privoznik 提交于
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
由 Michal Privoznik 提交于
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
由 Michal Privoznik 提交于
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
由 Michal Privoznik 提交于
In attempt to getting rid of errN labels let's start with the most upper one and rename it to 'error'. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
- 20 5月, 2019 4 次提交
-
-
由 Michal Privoznik 提交于
This reverts commit dfd70ca1. Pushed by a mistake, sorry. There's still some discussion going on upstream. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Daniel P. Berrangé 提交于
The libvirt-daemon-driver-qemu RPM has historically had a hard dependency on the libvirt-daemon-driver-network and libvirt-daemon-driver-storage-core packages. This was because the QEMU driver would directly call into APIs that were part of these drivers. The dependency to the storage driver was eliminated in commit 064fec69 Author: Daniel P. Berrangé <berrange@redhat.com> Date: Thu Jan 25 09:35:46 2018 +0000 storage: move storage file backend framework into util directory The dependency to the network driver was eliminated in commit 5b13570a Author: Daniel P. Berrangé <berrange@redhat.com> Date: Thu Jan 25 09:35:47 2018 +0000 conf: introduce callback registration for domain net device allocation commit 1438aea4 Author: Daniel P. Berrangé <berrange@redhat.com> Date: Thu Jan 25 09:35:48 2018 +0000 conf: expand network device callbacks to cover bandwidth updates Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 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>
-
由 Maxiwell S. Garcia 提交于
Snapshot create operation saves the live XML and uses it to replace the domain definition in case of revert. But the VM config XML is not saved and the revert operation does not address this issue. This commit prevents the config XML from being overridden by snapshot definition. An active domain stores both current and new definitions. The current definition (vm->def) stores the live XML and the new definition (vm->newDef) stores the config XML. In an inactive domain, only the config XML is persistent, and it's saved in vm->def. The revert operation uses the virDomainObjAssignDef() to set the snapshot definition in vm->newDef, if domain is active, or in vm->def otherwise. But before that, it saves the old value to return to caller. This return is used here to restore the config XML after all snapshot startup process finish. Signed-off-by: NMaxiwell S. Garcia <maxiwell@linux.ibm.com>
-
- 17 5月, 2019 14 次提交
-
-
由 Andrea Bolognani 提交于
We can't rely on $(noinst_PROGRAMS) retaining its original value, so let's use a separate $(EXAMPLES) variable instead. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Michal Privoznik 提交于
If an FD is passed into a child using: virCommandPassFD(cmd, fd, VIR_COMMAND_PASS_FD_CLOSE_PARENT); then the parent should refrain from touching @fd thereafter. This is even documented in virCommandPassFD() comment. The reason is that either at virCommandRun()/virCommandRunAsync() or virCommandFree() time the @fd will be closed. Closing it earlier, e.g. right after virCommandPassFD() call might result in undesired results. Another thread might open a file and receive the same FD which is then unexpectedly closed by virCommandFree() or virCommandRun(). Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Daniel P. Berrangé 提交于
Various binaries are statically linking to libvirt_util.la and other intermediate libraries we build. These intermediate libs all get built into the main libvirt.so shared library eventually, so we can dynamically link to that instead and reduce the on disk footprint. In libvirt-daemon RPM: virtlockd: 1.6 MB -> 153 KB virtlogd: 1.6 MB -> 157 KB libvirt_iohelper: 937 KB -> 23 KB In libvirt-daemon-driver-network RPM: libvirt_leaseshelper: 940 KB -> 26 KB In libvirt-daemon-driver-storage-core RPM: libvirt_parthelper: 926 KB -> 21 KB IOW, about 5.6 MB total space saving in a build done on Fedora 30 x86_64 architecture. Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Michal Privoznik 提交于
We provide default values for both MODPROBE and RMMOD and thus there is no way that their paths can be empty strings. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Michal Privoznik 提交于
https://bugzilla.redhat.com/show_bug.cgi?id=1710575 It may happen that the system where libvirt is built at doesn't have udevadm binary but the one where it runs does have it. If we change how udevadm is run in virWaitForDevices() then we can safely pass a default value in m4 macro. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Michal Privoznik 提交于
The udevsettle binary is no longer used anywhere as it was replaced by 'udevadm settle'. There's no reason for us to even check for it in configure. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Michal Privoznik 提交于
It's not true that there is a backup loop. There isn't. Drop this part of the comment to not confuse anybody. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Andrea Bolognani 提交于
Since we know the full list of machine types supported by the QEMU binary when probing machine type properties, we can save some work (and eventually test suite churn, as more architecture-specific machine types need to be probed) by only probing machines that we know exist. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Andrea Bolognani 提交于
Now that we're probing machine type properties using the latest machine type rather than the "spapr-machine" parent, we can finally discover properties that are not available on all machine types. This commit refreshes replies for QEMU 4.0.0 as well as 3.1.0 to show not only that we're actually discovering new machine type properties this way, but also that the number of available machine type properties increases with each subsequent QEMU release. If qom-list-properties had been available in QEMU 2.10.0, we could now drop the explicit version number checks for the QEMU_CAPS_MACHINE_PSERIES_MAX_CPU_COMPAT and QEMU_CAPS_MACHINE_PSERIES_RESIZE_HPT capabilities, but unfortunately it wasn't, so we have to keep them around still. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Andrea Bolognani 提交于
Now that we have the list of machine types available when probing machine type properties, we can list properties for the canonicalized version of the "pseries" machine type instead of having to go through "spapr-machine", which we know to be the parent type for all "pseries-*-machine" types. By doing this, we'll be able to find even properties that are only available from a certain versioned machine type forward, and can't thus be obtained when looking at the parent type only. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Andrea Bolognani 提交于
The QOM type for machine types is the machine type name followed by the -machine suffix. Since this is always the case, we can make virQEMUCapsMachineProps more readable and avoid repetition by not including the suffix there and adding it automatically while processing the data; moreover, when later on we will start figuring out which specific versioned machine type to probe at runtime instead of doing so statically, adding the suffix dynamically will become necessary. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Andrea Bolognani 提交于
We're going to need information about available machine types when probing machine type properties soon, and that means we have to change the order we call QMP commands. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Andrea Bolognani 提交于
Up until now we've probed machine type properties, along with properties for other types, in virQEMUCapsProbeQMPDevices(), but soon we're going to need some logic that is specific to machine types and as such wouldn't quite fit into that function. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Peter Krempa 提交于
Commit c2573527 introduced a logic bug where we will never save the inactive XML after a blockjob as the variable which was determining whether to do so is cleared right before. Thus even if we correctly modify the inactive state it will be rolled back when libvirtd is restarted. Reported-by: NThomas Stein <hello@himbee.re> Signed-off-by: NPeter Krempa <pkrempa@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
- 16 5月, 2019 3 次提交
-
-
由 Ján Tomko 提交于
It has been exported by systemd commit commit a571c23e954cb88cdd5faa28593b19bd7c340130 libudev: export udev_monitor_set_receive_buffer_size() released in v183. Signed-off-by: NJán Tomko <jtomko@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Ján Tomko 提交于
This is the version of systemd RHEL/CentOS 7 uses: https://repology.org/project/systemd/versions Oldest tracked openSUSE distros have 228, Ubuntu 16.04 has 229 and Gentoo's alternative eudev has bumped the version to 219 back in 2015. Signed-off-by: NJán Tomko <jtomko@redhat.com> Reviewed-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Christian Ehrhardt 提交于
When a vhost scsi device is hotplugged virt-aa-helper is called to add the respective path. For example the config: <hostdev mode='subsystem' type='scsi_host' managed='no'> <source protocol='vhost' wwpn='naa.50014059de6fba4f'/> </hostdev> Will call it to add: /sys/kernel/config/target/vhost//naa.50014059de6fba4f But in general /sys paths are filtered in virt-aa-helper.c:valid_path To allow the path used for vhost-scsi we need to add it to the list of known and accepted overrides. Fixes: https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/1829223Signed-off-by: NChristian Ehrhardt <christian.ehrhardt@canonical.com> Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
-
- 15 5月, 2019 3 次提交
-
-
由 Pavel Hrdina 提交于
The function was deprecated in udev 219 and all the supported OSes don't have older version of udev or systemd. Signed-off-by: NPavel Hrdina <phrdina@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Christian Ehrhardt 提交于
CPU features that always were a no-op in qemu got removed there. We no more specify them as that would trigger errors and fail to start qemu. This test ensures that those features really are not rendered into qemu command line. Without the related fix this test will trigger and fail like: In 'tests/qemuxml2argvdata/cpu-no-removed-features.args': Offset 371 Expect [ ] Actual [,-osxsave,-ospke ] Signed-off-by: NChristian Ehrhardt <christian.ehrhardt@canonical.com> Reviewed-by: NDaniel Henrique Barboza <danielhb413@gmail.com> Tested-by: NDaniel Henrique Barboza <danielhb413@gmail.com>
-
由 Christian Ehrhardt 提交于
Qemu dropped cpu features for osxsave and ospke [1][2]. The reason for the instant removal is that those features were never configurable as discussed in [3]. Fortunately the use cases adding those flags in the past are rare, but they exist. One that I identified are e.g. older virt-install when used with --cpu=host-model and there always could be the case of a user adding it to the guest xml. This triggers an issue like: qemu-system-x86_64: can't apply global Broadwell-noTSX-x86_64- cpu.osxsave=on: Property '.osxsave' not found Ensure that this does no more break spawning newer qemu versions by not rendering those features into the qemu command line. Fixes: https://bugs.launchpad.net/fedora/+source/qemu/+bug/1825195 Resolves: https://bugzilla.redhat.com/1644848 [1]: https://git.qemu.org/?p=qemu.git;a=commit;h=f1a2352 [2]: https://git.qemu.org/?p=qemu.git;a=commit;h=9ccb978 [3]: https://www.mail-archive.com/qemu-devel@nongnu.org/msg561877.htmlSigned-off-by: NChristian Ehrhardt <christian.ehrhardt@canonical.com> Reviewed-by: NDaniel Henrique Barboza <danielhb413@gmail.com> Tested-by: NDaniel Henrique Barboza <danielhb413@gmail.com>
-