Subscribe
Accepted Solution

Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hi,

 

I want the operator of workflows choose from a list of snapshot of volumes (e. g. to use it as a base for a cloning operation). For this I need the snapshots of cDOT volumes in a table (e. g. cm_storage.snapshot) in order to use sql statements to select them.

 

I am aware of the discussions in thread1 or in thread2.

 

But the solution in thread2 cannot be imported in WFA3.1 (see my comments in both threads). Meanwhile the creator of the solution in thread2 has left NetApp and may not update it. NetApp itself seems not to be able or willing to solve this issue (either in  filling this table in WFA by default or porting the solution of thread2 to WFA3.1).

 

I would create this table, datasource and OCUM/cluster connection by myself, if someone can tell me the steps how to do this.

 

Is there somebody who can describe/share what to do to get such a table filled with snapshot names from clustered DataONTAP volumes?

 

Thanks in advance.

 

Walter

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hi Walter,

 

You can refer this pack "Manage SnapMirror-SnapVault Cascade Relationship"  for caching snapshots directly from C-Dot.

 

http://automationstore.netapp.com/pack-list.shtml

 

Regards,

Pavan

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

This is a NetApp certified pack.

I would recommend to use the snapshot dictionary and cache queries from this pack.


Regards,

Abhi

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hi Abhi,

 

I am still unable to filter the snapshot for cluster mode volume .

 

Do you have a query to get it ? im using WFA 3.0.0.0.1P1.

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hello,

 

I like to know your requirement first.

I can see, there is a table namely 'Snapshot' under cm_storage_smsv from which you can pick the snapshots.

 

So I think, below query will suffice the same:

 

SELECT

    Snapshot.name AS 'name',

    Snapshot.volume AS 'volume',

    Snapshot.vserver AS 'vserver',

    Snapshot.cluster AS 'cluster',

    Snapshot.snapmirror_label AS 'snapmirror_label',

    Snapshot.timestamp AS 'timestamp'

FROM

    cm_storage_smsv.Snapshot Snapshot

WHERE

          Snapshot.volume = '${VolumeName}'

          AND Snapshot.cluster = '${ClusterIP}'

          AND Snapshot.vserver = '${VServerName}'

 

Let me know if I misunderstood something.

Thanks

                --Gaurab

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hi Gaurab,

 

Actually i am preparing workflow for clone creation in C-Mode and i am alomst done with workflow just filtering snapshot is not working .

 

i have used the below query but im getting the error while using this query , can you help me on this ?

 

Failed to execute query for user input '$snapshot':
SELECT command denied to user 'restricted'@'localhost' for table 'snapshot'

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hello Suresh,

 

I'm really very sorry, I didn't understand your problem.

 

Did you mean, the query I've sent is not working?

 

How/where/when did you get the message

"

Failed to execute query for user input '$snapshot':
SELECT command denied to user 'restricted'@'localhost' for table 'snapshot'

"

?

 

Can you plesae share some screen shot or elaborate the same or can share me your incomplete dar on which I can have a look.

 

Thanks,

   --Gaurab

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hi Abhi,

 

I have attached the screen shot of my priview , while choosing parent volume it should automatically filter the snapshot .

 

I would like set the variable for snapshot and filter it .

 

clone.PNG

 

Thanks

 

S Suresh

 

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hello Suresh,

 

Whatever I've understood the problem, you need to do the following task:

  1. Create a data_source (scheme) for snapshots. For the same please write a script (in PowerShell) - The script collects volume snapshot information from the Clustered Data ONTAP.
  2. Create a dictionary entry for Snapshots of a volume on a Clustered Data ONTAP. This dictionary should point to the above created scheme.
  3. Now you can create your own query within your custom command(s) using the Snapshot dictionary entry mention in step 2.

LMK if you need any more help from us.Smiley Happy

 

Thanks,

   --Gaurab

Re: Need snapshot names of clustered Data ONTAP volumes in WFA3.1 for use in user input fields

Hi Gaurab,

 

I am not familier with Scheme and Powershell script , please help me to achive this .