Вы находитесь на странице: 1из 2

TRY USING NAVICLI COMMANDS .....

IF UNABLE TO SEE RESULTS THEN PLS TRY BY USING JAVA


-JAR NAVICLI.JAR COMMANDS.

IMPORTANT NOTICE: ENSURE THESE SCRIPTS ARE TESTED IN THE LAB. IF ANY ERRORS PLS LET
ME KNOW.

THIS NAVICLI/NAVICLI.JAR SCRIPT IS FOR


1) CREATING RAID GROUP
2) CREATING OR BINDING LUNS
3) CREATING STORAGE GROUP
4) ADDING HOST TO STORAGE GROUP
5) ADDING LUN TO STORAGE GROUP
6) CREATING A CLONE
7) Destroying CLONE/STORAGE GROUPS/REMOVING LUNS & HOSTS FROM STORAGE GROUP

------------------------Script START-------
Note:-O is given to override Y/N (Prompting for authorisation) option. Enable or
try this option only if its been approved.

###1st step

1) java -jar navicli.jar -password password -scope 0 -addusersecurity


2) navicli -h <SPA_IPADRESS> createrg <RG_NO> [<EnclNo_DiskNO> .....]
3) navicli -h <SPA_IPADRESS> bind r5 <LUN_NUMBER> -rg <RG_NO> -sp A -sq mb -cap
capacity (Note: you can bind as many luns..accordingly you can enter this line of
script)
4) navicli -h <SPA_IPADRESS> bind r5 <LUN_NUMBER> -rg <RG_NO> -sp A -sq mb -cap
capacity (Note: you can bind as many luns..accordingly you can enter this line of
script)
5) java -jar navicli.jar -user user -password password -address <SPA_IPADRESS>
snapview -allocatecpl -spA <LUN_NUMBER> -spB <LUN_NUMBER>
6) navicli -h <SPA_IPADRESS> storagegroup -create -gname name
7) navicli -h <SPA_IPADRESS> storagegroup -connecthost -o -host <SOURCESERVER_IP OR
Server_Name> -gname name
8) navicli -h <SPA_IPADRESS> storagegroup -addhlu -gname Backup -hlu
<CLONELUN_numberforFIRSTLUN> -alu <CLONELUN_numberforFIRSTLUN>
9) java -jar navicli.jar -user user -password password -address <SPA_IPADDRESS>
snapview -createclonegroup -name name -luns <lun_number>
10) java -jar navicli.jar -user user -password password -address <SPA_IPADDRESS>
snapview -addclone -name name -luns <lun_number>
11) java -jar navicli.jar -user user -password password -address <SPA_IPADDRESS>
snapview -listclonegroup -name name
(NOTE: This command line will show the
clone group ID/ clone ID/ clone state etc.)

###2nd step (adding lun to backup host/storage group after synchronisation)

1) navicli -h <SPA_IPADRESS> storagegroup -create -gname name


2) navicli -h <SPA_IPADRESS> storagegroup -connecthost -o -host <BACKUPSERVER_IP OR
Server_Name> -gname name
3) navicli -h <SPA_IPADRESS> storagegroup -addhlu -gname Backup -hlu <CLONEDLUN>
-alu <CLONEDLUN>

###3RD step (fracture the clone to see the data in back up host)

1) java -jar navicli.jar -User USER -Password password -Scope 0 -Address


<SPA_IPADDRESS> snapview -fractureclone -name <clonegroup_name> -cloneid cloneid
(after fracturing see whether the
status showing "clone consistence")
2) java -jar navicli.jar -user user -password password -address <SPA_IPADDRESS>
snapview -listclonegroup -name name
(Note:will show the clone state
including clone id and clone group id)
###4th step
on the second or back-up host -> run admsnap command

1) admsnap flush -O device address


2) java -jar navicli.jar -User USER -Password password -Scope 0 -Address
<SPA_IPADDRESS> snapview -fractureclone -name <clonegroup_name> -cloneid cloneid
(if clone is in synchronised state then ONLY fracture the clone)
3) admsnap clone_activate
4) on second host (you can de-activate the clone by ###admsnap clone_deactivate)

------FOR DESTROYING CLONE GROUP & STORAGE GROUP / REMOVING LUN FROM CLONE FEATURE/
LUNS & HOST FROM STORAGE GROUP--------
*****************NOTE::: THIS IS ONLY TO BE TESTED ONLY IN THE
LAB*****************************

1) java -jar navicli.jar -user user -password password -address <spa_ipaddress>


snapview -removeclone -name NAME -cloneid cloneid
2) navicli -h <SPA_IPADRESS> storagegroup -removehlu -gname name -hlu <LUN_NUMBER>

3) navicli -h <SPA_IPADRESS> storagegroup -disconnecthost -o -host <BACKUPSERVER_IP


OR Server_Name> -gname name
4) java -jar navicli.jar -user user -password password -address <spa_ipaddress>
snapview -removeclone -name NAME -cloneid cloneuid
5) navicli -h <SPA_IPADDRESS> storagegroup -destroy -gname name
6) java -jar navicli.jar -user user -password password -address <SPA_IPADDRESS>
snapview -deallocatecpl

-----------------------sCRIPT END-----------------

***To Sync Clone again (fracture first then sync again)


java -jar navicli.jar -User USER -Password password -Scope 0 -Address
<SPA_IPADDRESS> snapview -syncclone -name <clonegroup_name> -cloneid cloneid

***To Reverse Sync a clone (fracture first then do reverse-sync)


java -jar navicli.jar -User USER -Password password -Scope 0 -Address
<SPA_IPADDRESS> snapview -reversesyncclone -name <clonegroup_name> -cloneid cloneid

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++
IN THE END OF THE PROCESSES YOU MIGHT HAVE TO REBOOT THE SERVER
or DISCOVER THE NEW DEVICES WHICH IS BEEN CONFIGURED THROUGH
SCRIPT

NOTE: IF YOU WANT TO EXECUTE THESE IN SPECIFIED TIME. PLEASE MENTION IT IN #


crontab of unix system
OR for windows system create batch file scripts.
------------------------------------------------------

Вам также может понравиться