- 26 9月, 2014 1 次提交
-
-
由 Michal Privoznik 提交于
On a domain startup, the variable store path is generated if needed. The path is intended to be generated only once. However, the updated domain definition is not saved into config dir rather than state XML only. So later, whenever the domain is destroyed and the daemon is restarted, the generated path is forgotten and the file may be left behind on virDomainUndefine() call. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 24 9月, 2014 1 次提交
-
-
由 Peter Krempa 提交于
Request erroring out from the backing chain traveller and drop qemu's internal backing chain integrity tester. The backing chain traveller reports errors by itself with possibly more detail than qemuDiskChainCheckBroken ever could. We also need to make sure that we reconnect to existing qemu instances even at the cost of losing the backing chain info (this really should be stored in the XML rather than reloaded from disk, but that needs some work).
-
- 19 9月, 2014 4 次提交
-
-
由 John Ferlan 提交于
Mimic the "Disk" processing for 'rawio', but for a scsi_host hostdev lun device.
-
由 John Ferlan 提交于
Adjust disk definition for 'rawio' to use the TristateBool logic
-
由 John Ferlan 提交于
Commit id '9a2f36ec' added a build conditional of CAP_SYS_RAWIO in order to determine whether or not a disk definition using rawio should be allowed on platforms without CAP_SYS_RAWIO. If one was found, virReportError was used but the code didn't goto cleanup. This patch adds the goto.
-
由 Pavel Hrdina 提交于
We are not detecting the presence of FIPS from QEMU, but from procfs and that means it's not QEMU capability. It was decided that we will pass this flag to QEMU even if it's not supported by old QEMU binaries. This patch also reverts changes done by commit a21cfb0f to qemucapabilitestest and implements a new test case in qemuxml2argvtest. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1135431Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 18 9月, 2014 1 次提交
-
-
由 Ján Tomko 提交于
Plug a memory leak and silence a warning.
-
- 16 9月, 2014 5 次提交
-
-
由 Ján Tomko 提交于
Pass the user-specified tun path down when creating tap device when called from the qemu driver. Also honor the vhost device path specified by user.
-
由 John Ferlan 提交于
Prior to trying the query-iothreads call - check if the qemu has the capability Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
-
由 John Ferlan 提交于
Change "i+1" to "i + 1"
-
由 John Ferlan 提交于
If there are no iothreads, then return from qemuProcessDetectIOThreadPIDs without error; otherwise, the following occurs: error: Failed to start domain $dom error: An error occurred, but the cause is unknown
-
由 John Ferlan 提交于
Modify qemuProcessStart() in order to allowing setting affinity to specific CPU's for IOThreads. The process followed is similar to that for the vCPU's. This involves adding a function to fetch the IOThread id's via qemuMonitorGetIOThreads() and adding them to iothreadpids[] list. Then making sure all the cgroup data has been properly set up and finally assigning affinity.
-
- 11 9月, 2014 1 次提交
-
-
由 John Ferlan 提交于
In qemuProcessInitPCIAddresses() if qemuMonitorGetAllPCIAddresses() returns a negative (or zero) value, then no need to call the qemuProcessDetectPCIAddresses(). Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
-
- 10 9月, 2014 2 次提交
-
-
由 Michal Privoznik 提交于
When using split UEFI image, it may come handy if libvirt manages per domain _VARS file automatically. While the _CODE file is RO and can be shared among multiple domains, you certainly don't want to do that on the _VARS file. This latter one needs to be per domain. So at the domain startup process, if it's determined that domain needs _VARS file it's copied from this master _VARS file. The location of the master file is configurable in qemu.conf. Temporary, on per domain basis the location of master NVRAM file can be overridden by this @template attribute I'm inventing to the <nvram/> element. All it does is holding path to the master NVRAM file from which local copy is created. If that's the case, the map in qemu.conf is not consulted. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Acked-by: NLaszlo Ersek <lersek@redhat.com>
-
由 Jiri Denemark 提交于
Total time of a migration and total downtime transfered from a source to a destination host do not count with the transfer time to the destination host and with the time elapsed before guest CPUs are resumed. Thus, source libvirtd remembers when migration started and when guest CPUs were paused. Both timestamps are transferred to destination libvirtd which uses them to compute total migration time and total downtime. Obviously, this requires the time to be synchronized between the two hosts. The reported times are useless otherwise but they would be equally useless if we didn't do this recomputation so don't lose anything by doing it. Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
-
- 08 9月, 2014 1 次提交
-
-
由 Jiri Denemark 提交于
When QEMU fails during incoming migration after we successfully started it (i.e., during Perform or Finish phase), we report a rather unhelpful message Unable to read from monitor: Connection reset by peer We already have a code that takes error messages from QEMU's error output but we disable it once QEMU successfully starts. This patch postpones this until the end of Finish phase during incoming migration so that we can report a much better error message: internal error: early end of file from monitor: possible problem: Unknown savevm section or instance '0000:00:05.0/virtio-balloon' 0 load of migration failed https://bugzilla.redhat.com/show_bug.cgi?id=1090093Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
-
- 04 9月, 2014 2 次提交
-
-
由 Eric Blake 提交于
I'm about to add a syntax check that enforces our documented HACKING style of always using matching {} on if-else statements. This commit focuses on the qemu driver. * src/qemu/qemu_command.c (qemuParseISCSIString) (qemuParseCommandLineDisk, qemuParseCommandLine) (qemuBuildSmpArgStr, qemuBuildCommandLine) (qemuParseCommandLineDisk, qemuParseCommandLineSmp): Correct use of {}. * src/qemu/qemu_capabilities.c (virQEMUCapsProbeCPUModels): Likewise. * src/qemu/qemu_driver.c (qemuDomainCoreDumpWithFormat) (qemuDomainRestoreFlags, qemuDomainGetInfo) (qemuDomainMergeBlkioDevice): Likewise. * src/qemu/qemu_hotplug.c (qemuDomainAttachNetDevice): Likewise. * src/qemu/qemu_monitor_text.c (qemuMonitorTextCreateSnapshot) (qemuMonitorTextLoadSnapshot, qemuMonitorTextDeleteSnapshot): Likewise. * src/qemu/qemu_process.c (qemuProcessStop): Likewise. Signed-off-by: NEric Blake <eblake@redhat.com>
-
由 Wang Rui 提交于
If virSecurityManagerClearSocketLabel() fails, 'agent' won't be freed before jumping to cleanup. Signed-off-by: NWang Rui <moon.wangrui@huawei.com>
-
- 03 9月, 2014 1 次提交
-
-
由 Chunyan Liu 提交于
Add umask to _virCommand, allow user to set umask to command. Set umask(002) to qemu process to overwrite the default umask of 022 set by many distros, so that unix sockets created for virtio-serial has expected permissions. Fix problem reported here: https://sourceware.org/bugzilla/show_bug.cgi?id=13078#c11 https://bugzilla.novell.com/show_bug.cgi?id=888166 To use virtio-serial device, unix socket created for chardev with default umask(022) has insufficient permissions. e.g.: -device virtio-serial \ -chardev socket,path=/tmp/foo,server,nowait,id=foo \ -device virtserialport,chardev=foo,name=org.fedoraproject.port.0 srwxr-xr-x 1 qemu qemu 0 21. Jul 14:19 /tmp/somefile.sock Other users in the same group (like real user, test engines, etc) cannot write to this socket. Signed-off-by: NChunyan Liu <cyliu@suse.com> Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 22 8月, 2014 1 次提交
-
-
由 Erik Skultety 提交于
The 'min_guarantee' is used by VMware ESX and OpenVZ drivers, with qemu however, libvirt should report error when starting a domain, because this element is not used. Resolves https://bugzilla.redhat.com/show_bug.cgi?id=1122455
-
- 20 8月, 2014 1 次提交
-
-
由 Roman Bogorodskiy 提交于
Currently, qemu driver uses qemuTranslateDiskSourcePool() to translate disk volume information. This function is general enough and could be used for other drivers as well, so move it to conf/domain_conf.c along with its helpers. - qemuTranslateDiskSourcePool: move to storage/storage_driver.c and rename to virStorageTranslateDiskSourcePool, - qemuAddISCSIPoolSourceHost: move to storage/storage_driver.c and rename to virStorageAddISCSIPoolSourceHost, - qemuTranslateDiskSourcePoolAuth: move to storage/storage_driver.c and rename to virStorageTranslateDiskSourcePoolAuth, - Update users of qemuTranslateDiskSourcePool to use a new name.
-
- 18 8月, 2014 3 次提交
-
-
由 Peter Krempa 提交于
Pin existing vcpus rather than existing vcpu pinning infos. This increases the complexity of the lookup, but avoids pinning cpus that are not enabled actually.
-
由 Peter Krempa 提交于
We set just one affinity of the emulator and the virConnectPtr isn't needed for that function.
-
由 Erik Skultety 提交于
When editing guest's XML (on QEMU), it was possible to add multiple listen elements into graphics parent element. However QEMU does not support listening on multiple addresses. Configuration is tested for multiple 'listen address' and if positive, an error is raised. https://bugzilla.redhat.com/show_bug.cgi?id=1119212
-
- 15 8月, 2014 1 次提交
-
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 14 8月, 2014 1 次提交
-
-
由 Sam Bobroff 提交于
During a QEMU live migration several warning messages about job handling could be written to syslog on the destination host: "entering monitor without asking for a nested job is dangerous" The messages are written because the job handling during migration uses hard coded asyncJob values in several places that are incorrect. This patch passes the required asyncJob value around and prevents the warnings as well as any issues that the warnings may be referring to. https://bugzilla.redhat.com/show_bug.cgi?id=1130089Signed-off-by: NSam Bobroff <sam.bobroff@au1.ibm.com> Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
- 12 8月, 2014 1 次提交
-
-
由 Peter Krempa 提交于
Fix header alignment and remove the unused conn parameter.
-
- 30 7月, 2014 3 次提交
-
-
由 Eric Blake 提交于
A future patch is going to wire up qemu active block commit jobs; but as they have similar events and are canceled/pivoted in the same way as block copy jobs, it is easiest to track all bookkeeping for the commit job by reusing the <mirror> element. This patch adds domain XML to track which job was responsible for creating a mirroring situation, and adds a job='copy' attribute to all existing uses of <mirror>. Along the way, it also massages the qemu monitor backend to read the new field in order to generate the correct type of libvirt job (even though it requires a future patch to actually cause a qemu event that can be reported as an active commit). It also prepares to update persistent XML to match changes made to live XML when a copy completes. * docs/schemas/domaincommon.rng: Enhance schema. * docs/formatdomain.html.in: Document it. * src/conf/domain_conf.h (_virDomainDiskDef): Add a field. * src/conf/domain_conf.c (virDomainBlockJobType): String conversion. (virDomainDiskDefParseXML): Parse job type. (virDomainDiskDefFormat): Output job type. * src/qemu/qemu_process.c (qemuProcessHandleBlockJob): Distinguish active from regular commit. * src/qemu/qemu_driver.c (qemuDomainBlockCopy): Set job type. (qemuDomainBlockPivot, qemuDomainBlockJobImpl): Clean up job type on completion. * tests/qemuxml2xmloutdata/qemuxml2xmlout-disk-mirror-old.xml: Update tests. * tests/qemuxml2argvdata/qemuxml2argv-disk-mirror.xml: Likewise. * tests/qemuxml2argvdata/qemuxml2argv-disk-active-commit.xml: New file. * tests/qemuxml2xmltest.c (mymain): Drive new test. Signed-off-by: NEric Blake <eblake@redhat.com>
-
由 Eric Blake 提交于
We were not directly saving the domain XML to file after starting or finishing a blockcopy. Without the startup write, a libvirtd restart in the middle of a copy job would forget that the job was underway. Then at pivot, we were indirectly writing new XML in reaction to events that occur as we stop and restart the guest CPUs. But there was a race: since pivot is an async action, it is possible that libvirtd is restarted before the pivot completes, so if XML changes during the event, that change was not written. The original blockcopy code cleared out the <mirror> element prior to restarting the CPUs, but this is also a race, observed if a user does an async pivot and a dumpxml before the event occurs. Furthermore, this race will interfere with active commit in a future patch, because that code will rely on the <mirror> element at the time of the qemu event to determine whether to inform the user of a normal commit or an active commit. Fix things by saving state any time we modify live XML, while delaying XML disk modifications until after the event completes. We still need a to teach libvirtd restarts to examine all existing <mirror> elements to see if the job completed in the meantime (that is, if libvirtd misses the event, the updated state still needs to be updated in live XML), but that will be a later patch, in part because we also need to to start taking advantage of newer qemu's ability to keep the job around after completion rather than the current usage where the job disappears both on error and on success. * src/qemu/qemu_driver.c (qemuDomainBlockCopy): Track XML change on disk. (qemuDomainBlockJobImpl, qemuDomainBlockPivot): Move job-end XML rewrites... * src/qemu/qemu_process.c (qemuProcessHandleBlockJob): ...here. Signed-off-by: NEric Blake <eblake@redhat.com>
-
由 Eric Blake 提交于
Doing a blockcopy operation across a libvirtd restart is not very robust at the moment. In particular, we are clearing the <mirror> element prior to telling qemu to finish the job. Also, thanks to the ability to request async completion, the user can easily regain control prior to qemu actually finishing the effort, and they should be able to poll the domain XML to see if the job is still going. A future patch will fix things to actually wait until qemu is done before modifying the XML to reflect the job completion. But since qemu issues identical BLOCK_JOB_COMPLETE events regardless of whether the job was cancelled (kept the original disk) or completed (pivoted to the new disk), we have to track which of the two operations were used to end the job. Furthermore, we'd like to avoid attempts to end a job where we are already waiting on an earlier request to qemu to end the job. Likewise, if we miss the qemu event (perhaps because it arrived during a libvirtd restart), we still need enough state recorded to be able to determine how to modify the domain XML once we reconnect to qemu and manually learn whether the job still exists. Although this patch doesn't actually fix the problem, it is a preliminary step that makes it possible to track whether a job has already begun steps towards completion. * src/conf/domain_conf.h (virDomainDiskMirrorState): New enum. (_virDomainDiskDef): Convert bool mirroring to new enum. * src/conf/domain_conf.c (virDomainDiskDefParseXML) (virDomainDiskDefFormat): Handle new values. * src/qemu/qemu_process.c (qemuProcessHandleBlockJob): Adjust client. * src/qemu/qemu_driver.c (qemuDomainBlockPivot) (qemuDomainBlockJobImpl): Likewise. * docs/schemas/domaincommon.rng (diskMirror): Expose new values. * docs/formatdomain.html.in (elementsDisks): Document it. * tests/qemuxml2argvdata/qemuxml2argv-disk-mirror.xml: Test it. Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 29 7月, 2014 2 次提交
-
-
由 Michal Privoznik 提交于
<memoryBacking> <hugepages> <page size="1" unit="G" nodeset="0-3,5"/> <page size="2" unit="M" nodeset="4"/> </hugepages> </memoryBacking> Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Michal Privoznik 提交于
Use better detection of hugetlbfs mount points. Yes, there can be multiple mount points each serving different huge page size. Since we already have ability to override the mount point in the qemu.conf file, this crazy backward compatibility code is brought in. Now we allow multiple mount points, so the "hugetlbfs_mount" option must take an list of strings (mount points). But previously, it was just a string, so we must accept both types now. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 23 7月, 2014 1 次提交
-
-
由 Ján Tomko 提交于
For the values "default", "on", "off" Replaces virDeviceAddressPCIMulti virDomainFeatureState virDomainIoEventFd virDomainVirtioEventIdx virDomainDiskCopyOnRead virDomainMemDump virDomainPCIRombarMode virDomainGraphicsSpicePlaybackCompression
-
- 17 7月, 2014 3 次提交
-
-
由 Martin Kletzander 提交于
When domain is started with numatune memory mode strict and the nodeset does not include host NUMA node with DMA and DMA32 zones, KVM initialization fails. This is because cgroup restrict even kernel allocations. We are already doing numa_set_membind() which does the same thing, only it does not restrict kernel allocations. This patch leaves the userspace numa_set_membind() in place and moves the cpuset.mems setting after the point where monitor comes up, but before vcpu and emulator sub-groups are created. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
由 Martin Kletzander 提交于
There were numerous places where numatune configuration (and thus domain config as well) was changed in different ways. On some places this even resulted in persistent domain definition not to be stable (it would change with daemon's restart). In order to uniformly change how numatune config is dealt with, all the internals are now accessible directly only in numatune_conf.c and outside this file accessors must be used. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
由 Martin Kletzander 提交于
Since there was already public virDomainNumatune*, I changed the private virNumaTune to match the same, so all the uses are unified and public API is kept: s/vir\(Domain\)\?Numa[tT]une/virDomainNumatune/g then shrunk long lines, and mainly functions, that were created after that: sed -i 's/virDomainNumatuneMemPlacementMode/virDomainNumatunePlacement/g' And to cope with the enum name, I haad to change the constants as well: s/VIR_NUMA_TUNE_MEM_PLACEMENT_MODE/VIR_DOMAIN_NUMATUNE_PLACEMENT/g Last thing I did was at least a little shortening of already long name: s/virDomainNumatuneDef/virDomainNumatune/g Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 10 7月, 2014 1 次提交
-
-
由 Ján Tomko 提交于
This saves a few lines of code and catches the error when: <spice autoport ='yes' defaultMode='any' ..> <channel name='main' mode='secure'/> </spice> is specified with spice_tls = 0 in qemu.conf. Instead of this error in qemuBuildGraphicsSPICECommandLine: error: unsupported configuration: spice secure channels set in XML configuration, but TLS port is not provided an error is reported in qemuProcessSPICEAllocatePorts: error: unsupported configuration: Auto allocation of spice TLS port requested but spice TLS is disabled in qemu.conf Inspired by: https://www.redhat.com/archives/libvir-list/2014-June/msg01408.html
-
- 02 7月, 2014 2 次提交
-
-
由 Ján Tomko 提交于
Add suport for invariant TSC flag (CPUID 0x80000007, bit 8 of EDX). If this flag is enabled, the TSC ticks at a constant rate across all ACPI P-, C- and T-states. This can be enabled by adding: <feature name='invtsc'/> to the <cpu> element. Migration and saving the domain does not work with this flag. QEMU support: http://git.qemu.org/?p=qemu.git;a=commitdiff;h=303752a The feature name "invtsc" differs from the name "" used by the linux kernel: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/x86/kernel/cpu/powerflags.c?id=30321c7b#n18
- 25 6月, 2014 1 次提交
-
-
由 Julio Faracco 提交于
As we are doing with the enum structures, a cleanup in "src/qemu/" directory was done now. All the enums that were defined in the header files were converted to typedefs in this directory. This patch includes all the adjustments to remove conflicts when you do this kind of change. "Enum-to-typedef"'s conversions were made in "src/qemu/qemu_{capabilities, domain, migration, hotplug}.h". Signed-off-by: NJulio Faracco <jcfaracco@gmail.com>
-