Array Performance and Data Protection
1751959 Members
5350 Online
108783 Solutions
New Discussion юеВ

Re: Hello All! Is there a way to show total volume and snapshot usage of volumes using the CLI?

 
SOLVED
Go to solution
scottie88
Occasional Advisor

Hello All! Is there a way to show total volume and snapshot usage of volumes using the CLI?

Hello All!

Is there a way to show total volume and snapshot usage of volumes using the CLI?

In the web GUI, you can go to Manage > Volumes > Space and it will give you a wonderful list of volumes, sizes, Volume Usage, Snapshot Usage and Total Usage; however, there isn't a way cleanly to pull all that data, shove it into an excel report and hand it to management. Nor could you just print the web GUI and hand it to them as it only will show 21 out of my 171 volumes at a time. I can try and copy the lines from the web GUI, 21 at a time, paste them into a text editor or Excel and try and clean them up, but this is cumbersome.

IS there an easy way to pull the same information via CLI and then be able to dump it to Excel? Something like the below, which is an example of what the collected data from the web GUI looks like after being clean up.

Volume    Size    Volume Usage    Snapshot Usage    Total Usage

BC-NIM-VMFS-TRAFFIC-C.OS-01    1.0 TB    137.7 GB    42.6 GB    180.29 GB

BC-NIM-VMFS-TRAFFIC-DB-D.DATA    256.0 GB    184.44 MB    83.47 MB    267.91 MB

BC-NIM-VMFS-TRAFFIC-S.SWAP-01    256.0 GB    982.56 MB    2.54 GB    3.5 GB

BC-NIM-VMFS-VCENTER-COS-01    1.0 TB    121.6 GB    75.75 GB    197.35 GB

BC-NIM-VMFS-VCENTER-DDATA-01    2.0 TB    271.71 GB    40.64 GB    312.35 GB

BC-NIM-VMFS-VCENTER-SSWAP-01    512.0 GB    6.56 GB    347.01 MB    6.9 GB

Scottie

3 REPLIES 3
Nick_Dyer
Honored Contributor
Solution

Re: Hello All! Is there a way to show total volume and snapshot usage of volumes using the CLI?

Hi Scottie,

Welcome to the forums.

The best way to get this information is to head to Infosight and click on 'Volumes', then click "Export". You'll get all the information you require in a handy CSV file where you can then manipulate it to your requirements.

Nick Dyer
twitter: @nick_dyer_
jcates98
Trusted Contributor

Re: Re: Hello All! Is there a way to show total volume and snapshot usage of volumes using the CLI?

I agree 100% with Nick that InfoSight is the best way to go.

That said, I wouldn't want to miss the opportunity to introduce you to the Nimble PowerShell Toolkit. We describe it HERE on Nimble Connect.

With the PS Toolkit, this is a pretty simple task as well.  You can use the following one-liner after connecting to a Nimble array:

Get-NSVolume | select name,size,vol_usage*,snap_usage* | ConvertTo-Csv > vols.csv

You then end up with something like this:

vols-csv.png

From there it's just a matter of summing.

Cheers!

Julian

scottie88
Occasional Advisor

Re: Hello All! Is there a way to show total volume and snapshot usage of volumes using the CLI?

Nick,

Thank you, this is useful and I am surprised i missed the export. The only thing I noticed is that is seems to prune some of the info. In the export under Snapshot Used (GB), in the size in under 1GB, it reports as 0. In the web GUI same volume would shows SNAPSHOT SPACE Used 3.65 MB. Granted its such a small thing in the amount of data and I get it may not report things under 1GB, but those I would show the report to would question it and ask why the volume wasn't being snapshotted when it is and is consuming a small amount of data.