- Set cache mode for target installation disk to unsafe for better

performance
  virtinst-set-cache-mode-unsafe-for-install.patch
- Renamed virtman-lxc-no-default-disk.patch to an upstream timestamp
  name 5385d602-lxc-no-default-disk.patch

OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=180
This commit is contained in:
Charles Arnold 2014-05-29 23:00:52 +00:00 committed by Git OBS Bridge
parent c7763f3f1f
commit d1212d53d0
5 changed files with 45 additions and 11 deletions

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Thu May 29 10:30:15 MDT 2014 - carnold@suse.com
- Set cache mode for target installation disk to unsafe for better
performance
virtinst-set-cache-mode-unsafe-for-install.patch
- Renamed virtman-lxc-no-default-disk.patch to an upstream timestamp
name 5385d602-lxc-no-default-disk.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Tue May 27 09:13:49 UTC 2014 - cbosdonnat@suse.com Tue May 27 09:13:49 UTC 2014 - cbosdonnat@suse.com

View File

@ -61,6 +61,7 @@ Patch22: 535ff0b7-fix-install-when-one-package-is-already-installed.patch
Patch23: 536152fe-fix-error-detecting-OS-in-show-all-list.patch Patch23: 536152fe-fix-error-detecting-OS-in-show-all-list.patch
Patch24: 536154d8-show-error-if-launching-delete-dialog-fails.patch Patch24: 536154d8-show-error-if-launching-delete-dialog-fails.patch
Patch25: 53615662-call-path_exists-before-getting-storage-volume.patch Patch25: 53615662-call-path_exists-before-getting-storage-volume.patch
Patch26: 5385d602-lxc-no-default-disk.patch
Patch45: 531e0a82-reverse-keyboard-grab-commit.patch Patch45: 531e0a82-reverse-keyboard-grab-commit.patch
Patch50: virtman-desktop.patch Patch50: virtman-desktop.patch
Patch51: virtman-cdrom.patch Patch51: virtman-cdrom.patch
@ -83,8 +84,6 @@ Patch69: virtman-add-s390x-arch-support.patch
Patch70: virtman-prevent-double-click-starting-vm-twice.patch Patch70: virtman-prevent-double-click-starting-vm-twice.patch
Patch71: virtman-default-lxc-uri.patch Patch71: virtman-default-lxc-uri.patch
Patch72: virtman-add-connect-default.patch Patch72: virtman-add-connect-default.patch
# PATCH-FIX-UPSTREAM virtman-lxc-no-default-disk.patch -- pending upstream review, bnc#870587
Patch73: virtman-lxc-no-default-disk.patch
Patch151: virtinst-storage-ocfs2.patch Patch151: virtinst-storage-ocfs2.patch
Patch152: virtinst-qed.patch Patch152: virtinst-qed.patch
Patch153: virtinst-support-suse-distros.patch Patch153: virtinst-support-suse-distros.patch
@ -96,6 +95,7 @@ Patch158: virtinst-set-qemu-emulator.patch
Patch159: virtinst-vol-default-nocow.patch Patch159: virtinst-vol-default-nocow.patch
Patch160: virtinst-detect-windows-media.patch Patch160: virtinst-detect-windows-media.patch
Patch161: virtinst-xenbus-disk-index-fix.patch Patch161: virtinst-xenbus-disk-index-fix.patch
Patch162: virtinst-set-cache-mode-unsafe-for-install.patch
BuildArch: noarch BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
@ -209,6 +209,7 @@ machine).
%patch23 -p1 %patch23 -p1
%patch24 -p1 %patch24 -p1
%patch25 -p1 %patch25 -p1
%patch26 -p1
%patch45 -p1 %patch45 -p1
%patch50 -p1 %patch50 -p1
%patch51 -p1 %patch51 -p1
@ -231,7 +232,6 @@ machine).
%patch70 -p1 %patch70 -p1
%patch71 -p1 %patch71 -p1
%patch72 -p1 %patch72 -p1
%patch73 -p1
%patch151 -p1 %patch151 -p1
%patch152 -p1 %patch152 -p1
%patch153 -p1 %patch153 -p1
@ -243,6 +243,7 @@ machine).
###%patch159 -p1 nocow flag ###%patch159 -p1 nocow flag
%patch160 -p1 %patch160 -p1
%patch161 -p1 %patch161 -p1
%patch162 -p1
%build %build
%if %{qemu_user} %if %{qemu_user}

View File

@ -0,0 +1,27 @@
--- virt-manager-1.0.1/virtinst/guest.py.orig 2014-05-29 10:27:00.609005060 -0600
+++ virt-manager-1.0.1/virtinst/guest.py 2014-05-29 10:27:03.588027133 -0600
@@ -343,6 +343,12 @@ class Guest(XMLBuilder):
self.on_reboot = action
self.on_crash = action
+ # At install time only set the target disk to 'unsafe' for
+ # better performance
+ if install:
+ target_disk = self.get_devices("disk")[0]
+ saved_cache = target_disk.driver_cache
+ target_disk.driver_cache = "unsafe"
self._set_defaults()
self.bootloader = None
@@ -362,7 +368,10 @@ class Guest(XMLBuilder):
self.bootloader = "/usr/bin/pygrub"
self.os.clear()
- return self.get_xml_config()
+ xml_config = self.get_xml_config()
+ if install:
+ target_disk.driver_cache = saved_cache
+ return xml_config
def get_continue_inst(self):
"""

View File

@ -10,11 +10,11 @@ locally, but only if there is no kvm/xen URI to default to.
virtManager/connect.py | 4 ++++ virtManager/connect.py | 4 ++++
2 files changed, 11 insertions(+), 3 deletions(-) 2 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/virtManager/connect.py b/virtManager/connect.py Index: virt-manager-1.0.1/virtManager/connect.py
index 1247d75..34835fa 100644 ===================================================================
--- a/virtManager/connect.py --- virt-manager-1.0.1.orig/virtManager/connect.py
+++ b/virtManager/connect.py +++ virt-manager-1.0.1/virtManager/connect.py
@@ -116,6 +116,10 @@ class vmmConnect(vmmGObjectUI): @@ -117,6 +117,10 @@ class vmmConnect(vmmGObjectUI):
return "qemu:///system" return "qemu:///system"
else: else:
return "qemu:///session" return "qemu:///session"
@ -25,6 +25,3 @@ index 1247d75..34835fa 100644
return None return None
def cancel(self, ignore1=None, ignore2=None): def cancel(self, ignore1=None, ignore2=None):
--
1.8.4.5