Creating Design and Implementation Documents with NetappDocs

Alexandru Vasile

Senior Storage Engineer - Netapp

NetAppDocs tool is a PowerShell module and contains a set of functions that automate the creation of NetApp® site design documentation. NetAppDocs can generate Excel, Word and PDF document types.

The intent of the tool is to automate documentation based on specific storage configurations.

The idea is that, while documentation tries to fit all use cases, it’s not perfect and cannot adapt to varying configurations. By using this tool, we can generate a set of docs that cover specific configurations.

Another use case that came up recently at NetApp was to document the default options for ONTAP in an easy to find, easy to read format. While the man pages keep most of this information, it can be time consuming to trawl through the pages and pages of docs out there. With this tool, once a cluster is installed, simply run it and get the default option settings right off the bat.

Additionally, the data collected can be useful for support cases where ASUP isn’t sending to NetApp for whatever reason.

The goal of this article is to show how to generate design and implementation documents using the NetappDocs modules from install to the end reports/documents.

Prerequisites :

    System Requirements :
  1. Microsoft Windows PowerShell 3.0 or higher.
  2. Microsoft .Net Framework 4.0 or higher.
  3. NetApp Data ONTAP PowerShell Toolkit

The tool install package : https://mysupport-beta.netapp.com/site/tools/tool-eula/netappdocs/download

User guide : https://mysupport-beta.netapp.com/api/tools-service/toolsbinary/netappdocs/download/NetAppDocs_User_Guide.pdf

Step 1 - Installation :

Run the *.msi installer

->>> press next.

Accept the license agreement and press > next.

Select the desired install path ; for this demo default path is used .

Press > install .

Installation has concluded press > Finish.

Step 2 – Importing NetappDocs modules :

Run power shell with elevated permissions ( Run as administrator ) .

Run in PS > Set-ExecutionPolicy -ExecutionPolicy RemoteSigned

            Press Y.

Verify Policy using Get-ExecutionPolicy command 

Import the modules using Import-Module NetAppDocs

Verify the import by using the command Get-Module -Name NetAppDocs

or help use command Show-NtapDocsHelp – it will pop a new page in the browser .

Help page popup below :

List all the module list using : Get-Command -Module NetAppDocs

For additional help use the command Get-Help -Name

Step 3 – Setting up variables :

Set the name and management ip of the ontap device in windows hosts ( in my case ontapsimulator is used ) .

IP and hostname is to be set .

Use command $Credential = Get-Credential to set this variable ( use admin and password for Netapp device )

Additionally it can be set for specific ontap cluster as below using Add-NcCredential -Controller ontapsim -Credential (Get-Credential) :

View the entry :

This concludes this step .

Step 4 – Generating the documentation and reports :

XML config export can be done using Get-NtapClusterData with Export-Clixml parameter as shown below  :

ClusterView Docx and xlsx can be exported with one command a: Get-NtapClusterData -Name ontapsim | Format-NtapClusterData | Out-NtapDocument -WordFile 'C:\ALEF\ontapsim.Docx' -ExcelFile 'C:\ALEF\ontapsim.xlsx'

The command will generate the files in the specified locations ( this is the ClusterView ) .

Reports look like bellow :

There is also a SVM View: using the same command Get-NtapClusterD but this time with Format-NtapVserverData parameter

EX :

Get-NtapVserverData -Name 'NFS_SVM', 'iscsi_SVM' -ClusterName 'ontapsim' | Format-NtapVserverData | Out-NtapDocument -WordFile 'c:\ALEF\Nas_SVMs.docx' -ExcelFile 'c:\ALEF\Nas_SVMs.xlsx'  

NOTE : ASUP data collection is supported ; data can be gathered using Get-NtapClusterAsupData command.

 Another interesting feature is the ability of creating Differences Reports

Differences Reports are done using as input the xml files exports and the command : Compare-NtapDocsData

EX :

Get-NtapClusterData -Name 'ontapsim' | Format-NtapClusterData | Out-NtapDocument -XmlFile C:\ALEF\ontapsim_01-2020.xml

Get-NtapClusterData -Name 'ontapsim' | Format-NtapClusterData | Out-NtapDocument -XmlFile C:\ALEF\ontapsim_03-2020.xml

Compare-NtapDocsData -XmlFile1 C:\ALEF\ontapsim_01-2020.xml -XmlFile2 C:\ALEF\ontapsim_03-2020.xml | Out-NtapDocument -XlxsFile C:\ALEF\ontapsim_DiffReport.xlsx

This concludes the short article about  generating Design and Implementation Documents with NetappDocs.

For more in detail information please check the User guide.


Do you have any questions about Netapp products?

Contact us