diff options
Diffstat (limited to 'systemd')
-rwxr-xr-x | systemd/fedora-storage-init | 2 | ||||
-rwxr-xr-x | systemd/mandriva-boot-links | 21 | ||||
-rwxr-xr-x | systemd/mandriva-save-dmesg | 4 | ||||
-rw-r--r-- | systemd/system/mandriva-boot-links.service | 12 | ||||
-rw-r--r-- | systemd/system/mandriva-everytime.service | 13 | ||||
-rw-r--r-- | systemd/system/mandriva-kmsg-loglevel.service | 10 | ||||
-rw-r--r-- | systemd/system/mandriva-save-dmesg.service | 11 |
7 files changed, 72 insertions, 1 deletions
diff --git a/systemd/fedora-storage-init b/systemd/fedora-storage-init index 565d8111..962102af 100755 --- a/systemd/fedora-storage-init +++ b/systemd/fedora-storage-init @@ -34,7 +34,7 @@ if ! strstr "$cmdline" nodmraid && [ -x /sbin/dmraid ]; then fi # Start any MD RAID arrays that haven't been started yet -[ -r /proc/mdstat ] && [ -r /dev/md/md-device-map ] && /sbin/mdadm -IRs +[ -r /proc/mdstat ] && [ -r /dev/.mdadm/map ] && /sbin/mdadm -IRs if [ -x /sbin/lvm ]; then action $"Setting up Logical Volume Management:" /sbin/lvm vgchange -a y --sysinit 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/mandriva-boot-links.service b/systemd/system/mandriva-boot-links.service new file mode 100644 index 00000000..ced82ef0 --- /dev/null +++ b/systemd/system/mandriva-boot-links.service @@ -0,0 +1,12 @@ +[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 +RemainAfterExit=yes diff --git a/systemd/system/mandriva-everytime.service b/systemd/system/mandriva-everytime.service new file mode 100644 index 00000000..676f8671 --- /dev/null +++ b/systemd/system/mandriva-everytime.service @@ -0,0 +1,13 @@ +[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 +RemainAfterExit=yes diff --git a/systemd/system/mandriva-kmsg-loglevel.service b/systemd/system/mandriva-kmsg-loglevel.service new file mode 100644 index 00000000..4e92e429 --- /dev/null +++ b/systemd/system/mandriva-kmsg-loglevel.service @@ -0,0 +1,10 @@ +[Unit] +Description=Set default kernel console loglevel +DefaultDependencies=no +Conflicts=shutdown.target + +[Service] +EnvironmentFile=/etc/sysconfig/init +ExecStart=/bin/dmesg -n $LOGLEVEL +Type=oneshot +RemainAfterExit=yes diff --git a/systemd/system/mandriva-save-dmesg.service b/systemd/system/mandriva-save-dmesg.service new file mode 100644 index 00000000..5fd1bcaa --- /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=systemd-udev-settle.service local-fs.target +Before=shutdown.target + +[Service] +ExecStart=-/lib/systemd/mandriva-save-dmesg +Type=oneshot +RemainAfterExit=yes |