1 2 3 4 5 6 7 8 9 10 11 12 13 14
#!/bin/sh #INIT 55 case $1 in autostop) cd / sync for i in $(grep -v ^# /etc/fstab 2>/dev/null|awk '{ print $2 }');do umount $i 2>/dev/null done ;; esac exit 0