SHA256
1
0
forked from pool/qemu

Accepting request 415262 from home:a_faerber:branches:Virtualization

%post hook cleanups (boo#860275, boo#989655)

OBS-URL: https://build.opensuse.org/request/show/415262
OBS-URL: https://build.opensuse.org/package/show/Virtualization/qemu?expand=0&rev=307
This commit is contained in:
Andreas Färber 2016-07-26 14:22:29 +00:00 committed by Git OBS Bridge
parent 76b986ded9
commit 49b7a849e9
5 changed files with 34 additions and 18 deletions

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Tue Jul 19 20:57:17 UTC 2016 - afaerber@suse.de
- Clean up the udev ifdeffery to cover systemd as well (boo#860275)
- Trigger udev rules also under systemd (boo#989655)
- Suppress s390x sysctl in chroot
- Ignore s390x sysctl failures (agraf)
-------------------------------------------------------------------
Thu Jul 14 19:38:39 UTC 2016 - brogers@suse.com

View File

@ -1136,20 +1136,20 @@ install -D -m 644 check-report.xml %{buildroot}%{_datadir}/qemu/check-report.xml
%if %{kvm_available}
%post
if [ "$(readlink -f /proc/1/root)" = "/" ]; then
# Do not execute operations affecting host devices while running in a chroot
if [ $(stat -L -c "%i" /proc/1/root/) = $(stat -L -c "%i" /) ]; then
setfacl --remove-all /dev/kvm &> /dev/null || :
fi
%if 0%{?with_systemd}
%udev_rules_update
%udev_rules_update
%_bindir/udevadm trigger || :
%else
if [ "$(readlink -f /proc/1/root)" = "/" ]; then
/sbin/udevadm control --reload-rules || :
/sbin/udevadm trigger || :
fi
%endif
%ifarch s390x
sysctl vm.allocate_pgste=1
sysctl vm.allocate_pgste=1 || :
%endif
fi
%endif
%if 0%{?suse_version} >= 1130

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Tue Jul 19 20:57:17 UTC 2016 - afaerber@suse.de
- Clean up the udev ifdeffery to cover systemd as well (boo#860275)
- Trigger udev rules also under systemd (boo#989655)
- Suppress s390x sysctl in chroot
- Ignore s390x sysctl failures (agraf)
-------------------------------------------------------------------
Thu Jul 14 19:38:39 UTC 2016 - brogers@suse.com

View File

@ -1136,20 +1136,20 @@ install -D -m 644 check-report.xml %{buildroot}%{_datadir}/qemu/check-report.xml
%if %{kvm_available}
%post
if [ "$(readlink -f /proc/1/root)" = "/" ]; then
# Do not execute operations affecting host devices while running in a chroot
if [ $(stat -L -c "%i" /proc/1/root/) = $(stat -L -c "%i" /) ]; then
setfacl --remove-all /dev/kvm &> /dev/null || :
fi
%if 0%{?with_systemd}
%udev_rules_update
%udev_rules_update
%_bindir/udevadm trigger || :
%else
if [ "$(readlink -f /proc/1/root)" = "/" ]; then
/sbin/udevadm control --reload-rules || :
/sbin/udevadm trigger || :
fi
%endif
%ifarch s390x
sysctl vm.allocate_pgste=1
sysctl vm.allocate_pgste=1 || :
%endif
fi
%endif
%if 0%{?suse_version} >= 1130

View File

@ -1017,20 +1017,20 @@ install -D -m 644 check-report.xml %{buildroot}%{_datadir}/qemu/check-report.xml
%if %{kvm_available}
%post
if [ "$(readlink -f /proc/1/root)" = "/" ]; then
# Do not execute operations affecting host devices while running in a chroot
if [ $(stat -L -c "%i" /proc/1/root/) = $(stat -L -c "%i" /) ]; then
setfacl --remove-all /dev/kvm &> /dev/null || :
fi
%if 0%{?with_systemd}
%udev_rules_update
%udev_rules_update
%_bindir/udevadm trigger || :
%else
if [ "$(readlink -f /proc/1/root)" = "/" ]; then
/sbin/udevadm control --reload-rules || :
/sbin/udevadm trigger || :
fi
%endif
%ifarch s390x
sysctl vm.allocate_pgste=1
sysctl vm.allocate_pgste=1 || :
%endif
fi
%endif
%if 0%{?suse_version} >= 1130