32 Posts

February 13th, 2009 14:00

or from at command ...

9 Legend

 • 

20.4K Posts

February 13th, 2009 14:00

perl , bash ?

9 Legend

 • 

20.4K Posts

February 13th, 2009 15:00

what are you trying to achieve ? Nightly backups, file system refresh for qa/development ?

32 Posts

February 13th, 2009 15:00

one time move of fs on ATA shelf - to new fs on new FC shelf

I have done manually before, but would like to try scripting it for middle of night migration

I know there is replication technique, but it seems too complex and I'm not sure about the sequence of steps

-J

32 Posts

February 13th, 2009 15:00

bash

9 Legend

 • 

20.4K Posts

February 14th, 2009 23:00

since you have done it manually ..it's really just a matter of putting your command in a file and maybe using variable names instead of hard coding file system names, for example:

export NAS_DB=/nas
export PATH=$PATH:/nas/bin
 
## Target file system is created but not mounted ##
 
SOURCEFS=fs59
TARGETFS=fs69
SERVER=server_4
MOUNTPOINT=${TARGETFS}
SNAPNAME=${SOURCEFS}_ckpt
 
nas_fs -Type rawfs ${TARGETFS} -Force
server_mountpoint ${SERVER} -create /${MOUNTPOINT}
server_mount ${SERVER} -option ro ${TARGETFS} /${MOUNTPOINT}
fs_ckpt ${SOURCEFS} -name ${SNAPNAME} -Create
echo "Starting fs_copy process"
fs_copy -start ${SNAPNAME} ${TARGETFS}
echo "Initial fs_copy completed"
nas_fs -delete ${SNAPNAME} -o umount=yes
server_mount ${SERVER} -option rw ${TARGETFS} /${MOUNTPOINT}


Unfortunately Celerra developers refuse to release error codes so it's nearly impossible to take actions within the script based on error codes. For example if there is a snapsure process in progress, it will not allow you to take a snapshot until the one running completes. Checking $? value does not help a lot. I submitted an RFE to get error codes from Celerra developers two years ago...still waiting.

32 Posts

February 16th, 2009 08:00

Many thanks dynamox,

Thats what I was looking for, just a sanity check on a scripting method.

I'll give that a go on a test fs and let you know.

If anyone else wants to add, I'm keeping the topic open for a while.

-John
No Events found!

Top