5
0
mirror of git://git.proxmox.com/git/qemu-server.git synced 2025-02-18 17:57:43 +03:00

752 Commits

Author SHA1 Message Date
Wolfgang Link
5f96f4df75 add possibility to restore backup on rbd in krbd mode 2015-09-09 07:47:42 +02:00
Wolfgang Link
116da78402 add krbd support to online snapshot 2015-09-09 07:22:20 +02:00
Dietmar Maurer
ad9a140f88 fix install path 2015-09-07 11:33:44 +02:00
Dietmar Maurer
335af808a4 improve bash completion 2015-09-07 08:13:07 +02:00
Dietmar Maurer
65e866e5da implement a few bash completion helpers 2015-09-06 16:01:59 +02:00
Dietmar Maurer
f3e76e36bc covert qm into a PVE::CLI class, enable bash completions 2015-09-06 15:44:53 +02:00
Alen Grizonic
cb0e4540f7 VM protection mode added
used to prevent an unintended virtual machine remove operation

v3 changes:

- changed man page message
- removed protection parameter (where not needed)
2015-09-06 11:31:05 +02:00
Wolfgang Link
1dbd6d30e0 fix move_disk on RBD
activating the disk when use RBD is necessary to have the given path.
2015-09-06 11:05:51 +02:00
Dietmar Maurer
952e3ac30f cleanup previous patch 2015-08-28 18:16:08 +02:00
Alen Grizonic
e9f2f8e5f9 HA resources check before destroying vm 2015-08-28 15:32:44 +02:00
Dietmar Maurer
d853f40aef fix: start kvm with os type other
this check is necessary, because we do not set ostype in qemu config when type is other

Seem that x2apic is now enabled by default when kvm is used

since this commit
http://git.qemu.org/?p=qemu.git;a=commit;h=ef02ef5f4536dba090b12360a6c862ef0e57e3bc

So we just need to disable it for solaris
2015-08-28 11:10:44 +02:00
Thomas Lamprecht
7f9e28e45c fix 'uninitialized value in concat' due to unnamed VM
This is an minor fix which let's you start the spice console on an
unnamed VM without getting the 'Use of uninitialized value in
concatenation' error.
Also changes the trailing comma from the $conf definition lineto an
semicolon.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2015-08-28 10:36:51 +02:00
Alen Grizonic
457010cc48 clone vm firewall config file
Signed-off-by: Alen Grizonic <a.grizonic@proxmox.com>
2015-08-25 06:49:26 +02:00
Wolfgang Link
40b977f328 fix bug #688: if vm is not owner of this disk remove from config 2015-08-20 12:28:50 +02:00
Wolfgang Link
a78ea5dfe9 fix bug #688: prevent copy unused disks in the config. 2015-08-20 12:28:05 +02:00
Alen Grizonic
e9abcde681 fix bug #603: vmid.fw file not deleted
Signed-off-by: Alen Grizonic <a.grizonic@proxmox.com>
2015-08-19 15:30:00 +02:00
Wolfgang Link
d662790a14 fix bug #517: improve error message
Get a understandble message,
if someone try to increase a qcow2 image where one or more snapshots reside
2015-08-18 16:35:00 +02:00
Wolfgang Bumiller
1bc483f6bc adapt /config and /pending API calls to force-delete 2015-08-18 16:29:10 +02:00
Alen Grizonic
37f438057a remove vm access permissions after destroy
removed duplicated code which was used in
PVE::AccessControl -> now in PVE::API2::Qemu

Signed-off-by: Alen Grizonic <a.grizonic@proxmox.com>
2015-08-14 08:07:24 +02:00
Wolfgang Bumiller
cee01bcbd7 merge delete_drive into try_deallocate_drive
It used to be private and is only used once.
2015-08-13 12:34:12 +02:00
Wolfgang Bumiller
3dc38fbb74 pending-delete: remember force-deletes
The -force flag didn't have any effect since the pending
changes didn't carry over the the flag.
Now forced deletes have an exclamation mark prepended to the
option name.
2015-08-13 11:08:45 +02:00
Dietmar Maurer
b0ec896e43 correctly handle empty description in pending section
So that we can delete descriptions with

 qm set <vmid> --descr ''
2015-08-11 11:24:41 +02:00
Thomas Lamprecht
663d664130 Fixed wrong UUID in Qemu VZDump backup
As the format of the uuid which the qemu monitor returned changed,
it is here adapted to fix errors with not matching uuids.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2015-07-30 11:31:19 +02:00
Alexandre Derumier
525814b230 add memory_unplug support V2
qemu 2.4 feature

changelog: rebase on last git

Note that currently linux guest don't support unplug of dimm when it'sused by kernel memory.
They are some tunning to do with memory zone movable.
http://events.linuxfoundation.org/sites/events/files/lcjp13_chen.pdf

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-29 10:16:28 +02:00
Thomas Lamprecht
38f7f26c44 fixed bug 662, wrong subroutine for parsing startup order
Changed from old, now missing, subroutine parse_startup() to new
pve_parse_startup_order() in qemu-server and pve-manager

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2015-07-22 12:44:30 +02:00
Alexandre Derumier
f1f7ea886a cpuflags : don't enforce with tcg mode
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-22 12:40:47 +02:00
Alexandre Derumier
dac7c6190c cpuflags : remove enforce for cpumodel=host
Currently enforce with cpumodel=host on amd cpus don't work,
because amd cpus have unsupported flags in qemu.

This is a protection, and this is good.

but cpumodel host should be never use by users for production (only for testing).
For production and stability, users need to choose a true cpu model which filter
the supported cpuflags by qemu.

So I think we can remove the enforce for host model as for testing it's ok.

warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 0]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 1]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 2]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 3]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 4]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 5]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 6]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 7]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 8]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 9]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 12]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 13]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 14]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 15]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 16]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 17]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 23]
warning: host doesn't support requested feature: CPUID.80000001H:EDX [bit 24]
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-22 12:40:20 +02:00
Alexandre Derumier
0dc48c3d5b cpuflags : remove -rdtscp for Opteron cpu models
rdtscp is not supported by qemu and with enforce it's not starting
warning: host doesn't support requested feature: CPUID.80000001H:EDX.rdtscp [bit 27]

from to qemu wiki
http://wiki.qemu.org/Features/CPUModels#Disabling_features_that_were_always_disabled_on_KVM
"Fact: currently libvirt runs CPU models having rdtscp without the "enforce" flag, and rdtscp is silently disabled
Consequence: libvirt SHOULD use something like "-cpu Opteron_G5,-rdtscp",
especially when it starts using (or emulating) enforce mode
This will require a solution on libvirt side. QEMU will just provide the mechanisms to report CPU model information
and check what the host and QEMU supports, but the decision to disable rdtscp to be able
to run Opteron_G[2345] needs to be taken by libvirt."

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-22 12:38:47 +02:00
Alexandre Derumier
7d930a0e7e vzdump : abord backup if disk have iothread enabled.
Currently backup don't work with iothread feature, and crash qemu

For now, abord the backup if one of the vm drives have iothread enabled until backup code is fixed.

Upstream qemu backup cde already support iothread.
http://git.qemu.org/?p=qemu.git;a=commit;h=761731b1805f6ef64eb615e5b82a0801db3cde78

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-22 12:28:52 +02:00
Alexandre Derumier
22967505c4 qemu-server : drive-mirror : allow to interrupts at the scanning bitmap phase
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-01 06:39:50 +02:00
Alexandre Derumier
604ea64464 qemuserver : vm_status : add extended stats (disks, nics, memory) V3
Add extended stats results for each nics,disks and memory on full stats mode only.

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-06-16 13:23:24 +02:00
Dietmar Maurer
85bdc6afc0 remove outdated host_device format
Newer qemu does not need it.

https://lists.nongnu.org/archive/html/qemu-devel/2011-06/msg02790.html
2015-06-10 10:29:30 +02:00
Dietmar Maurer
d81f0f09fc parse_drive: do not overwrite configured format
Instead, we use qemu_img_format() to query the format when we need it.
We also pass the format to qemu in print_drive_full to avoid qemu warnings.
2015-06-10 10:22:42 +02:00
Wolfgang Bumiller
b2ee900e3c fix aio O_DIRECT check for cdrom drives
Only non-cdrom drives default to cache=none, so the check
for whether to default to aio=native needs to take the same
condition into account.
I combined them close together to make their relation more
visible.
2015-06-02 16:11:01 +02:00
Dietmar Maurer
c6f773b818 cpulimit: use number instead of integer 2015-06-02 16:03:25 +02:00
Alexandre Derumier
58be00f10a implement cpuunit with cgroups
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-06-02 15:56:52 +02:00
Dietmar Maurer
3a515a8805 code cleanup 2015-05-29 08:23:13 +02:00
Alexandre Derumier
ba02e591f0 remove old openvz fairscheduler code
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-05-29 08:11:07 +02:00
Alexandre Derumier
c8effec354 implement hotplug for cpuunits
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-05-29 08:11:04 +02:00
Alexandre Derumier
f08e17c7be implement cgroups through systemd-run
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-05-29 08:11:02 +02:00
Wolfgang Bumiller
fd1f36ac6f localhost instead of 127.0.0.1 makes ipv6 life easier 2015-05-27 08:25:38 +02:00
Wolfgang Bumiller
2fbd27eabc migration: put the source address in brackets
Always adding brackets around the address works. They're required for
ipv6 and qemu also accepts them for ipv4 and hostnames.
2015-05-21 17:30:30 +02:00
Wolfgang Bumiller
af0eba7e35 pass port family to next_*_port() calls 2015-05-12 12:28:56 +02:00
Alexandre Derumier
38e0c3b8ae qmp drive-mirror : set big timeout
drive-mirror is doing lseek on source image before starting, and this can take a lot of time for big nfs volume
during this time, qmp socket is hanging
http://lists.nongnu.org/archive/html/qemu-devel/2015-05/msg01838.html
so we need to setup a big timeout

qemu devs are currently working to fix this

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-05-12 08:18:42 +02:00
Alexandre Derumier
ad123d97f9 qemu-mirror : block job complete : use ready flag
Since qemu 2.2, a new "ready" flag has been added to blockjob
http://git.qemu.org/?p=qemu.git;a=commit;h=ef6dbf1e46ebd1d41ab669df5bba0bbdec6bd374
to known if we can complete it.

we can't use len==offset to known if all block are mirrored, because behaviour will change soon in qemu 2.3

http://git.qemu.org/?p=qemu.git;a=commit;h=b21c76529d55bf7bb02ac736b312f5f8bf033ea2
"block/mirror: Improve progress report

Instead of taking the total length of the block device as the block
job's length, use the number of dirty sectors. The progress is now the
number of sectors mirrored to the target block device. Note that this
may result in the job's length increasing during operation, which is
however in fact desirable.
"

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-05-12 08:18:30 +02:00
Wolfgang Bumiller
d483fa010c Switch from netcat-traditional to netcat6
netcat6 supports both ipv4 and ipv6, contrary to netcat-traditional.
Additionally rather than using the alternatives-managed /bin/nc path,
/bin/nc6 is now used which always points to the netcat6 implementation,
allowing us to drop the netcat-openbsd conflict entry.
2015-05-12 06:39:08 +02:00
Wolfgang Link
e5eaa02815 remove running from Storage and check it in QemuServer
It is better to check if a VM is running in QemuServer then in Storage.
for the Storage there is no difference if it is running or not.

Signed-off-by: Wolfgang Link <w.link@proxmox.com>
2015-05-06 11:47:11 +02:00
Wolfgang Link
adf8ac08c8 implement offline migration on zfs
Signed-off-by: Wolfgang Link <w.link@proxmox.com>
2015-04-27 10:42:59 +02:00
Wolfgang Link
37a6dc7809 fix bug #618: correct typo
Signed-off-by: Wolfgang Link <w.link@proxmox.com>
2015-04-27 10:42:49 +02:00
Dietmar Maurer
43574f738d use new standard option 'pve-startup-order' 2015-04-22 10:02:33 +02:00