aboutsummaryrefslogtreecommitdiffstats
path: root/systemd
diff options
context:
space:
mode:
Diffstat (limited to 'systemd')
-rwxr-xr-xsystemd/mandriva-boot-links21
-rwxr-xr-xsystemd/mandriva-save-dmesg4
-rw-r--r--systemd/system/fedora-sysinit-unhack.service3
-rw-r--r--systemd/system/mandriva-boot-links.service11
-rw-r--r--systemd/system/mandriva-clean-var-run-lock.service16
-rw-r--r--systemd/system/mandriva-everytime.service12
-rw-r--r--systemd/system/mandriva-kmsg-loglevel.service9
-rw-r--r--systemd/system/mandriva-save-dmesg.service11
8 files changed, 86 insertions, 1 deletions
diff --git a/systemd/mandriva-boot-links b/systemd/mandriva-boot-links
new file mode 100755
index 00000000..50ecc71c
--- /dev/null
+++ b/systemd/mandriva-boot-links
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+uname_r=$(uname -r)
+
+# Adjust symlinks as necessary in /boot to keep system services from
+# spewing messages about mismatched System maps and so on.
+if [ -L /boot/System.map -a -r /boot/System.map-$uname_r -a \
+ ! /boot/System.map -ef /boot/System.map-$uname_r ] ; then
+ ln -s -f System.map-$uname_r /boot/System.map
+fi
+if [ ! -e /boot/System.map -a -r /boot/System.map-$uname_r ] ; then
+ ln -s -f System.map-$uname_r /boot/System.map
+fi
+
+# Adjust symlinks as necessary in /boot to have the default config
+if [ -L /boot/config -a -r /boot/config-$uname_r ] ; then
+ ln -sf config-$uname_r /boot/config
+fi
+if [ ! -e /boot/config -a -r /boot/config-$uname_r ] ; then
+ ln -sf config-$uname_r /boot/config
+fi
diff --git a/systemd/mandriva-save-dmesg b/systemd/mandriva-save-dmesg
new file mode 100755
index 00000000..92562fcc
--- /dev/null
+++ b/systemd/mandriva-save-dmesg
@@ -0,0 +1,4 @@
+#!/bin/sh
+
+[ -f /var/log/dmesg ] && mv -f /var/log/dmesg /var/log/dmesg.old
+dmesg -s 131072 > /var/log/dmesg
diff --git a/systemd/system/fedora-sysinit-unhack.service b/systemd/system/fedora-sysinit-unhack.service
index 86e20cd6..221d8bb1 100644
--- a/systemd/system/fedora-sysinit-unhack.service
+++ b/systemd/system/fedora-sysinit-unhack.service
@@ -1,8 +1,9 @@
[Unit]
-Description=Bootup hack
+Description=Bootup unhack
DefaultDependencies=no
Conflicts=shutdown.target
Before=shutdown.target
+After=fedora-sysinit-hack.service sysinit.target
[Service]
Type=oneshot
diff --git a/systemd/system/mandriva-boot-links.service b/systemd/system/mandriva-boot-links.service
new file mode 100644
index 00000000..202dfc58
--- /dev/null
+++ b/systemd/system/mandriva-boot-links.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Setup links in /boot for running kernel
+DefaultDependencies=no
+Requires=local-fs.target
+Conflicts=shutdown.target
+After=local-fs.target
+Before=shutdown.target
+
+[Service]
+ExecStart=-/lib/systemd/mandriva-boot-links
+Type=oneshot
diff --git a/systemd/system/mandriva-clean-var-run-lock.service b/systemd/system/mandriva-clean-var-run-lock.service
new file mode 100644
index 00000000..e8feaacb
--- /dev/null
+++ b/systemd/system/mandriva-clean-var-run-lock.service
@@ -0,0 +1,16 @@
+# This file is part of initscripts.
+#
+# Implement /var/run and /var/lock clean up that is part of standard
+# rc.sysinit but cannot be expressed using tmpfiles.d
+
+[Unit]
+Description=Cleanup of /var/run and /var/lock
+DefaultDependencies=no
+Wants=local-fs.target
+After=systemd-readahead-collect.service systemd-readahead-replay.service local-fs.target
+Before=systemd-tmpfiles-setup.service sysinit.target shutdown.target
+
+[Service]
+Type=oneshot
+ExecStart=-/usr/bin/find /var/lock /var/run -depth ! -type d ! -path /var/lock/TMP_1ST -delete
+IOSchedulingClass=idle
diff --git a/systemd/system/mandriva-everytime.service b/systemd/system/mandriva-everytime.service
new file mode 100644
index 00000000..68fa89d9
--- /dev/null
+++ b/systemd/system/mandriva-everytime.service
@@ -0,0 +1,12 @@
+[Unit]
+Description=Reconfigure the system on administrator request
+DefaultDependencies=no
+Conflicts=shutdown.target
+Before=basic.target shutdown.target
+After=local-fs.target
+
+[Service]
+ExecStart=-/etc/init.d/mandrake_everytime
+Type=oneshot
+TimeoutSec=0
+StandardInput=tty
diff --git a/systemd/system/mandriva-kmsg-loglevel.service b/systemd/system/mandriva-kmsg-loglevel.service
new file mode 100644
index 00000000..dc89d5ac
--- /dev/null
+++ b/systemd/system/mandriva-kmsg-loglevel.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Set default kernel console loglevel
+DefaultDependencies=no
+Conflicts=shutdown.target
+
+[Service]
+EnvironmentFile=/etc/sysconfig/init
+ExecStart=/bin/dmesg -n $LOGLEVEL
+Type=oneshot
diff --git a/systemd/system/mandriva-save-dmesg.service b/systemd/system/mandriva-save-dmesg.service
new file mode 100644
index 00000000..c53f350d
--- /dev/null
+++ b/systemd/system/mandriva-save-dmesg.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Save boot dmesg content
+DefaultDependencies=no
+Conflicts=shutdown.target
+After=udev-settle.service local-fs.target
+Before=shutdown.target
+Wants=udev.service udev-settle.service
+
+[Service]
+ExecStart=-/lib/systemd/mandriva-save-dmesg
+Type=oneshot