From 2cbb4aa65aa72601e0d20beed16348e03ade15e1 Mon Sep 17 00:00:00 2001 From: Kunhoon Baik Date: Tue, 7 Jun 2016 22:51:38 +0900 Subject: [PATCH] For using persistent storage in AUTO mode. As Tizen default, /opt is mounted seperately, and the /var -> /opt/var Thus, systemd flush should be done after mounting /opt. In generic, I think that systemd-journal-flush should be done after local-fs.target because several devices have own partition policies. Change-Id: I4acb4bd26365681ea798441c2f154b8ba5422665 --- packaging/systemd.spec | 4 ++++ units/systemd-journal-flush.service | 1 + 2 files changed, 5 insertions(+) diff --git a/packaging/systemd.spec b/packaging/systemd.spec index 3ed6052..a863203 100644 --- a/packaging/systemd.spec +++ b/packaging/systemd.spec @@ -267,6 +267,8 @@ rm -rf %{buildroot}/%{_datadir}/bash-completion/* rm -rf %{buildroot}/%{_datadir}/zsh/site-functions/* %endif +mkdir -p %{buildroot}/%{_localstatedir}/log/journal + # end of install %pre /usr/bin/getent group cdrom >/dev/null 2>&1 || /usr/sbin/groupadd -r -g 11 cdrom >/dev/null 2>&1 || : @@ -481,6 +483,8 @@ fi %{_datadir}/factory/etc/pam.d/other %{_datadir}/factory/etc/pam.d/system-auth +%{_localstatedir}/log/journal + # Make sure we don't remove runlevel targets from F14 alpha installs, # but make sure we don't create then anew. %ghost %config(noreplace) %{_sysconfdir}/systemd/system/runlevel2.target diff --git a/units/systemd-journal-flush.service b/units/systemd-journal-flush.service index 8c01587..1de3b58 100644 --- a/units/systemd-journal-flush.service +++ b/units/systemd-journal-flush.service @@ -14,6 +14,7 @@ Documentation=man:systemd-journald.service(8) man:journald.conf(5) ConditionPathExists=!/etc/initrd-release DefaultDependencies=no +After=local-fs.target After=systemd-remount-fs.service Before=systemd-tmpfiles-setup.service Wants=systemd-journald.service -- 2.7.4