diff options
author | Waldemar Brodkorb <wbx@uclibc-ng.org> | 2016-11-20 17:42:34 +0100 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2016-11-25 01:49:36 +0100 |
commit | b0f23d1e562e753cb78a473fdade956a25cc337b (patch) | |
tree | fe4a5908d1e39e24ec6df66052e866ed72421a79 /package/base-files/src/etc/mdev | |
parent | 49a817b44be5695a87f6b4c8eadef3bb0f9419f9 (diff) |
finalize systemd as alternative init system
Most important is the fix in patch-src_journal_journald-server_c,
which breaks startup of systemd-journald when code is compiled
with -DNDEBUG.
A lot of base-files reorganizing to only install required files
on sysv systems.
Diffstat (limited to 'package/base-files/src/etc/mdev')
-rwxr-xr-x | package/base-files/src/etc/mdev/fs | 67 |
1 files changed, 0 insertions, 67 deletions
diff --git a/package/base-files/src/etc/mdev/fs b/package/base-files/src/etc/mdev/fs deleted file mode 100755 index 86c4cee2f..000000000 --- a/package/base-files/src/etc/mdev/fs +++ /dev/null @@ -1,67 +0,0 @@ -#!/bin/sh -# skip root disk here, will be handled in /etc/init.d/fs -rootdisk=$(readlink /dev/root) -if [ "x${rootdisk}" = "x${MDEV}" ];then - exit 0 -fi -uuid=$(blkid /dev/${MDEV} | sed -n '/^.*UUID="\([^"]*\)".*$/s//\1/p') -if [ -z $uuid ];then - fs=$(grep "^/dev/${MDEV}[[:blank:]]" /etc/fstab | awk '{ print $3 }') - mnt=$(grep "^/dev/${MDEV}[[:blank:]]" /etc/fstab | awk '{ print $2 }') - disk="${MDEV}" -else - fs=$(grep "^/dev/${MDEV}[[:blank:]]\|^UUID=$uuid" /etc/fstab | awk '{ print $3 }') - mnt=$(grep "^/dev/${MDEV}[[:blank:]]\|^UUID=$uuid" /etc/fstab | awk '{ print $2 }') - disk="${MDEV} (${uuid})" -fi -if [ -z $fs ];then - logger -t mdev "Disk $disk not registered in /etc/fstab" - exit 0 -fi - -procfs=$fs -if [ $fs = "ntfs-3g" ];then - procfs=fuse -fi - -# check if already mounted via /etc/init.d/fs -adk_check() { - mount | grep "${MDEV}[[:blank:]]" - if [ $? -eq 0 ];then - logger -t mdev "Filesystem on ${MDEV} already mounted" - exit 0 - fi -} - -# filesystem check -adk_fsck() { - [ -x /usr/sbin/fsck.$fs ] && { - logger -t mdev "Checking $fs filesystem on ${MDEV}" - fsck -p ${MDEV} >/dev/null - } -} - -# mount filesystem -adk_mount() { - mkdir -p $mnt >/dev/null 2>&1 - grep $procfs /proc/filesystems >/dev/null 2>&1 - if [ $? -eq 0 ];then - logger -t mdev "Mounting $disk to $mnt" - mount $mnt 2>> /tmp/mount.err - if [ $? -ne 0 ]; then - logger -t mdev "Mounting $disk failed with $?" - fi - else - logger -t mdev "Required filesystem $procfs not available" - fi -} - -case "${ACTION}" in -add) - logger -t mdev "Device ${MDEV} added to the system" - adk_check - adk_fsck - adk_mount - ;; -esac -exit 0 |