Data Backup and Recovery

A single command for restores

prateek_sin
6,353 Views

Hi All,

I would like to know is there any option in SnapCreator 3.4.0 to restore a single file or a volume without using the interactive restore.

I am looking for a single command that can take all the inputs as parameters and display the result of the command.

   OR

Can a file that stores all the inputs( required in  interactive restore) be provided as input the snapcreator restore command ?

Thanks in Advance

Prateek Sinha

1 ACCEPTED SOLUTION

ktenzer
6,337 Views

Answers below

Also I would like to know, are the following features present in the SnapCreator 3.5.0c ?

1)  non interactive deletion of snapshots and volume clones (CLI Based)

Yes

Deletion of clone:

./snapcreator --profile 443 --action umount --clone_name cl_443_sc_qa_pri1_20111018110824 --snap_name db2prd-daily_20111018111105 --policy daily --verbose

Deletion of snapshot:

./snapcreator --profile 443 --action delete --snap_name db2prd-daily_20111108104417 --volume_name sc_qa_pri1 --non_interactive --policy daily --verbose

2)  non interactive volume restore (CLI Based)

Yes

./snapcreator --profile 443 --action restore --snap_name db2prd-daily_20111108104417 --volume_name sc_qa_pri1 --non_interactive --policy daily --verbose

Regards,

Keith

View solution in original post

9 REPLIES 9

ktenzer
6,353 Views

Hi Prateek,

Yes SC 3.4.0 supports a non-interactive volume restore, single file restore is only available through interactive CLI or GUI interface

The key is specifying following:

--snap_name

--volume_name

--non_interactive

--action restore

./snapcreator --profile 443 --action restore --policy daily --volume_name keith --snap_name db2prd-daily_20110930115221 --non_interactive --verbose

Hope this helps!

Keith

prateek_sin
6,353 Views

Hi Keith,

Thanks a lot !  for your response.

I used the following command for a volume restore, this gave an error saying volume_name is not an option . Please see the details below.Also Config file is attached in this post.

Is there any change required in the config file ..?

________

[root@fcrhel configs]# ../snapcreator --profile NFS_Share_Profile --action restore --policy hourly --volume_name /vol/Oracle_Control_Files --snap_name snap_test-hourly_20001004172657 --non_interactive --verbose

Unknown option: volume_name

Usage: ../snapcreator {--profile <Profile> --action <Action> --policy <Policy> <Optional Arguments> | --start-agent <port>

Configuration File

Regards,

Prateek Sinha

________

ktenzer
6,353 Views

Make sure you have SC 3.4.0, these options are only available in 3.4.0 not 3.3.0

Also your argument should be as follows (no /vol in frton of volume name):

./snapcreator --profile NFS_Share_Profile --action restore --policy hourly --volume_name Oracle_Control_Files --snap_name snap_test-hourly_20001004172657 --non_interactive --verbose

Regards,

Keith

prateek_sin
6,337 Views

Hi Keith,

I tried the following command as suggested by you still the output is same, also I made sure the I am using the correct version of SnapCreator (3.4.0).I am unable to find out the issue:

________


[root@fcrhel scServer3.4.0]# pwd

/root/SnapCreator3.4.0/scServer3.4.0

[root@fcrhel scServer3.4.0]#

[root@fcrhel scServer3.4.0]# ls

configs gui LICENSE logs NOTICE.PDF plugins snapcreator

[root@fcrhel scServer3.4.0]# ls

configs gui LICENSE logs NOTICE.PDF plugins snapcreator

[root@fcrhel scServer3.4.0]# cd configs/

[root@fcrhel configs]# ls

default NFS_Share_Profile non_interactive

[root@fcrhel configs]# cd NFS_Share_Profile/

[root@fcrhel NFS_Share_Profile]# ls

NFS_Share_Profile.conf

[root@fcrhel NFS_Share_Profile]# cd ..

[root@fcrhel configs]# ls

default NFS_Share_Profile non_interactive

[root@fcrhel configs]#

[root@fcrhel configs]# cd ..

[root@fcrhel scServer3.4.0]# ./snapcreator -version

NetApp Snap Creator Framework 3.4.0

[root@fcrhel scServer3.4.0]# ./snapcreator --profile NFS_Share_Profile --action restore --policy hourly --volume_name Oracle_Control_Files --snap_name snap_test-hourly_20001004172657 --non_interactive --verbose


Unknown option: volume_name

Usage: ./snapcreator {--profile <Profile> --action <Action> --policy <Policy> <Optional Arguments> | --start-agent <port>



________

Also I would like to know the command for non interactive deletion of snapshots and volume clones. The command that I used did not do the job, its mentioned below:

_________


[root@fcrhel scServer3.4.0]#

[root@fcrhel scServer3.4.0]# ls

configs gui LICENSE logs NOTICE.PDF plugins snapcreator

[root@fcrhel scServer3.4.0]# ./snapcreator --version

NetApp Snap Creator Framework 3.4.0

[root@fcrhel scServer3.4.0]# ./snapcreator --profile NFS_Share_Profile --action snaplist

########## NetApp Snap Creator Framework Snapshot (Primary) List for 157.227.25.101:Oracle_Control_Files #########

### Snapshot Name ### ### Snapshot Timestamp ###

snap_test-hourly_20001004172657 Oct 04 2011 17:27:15

snap_test-hourly_20001004173436 Oct 04 2011 17:34:55

snap_test-hourly_20001004174725 Oct 04 2011 17:47:43

[root@fcrhel scServer3.4.0]#

[root@fcrhel scServer3.4.0]# ./snapcreator --profile NFS_Share_Profile --action delete --policy hourly --snap_name snap_test-hourly_20001004172657 --non_interactive --verbose


Unknown option: non_interactive

Usage: ./snapcreator {--profile <Profile> --action <Action> --policy <Policy> <Optional Arguments> | --start-agent <port>


_________

Thanks and Regards,

Prateek

ktenzer
6,337 Views

I am sorry I got confused...the non-interactive option is only available in Snap Creator 3.5.0 not 3.4.0. It will be released on NOW on Jan 12 2012. In meantime if you are partner you can access www.snapcreator.com and download the community version 3.5.0c but there is NO NGS support for it just community.

Regards,

Keith

prateek_sin
6,337 Views

Thanks for the info Keith

Also I would like to know, are the following features present in the SnapCreator 3.5.0c ?

1)  non interactive deletion of snapshots and volume clones (CLI Based)

2)  non interactive volume restore (CLI Based)

Regards,

Prateek

ktenzer
6,338 Views

Answers below

Also I would like to know, are the following features present in the SnapCreator 3.5.0c ?

1)  non interactive deletion of snapshots and volume clones (CLI Based)

Yes

Deletion of clone:

./snapcreator --profile 443 --action umount --clone_name cl_443_sc_qa_pri1_20111018110824 --snap_name db2prd-daily_20111018111105 --policy daily --verbose

Deletion of snapshot:

./snapcreator --profile 443 --action delete --snap_name db2prd-daily_20111108104417 --volume_name sc_qa_pri1 --non_interactive --policy daily --verbose

2)  non interactive volume restore (CLI Based)

Yes

./snapcreator --profile 443 --action restore --snap_name db2prd-daily_20111108104417 --volume_name sc_qa_pri1 --non_interactive --policy daily --verbose

Regards,

Keith

prateek_sin
6,337 Views

Great !!

All the three commands worked with SnapCreator 3.5.0c

Regards,

Prateek

ktenzer
6,337 Views

Good news!

You are welcome to use 3.5.0c or wait till the NetApp NGS supported version is released to NOW on Jan 12 2012

For support with 3.5.0c you can certainly ask questions here but you should sign up for the developer community @ www.snapcreator.com

You can reports bugs etc here:

https://github.com/NetApp/SC-Framework/issues

Regards,

Keith

Public