s4:scripting/devel Allow tmpfs script to be re-run
authorAndrew Bartlett <abartlet@samba.org>
Mon, 18 Jan 2010 06:24:45 +0000 (19:24 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 24 Feb 2010 21:26:09 +0000 (08:26 +1100)
By doing the unmount, we can avoid double-mounting st and bin

source4/scripting/devel/tmpfs.sh

index 5604f68dd7680cc2ef3e91f0e7fd019226fa4aae..14e9b276c65bf5e859c285de5a2ce8627d624afd 100755 (executable)
@@ -3,7 +3,10 @@
 # This sets up bin/ and st/ as tmpfs filesystems, which saves a lot of
 # time waiting on the disk!
 
-rm -rf bin st
+sudo echo "About to (re)mount bin and st as tmpfs"
+rm -rf bin st 
+sudo umount bin > /dev/null 2>&1 
+sudo umount st  > /dev/null 2>&1 
 mkdir -p bin st || exit 1
 sudo mount -t tmpfs /dev/null bin || exit 1
 sudo chown $USER bin || exit 1