Microsoft Virtualization Discussions

Need help to understand the way to automate activities in netapp filer

netappwala
6,672 Views

Hi,

 

I wanna start automating activities in my filers.

 

I know there is something called NetApp DataOnTap tool kit for PowerShell to automate activities. I want to know what other options we have.

 

And can anyone tell me what kind of activities can be automated using PowerShell DOT tool kit?

 

 

Thanks,

Charan

1 ACCEPTED SOLUTION

asulliva
6,528 Views

My preference is to use the PowerShell Toolkit for doing things that I need to do more than once.  For example, creating volumes, particularly when I am customizing the volume options such as disabling atime_update for VMware datastores.  It's tedious to do these things using any of the GUI tools, and error prone when using the CLI where you have to re-type the command(s) each time.

 

For regular polling (for example, every 1 or 5 minutes) of performance and health data against your systems, it's probably best to use something like Unified Manager, Performance Manager, or Harvest + Graphana.  For ad hoc checks, the PowerShell Toolkit is still an excellent tool.

 

I honestly can't say there has ever been a situation where the PowerShell Toolkit was the only option...you can always use one of the other languages in the NMSDK such as Perl, Python, etc., use the GUI, or use the CLI...but I often find the Toolkit to be the most convenient.  For example, a simple list of volumes...with the CLI it's difficult, if not impossible, to order the volumes by percentage used.  With the Toolkit, it's simple, quick, and easy: 

 

Get-NcVol | Sort-Object -Property Used

Where I think the Toolkit really becomes useful is when you want to find esoteric information about your systems.  For example, I want to see all aggregates which have partial RAID groups:

 

Get-NcAggr | ?{ ($_.AggrRaidAttributes.RaidSize * ($_.AggrRaidAttributes.Plexes.Raidgroups.Count | Measure-Object -Sum).Sum) -ne $_.AggrRaidAttributes.DiskCount }

If you're automating things, then you can use the other languages, but I almost always find it faster to do equivalent tasks in PowerShell vs {Perl, Python, .NET, C/C++, Java, etc.}.  They are all equivalently powerfull...PowerShell doesn't have access to more or less of the API than any other langauage...I just find creating scripts to do things faster in PowerShell.  To be fair, this is purely preference...I know people who would choose Perl or Python over PowerShell for the same reason.  Plus, it's really easy to take a PowerShell script and create an equivalent WFA workflow to make your automation available to anyone who can click a GUI.

 

Hope that helps.

 

Andrew

If this post resolved your issue, please help others by selecting ACCEPT AS SOLUTION or adding a KUDO.

View solution in original post

7 REPLIES 7

JGPSHNTAP
6,654 Views

You can do just about anything from monitoring to creating to removing.. It's essentially a full API into the system.

 

 

asulliva
6,646 Views

Hi Charan,

 

The NetApp PowerShell Toolkit is available here, pretty much anything you can do from the CLI you can do from PowerShell.  If you aren't interested in PowerShell, there are also a number of other SDKs available from the NetApp Manageability SDK, avaialble from the MySupport software downloads page.  The NMSDK includes libraries to help with .NET, python, perl, C/C++, and many other languages.

 

Hope that helps.

 

Andrew

If this post resolved your issue, please help others by selecting ACCEPT AS SOLUTION or adding a KUDO.

netappwala
6,533 Views

Hi Andrew,

 

Thanks for giving useful information.

 

We have DFM and few other tools for monitoring and performing activties. Everyone prefer to use them instaed of going with PSTK. As I like programming I am trying to convince myself to use PSTK, but how can I expaline others that why I am choosing this path.

 

Based on your experience... It would be great if you can share a sceneario where you had felt that PSTK was the only solution.

 

 

Regards,


Charan

asulliva
6,529 Views

My preference is to use the PowerShell Toolkit for doing things that I need to do more than once.  For example, creating volumes, particularly when I am customizing the volume options such as disabling atime_update for VMware datastores.  It's tedious to do these things using any of the GUI tools, and error prone when using the CLI where you have to re-type the command(s) each time.

 

For regular polling (for example, every 1 or 5 minutes) of performance and health data against your systems, it's probably best to use something like Unified Manager, Performance Manager, or Harvest + Graphana.  For ad hoc checks, the PowerShell Toolkit is still an excellent tool.

 

I honestly can't say there has ever been a situation where the PowerShell Toolkit was the only option...you can always use one of the other languages in the NMSDK such as Perl, Python, etc., use the GUI, or use the CLI...but I often find the Toolkit to be the most convenient.  For example, a simple list of volumes...with the CLI it's difficult, if not impossible, to order the volumes by percentage used.  With the Toolkit, it's simple, quick, and easy: 

 

Get-NcVol | Sort-Object -Property Used

Where I think the Toolkit really becomes useful is when you want to find esoteric information about your systems.  For example, I want to see all aggregates which have partial RAID groups:

 

Get-NcAggr | ?{ ($_.AggrRaidAttributes.RaidSize * ($_.AggrRaidAttributes.Plexes.Raidgroups.Count | Measure-Object -Sum).Sum) -ne $_.AggrRaidAttributes.DiskCount }

If you're automating things, then you can use the other languages, but I almost always find it faster to do equivalent tasks in PowerShell vs {Perl, Python, .NET, C/C++, Java, etc.}.  They are all equivalently powerfull...PowerShell doesn't have access to more or less of the API than any other langauage...I just find creating scripts to do things faster in PowerShell.  To be fair, this is purely preference...I know people who would choose Perl or Python over PowerShell for the same reason.  Plus, it's really easy to take a PowerShell script and create an equivalent WFA workflow to make your automation available to anyone who can click a GUI.

 

Hope that helps.

 

Andrew

If this post resolved your issue, please help others by selecting ACCEPT AS SOLUTION or adding a KUDO.

netappwala
6,520 Views

Many thanks Andrew....really great explanation. I will be asking you more technical questions about PSTK in future, hope you will help Smiley Happy

 

 

Regards,

 

Charan

paulstringfellow
6,473 Views

Andrew is an excellent resource and certainly knows his stuff in great detail.

 

if you want to find out more about what he knows, but also NetApp capability on general, I'd suggest give the NetApp podcast a go... lot's of great episodes and an excellent resource of NetApp information.

 

you won't regret it!!

 

http://community.netapp.com/t5/Technology/bg-p/technology/label-name/tech%20ontap%20podcast

paulstringfellow
6,612 Views

Powershell toolkit is great as suggested and will allow masses of automation.

 

also shouldn't forget, the SMI-s integration that will allow automation of process with VMM if you are using that.

 

also the plugins for system centre which will provide information, and with the use of Orchestrator the ability to act on alerts etc and start to build workflows there... so tonnes of stuff you can do!

Public