#!/bin/bash
# /usr/local/bin/mountdrobo
# http://crystalfaeries.net/posix/bin/mountdrobo
# celeste:crystalfaery 2014-07-09 05:52:58+00:00
# Mount all of our Drobo shares
let exitval=0 # assume success
# mount the user's private partition for private files
#sudo mount -t cifs //drobofs/kahealani /home/kahealani/documents --verbose -o user=kahealani,uid=1000,forceuid,gid=1000,forcegid,file_mode=0660,dir_mode=0770,domain=KAHEALANI,rw,posixpaths,noserverino |& tee -a /var/log/cifs.log
#let result=$?
#if [[ $result -ne 0 ]]
#then
# let exitval=$result
#fi
# mount the user's private partition for private files backup
sudo mount -t cifs //drobo5n/kahealani /home/kahealani/documents --verbose -o user=kahealani,uid=1000,forceuid,gid=1000,forcegid,file_mode=0660,dir_mode=0770,domain=KAHEALANI,rw,posixpaths,noserverino |& tee -a /var/log/cifs.log
let result=$?
if [[ $result -ne 0 ]]
then
let exitval=$result
fi
# mount the Public drobo partition for backups of public files
#sudo mount -t cifs //drobofs/Public /home/public --verbose -o user=kahealani,uid=1000,forceuid,gid=1000,forcegid,file_mode=0664,dir_mode=0775,domain=KAHEALANI,rw,posixpaths,noserverino |& tee -a /var/log/cifs.log
#let result=$?
#if [[ $result -ne 0 ]]
#then
# let exitval=$result
#fi
# mount the Public drobo partition for backups of public files backup
sudo mount -t cifs //drobo5n/Public /home/public --verbose -o user=kahealani,uid=1000,forceuid,gid=1000,forcegid,file_mode=0664,dir_mode=0775,domain=KAHEALANI,rw,posixpaths,noserverino |& tee -a /var/log/cifs.log
let result=$?
if [[ $result -ne 0 ]]
then
let exitval=$result
fi
exit $exitval
syntax highlighted by Code2HTML, v. 0.9.1