Advertisement
Guest User

Untitled

a guest
Nov 22nd, 2014
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.41 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. checkMount() {
  4.         echo `ls /mnt/ManageTV/ | wc -l`
  5. }
  6.  
  7. if [[ $(checkMount) -eq 0 ]]; then
  8.         echo "Mounting Magma shared drives"
  9.         `mount -a 2> /var/log/warnings`
  10.         if [[ $(checkMount) -eq 0 ]]; then
  11.                 echo "Drive not mounted, check /var/log/warnings"
  12.         else
  13.                 echo "Drives Mounted"
  14.         fi
  15. else
  16.         echo "Already Mounted"
  17. fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement