diff options
author | danger <danger@FreeBSD.org> | 2009-05-17 08:25:02 +0000 |
---|---|---|
committer | danger <danger@FreeBSD.org> | 2009-05-17 08:25:02 +0000 |
commit | bb3ce629cacca1c66b09eb05f6ea8457cf57e63d (patch) | |
tree | 49a27aeaa9a320be46c999be7f514a14991895e5 /etc/rc.d/tmp | |
parent | 7275a79f2171bcc23335d1105702d0bef9de9dcf (diff) | |
download | FreeBSD-src-bb3ce629cacca1c66b09eb05f6ea8457cf57e63d.zip FreeBSD-src-bb3ce629cacca1c66b09eb05f6ea8457cf57e63d.tar.gz |
- do not create and mount new file systems on top of the old ones on every
invocation of this script once we already have one
(in case tmpmfs="YES").
Reviewed by: dougb
Diffstat (limited to 'etc/rc.d/tmp')
-rwxr-xr-x | etc/rc.d/tmp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/etc/rc.d/tmp b/etc/rc.d/tmp index 9750b6e..abf53ac 100755 --- a/etc/rc.d/tmp +++ b/etc/rc.d/tmp @@ -43,8 +43,10 @@ load_rc_config $name # case "${tmpmfs}" in [Yy][Ee][Ss]) - mount_md ${tmpsize} /tmp "${tmpmfs_flags}" - chmod 01777 /tmp + if ! /bin/df /tmp | grep -q "^/dev/md[0-9]"; then + mount_md ${tmpsize} /tmp "${tmpmfs_flags}" + chmod 01777 /tmp + fi ;; [Nn][Oo]) ;; |