diff options
author | Dirk von Suchodoletz | 2006-05-21 15:01:26 +0200 |
---|---|---|
committer | Dirk von Suchodoletz | 2006-05-21 15:01:26 +0200 |
commit | 9b51546822b3c217fd669249b05a4a2265d88943 (patch) | |
tree | 837e1e37f0c707ff3c4931536b7dcc51e76b01bb /initrd/initrd-stuff/bin/servconfig | |
parent | see ticket #54 - tryout for special path /var/X11R6/bin ... (diff) | |
download | core-9b51546822b3c217fd669249b05a4a2265d88943.tar.gz core-9b51546822b3c217fd669249b05a4a2265d88943.tar.xz core-9b51546822b3c217fd669249b05a4a2265d88943.zip |
some fixes for automounter, better timing in init for nbd mounts ...
git-svn-id: http://svn.openslx.org/svn/openslx/ld4@227 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'initrd/initrd-stuff/bin/servconfig')
-rwxr-xr-x | initrd/initrd-stuff/bin/servconfig | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/initrd/initrd-stuff/bin/servconfig b/initrd/initrd-stuff/bin/servconfig index 78203904..28dede13 100755 --- a/initrd/initrd-stuff/bin/servconfig +++ b/initrd/initrd-stuff/bin/servconfig @@ -4,11 +4,11 @@ # for linux diskless clients (executed within initial # ramdisk) # -# Author(s): Dirk von Suchodoletz <dirk@goe.net>, 19-05-2006 +# Author(s): Dirk von Suchodoletz <dirk@goe.net>, 21-05-2006 # # Copyright: (c) 2006 - RZ Universitaet Freiburg # -# Version: 0.1.1a +# Version: 0.1.1b # check for configuration files to source @@ -192,24 +192,33 @@ config_acpi # configure automounter # if automounter=yes -echo -e "# /etc/auto.master - file generated by $0:\n\ +if [ -d /mnt/misc ] ; then + echo -e "# /etc/auto.master - file generated by $0:\n\ /misc\t/etc/auto.misc" >/mnt/etc/auto.master -echo -e "# /etc/auto.misc - file generated by $0:\n" \ + echo -e "# /etc/auto.misc - file generated by $0:" >/mnt/etc/auto.misc +else + echo -e "# /etc/auto.master - file generated by $0:\n\ +/misc\t#/etc/auto.misc" >/mnt/etc/auto.master + echo -e "# /etc/auto.misc - file generated by $0:\nautomount for removable \ +devices is mostly deprecated, so /misc is not\nactivated in auto.master." \ > /mnt/etc/auto.misc +fi if [ -n "${automnt_src}" ] ; then # local directory and home directory server from machine-setup [ -z "${automnt_dir}" ] && automnt_dir="/home" # remove leading and trailing slash automnt_dir=${automnt_dir#/} automnt_dir=${automnt_dir%/} - test -d ${automnt_dir} || error "$scfg_erradir" - strinstr "/" ${automnt_dir} || error "$scfg_erratpld" + test -d /${automnt_dir} || error "$scfg_erradir" nonfatal + strinstr "/" ${automnt_dir} || error "$scfg_erratpld" nonfatal echo -e "/${automnt_dir}\t/etc/auto.${automnt_dir}\n" \ >> /mnt/etc/auto.master echo -e "# /etc/auto.${automnt_dir} created by $0:\n" \ > /mnt/etc/auto.${automnt_dir} echo -e "*\t-rsize=32768,wsize=32768,rw\t${automnt_src}/&" \ >> /mnt/etc/auto.${automnt_dir} + # no tempfs needed if automounter operates on /home + [ "${automnt_dir}" = "home" ] && umount -t tmpfs /mnt/home 2>/dev/null # portmapper is needed for remote NFS sources config_portmap fi |