[node-patches] Change in ovirt-node[ovirt-3.5]: ntpd: Avoid Private tmp creation

fabiand at redhat.com fabiand at redhat.com
Fri Oct 9 16:50:54 UTC 2015


Hello Douglas Schilling Landgraf,

I'd like you to do a code review.  Please visit

    https://gerrit.ovirt.org/47168

to review the following change.

Change subject: ntpd: Avoid Private tmp creation
......................................................................

ntpd: Avoid Private tmp creation

This patch disable creation of private tmp for ntp service.
oVirt node distros based in RHEL 7.2 at moment are facing
issues with namespace and bind mounting. As example, files
in /etc return busy when trying to remove it after the
unpersist command.

Change-Id: I95ad04aca90f303c3a90afb4c8b9c3c3fd0eb838
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1251151
Signed-off-by: Douglas Schilling Landgraf <dougsland at redhat.com>
(cherry picked from commit 502b72c953d1acb1ce0a9550e17326004273971e)
---
M ovirt-node.spec.in
M services/Makefile.am
A services/ntpd-private-tmp.conf
3 files changed, 11 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/68/47168/1

diff --git a/ovirt-node.spec.in b/ovirt-node.spec.in
index e4efd92..11b6d45 100644
--- a/ovirt-node.spec.in
+++ b/ovirt-node.spec.in
@@ -473,8 +473,11 @@
 %{__install} -d -m0755 %{buildroot}%{_libexecdir}/ovirt-node/hooks/on-boot
 %{__install} -d -m0755 %{buildroot}%{_libexecdir}/ovirt-node/hooks/on-changed-boot-image
 
+%if 0%{?is_systemd}
+%{__install} -Dp -m0644 services/ntpd-private-tmp.conf \
+                       %{buildroot}%{_sysconfdir}/systemd/system/ntpd.service.d/ntpd-private-tmp.conf
+%else
 # dracut patches for rhel6
-%if ! %{is_systemd}
 %{__install} -p -m0644 dracut/dracut-7ed4ff0636c74a2f819ad6e4f2ab4862.patch %{buildroot}%{app_root}
 
 %endif
@@ -784,6 +787,7 @@
 %{_unitdir}/ovirt-post.service
 %{_unitdir}/ovirt-early.service
 %{_unitdir}/ovirt-kdump.service
+%{_sysconfdir}/systemd/system/ntpd.service.d/ntpd-private-tmp.conf
 %else
 %{_initrddir}/ovirt-awake
 %{_initrddir}/ovirt-early
diff --git a/services/Makefile.am b/services/Makefile.am
index 1dec6e0..21f30a0 100644
--- a/services/Makefile.am
+++ b/services/Makefile.am
@@ -40,4 +40,8 @@
   init.d/ovirt-node-igor-slave
 endif
 
+EXTRA_DIST = \
+  ntpd-private-tmp.conf \
+  $(NULL)
+
 # vim: ts=2
diff --git a/services/ntpd-private-tmp.conf b/services/ntpd-private-tmp.conf
new file mode 100644
index 0000000..d9fe94e
--- /dev/null
+++ b/services/ntpd-private-tmp.conf
@@ -0,0 +1,2 @@
+[Service]
+PrivateTmp=false


-- 
To view, visit https://gerrit.ovirt.org/47168
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I95ad04aca90f303c3a90afb4c8b9c3c3fd0eb838
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Fabian Deutsch <fabiand at redhat.com>
Gerrit-Reviewer: Douglas Schilling Landgraf <dougsland at redhat.com>



More information about the node-patches mailing list