diff options
| author | Richard Purdie <richard@openedhand.com> | 2006-07-21 10:10:31 +0000 |
|---|---|---|
| committer | Richard Purdie <richard@openedhand.com> | 2006-07-21 10:10:31 +0000 |
| commit | b2f192faabe412adce79534e22efe9fb69ee40e2 (patch) | |
| tree | 7076c49d4286f8a1733650bd8fbc7161af200d57 /meta/packages/initscripts/initscripts-1.0/umountnfs.sh | |
| parent | 2cf0eadf9f730027833af802d7e6c90b44248f80 (diff) | |
| download | poky-b2f192faabe412adce79534e22efe9fb69ee40e2.tar.gz | |
Rename /openembedded/ -> /meta/
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@530 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/packages/initscripts/initscripts-1.0/umountnfs.sh')
| -rwxr-xr-x | meta/packages/initscripts/initscripts-1.0/umountnfs.sh | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/meta/packages/initscripts/initscripts-1.0/umountnfs.sh b/meta/packages/initscripts/initscripts-1.0/umountnfs.sh new file mode 100755 index 0000000000..f5fe48aa74 --- /dev/null +++ b/meta/packages/initscripts/initscripts-1.0/umountnfs.sh | |||
| @@ -0,0 +1,28 @@ | |||
| 1 | #! /bin/sh | ||
| 2 | # | ||
| 3 | # umountnfs.sh Unmount all network filesystems. | ||
| 4 | # | ||
| 5 | |||
| 6 | PATH=/sbin:/bin:/usr/sbin:/usr/bin | ||
| 7 | |||
| 8 | # Write a reboot record to /var/log/wtmp before unmounting | ||
| 9 | halt -w | ||
| 10 | |||
| 11 | echo "Unmounting remote filesystems..." | ||
| 12 | |||
| 13 | test -f /etc/fstab && ( | ||
| 14 | |||
| 15 | # | ||
| 16 | # Read through fstab line by line and unount network file systems | ||
| 17 | # | ||
| 18 | while read device mountpt fstype options | ||
| 19 | do | ||
| 20 | if test "$fstype" = nfs || test "$fstype" = smbfs || test "$fstype" = ncpfs | ||
| 21 | then | ||
| 22 | umount -f $mountpt | ||
| 23 | fi | ||
| 24 | done | ||
| 25 | ) < /etc/fstab | ||
| 26 | |||
| 27 | : exit 0 | ||
| 28 | |||
