Here’s a sample script
REM CONTROLLER is the SnapVault target NetApp Controller
set CONTROLLER=torfiler3
REM SECPATH is the path to the SnapVault Volume on the target controller including the qtree
set SECPATH=/vol/vmblock1vault/vmblock1
REM SVSCHED is the schedule name for the retention schedule configured on the SnapVault volume
set SVSCHED=smvi_weeklyvault
REM SVVOLUME is the SnapVault target volume not including the qtree
set SVVOLUME=vmblock1vault
REM USER is the limiter user id for the SnapVault transfer
set USER=limited-SV-user
REM PASSWORD is the password for the limited user
set PASSWORD=smv1rocks
REM SNAPNAME is the name of the snapshot to be transfered
set SNAPNAME=smvi__weeklyISCSI1_recent
REM ZAPIPATH is the path to the ONTAP SDK
set ZAPIPATH="E:\Program Files\NetApp\Virtual Storage Console\smvi\server\scripts"
REM LOGPATH Is the path to the log generated by the SMVI script
set LOGPATH="E:\Program Files\NetApp\Virtual Storage Console\smvi\server\log\scripts"
REM LOGFILE is the logfile generate by the SMVI script
set LOGFILE=SnapVaultScript.log
if %BACKUP_PHASE% == POST_BACKUP goto doSnapVault
goto ende
:doSnapVault
echo SCRIPT STARTING FOR SMVI JOB:%BACKUP_NAME%>>%LOGPATH%\%LOGFILE%
echo BEGIN SNAPVAULT UPDATE>>%LOGPATH%\%LOGFILE%
chdir %ZAPIPATH%>>%LOGPATH%\%LOGFILE%
echo BEGIN SNAPVAULT UPDATE FOR %SVVOLUME%>>%LOGPATH%\%LOGFILE%
apitest.exe %CONTROLLER% %USER% %PASSWORD% snapvault-secondary-initiate-incremental-transfer primary-snapshot %SNAPNAME% secondary-path %SECPATH%>>%LOGPATH%\%LOGFILE%
apitest.exe %CONTROLLER% %USER% %PASSWORD% snapvault-secondary-initiate-snapshot-create schedule-name %SVSCHED% volume-name %SVVOLUME%>>%LOGPATH%\%LOGFILE%
echo END SNAPVAULT UPDATE FOR %SVVOLUME%>>%LOGPATH%\%LOGFILE%
echo