NetApp Community Update
This site will enter Read Only mode on July 23 as we prepare to move to a new platform. You will still be able to view content, but posting and replying will be temporarily disabled.
We're excited to launch our new Community experience on July 30 and more information will follow soon.
Stay connected during the transition - Join our Discord community today.

Microsoft Virtualization Discussions

DataOntap Powershell get-navol command

GNaiding
4,727 Views

Hi All,

 

I am trying to fetch the volume available space from the command get-NaVol.

 

$vol1=get-navol -name <volname> | select sizeavailable

 

It give the results

 

sizeavailable: 982983454

 

But I am not able to get the numeric value. Can this be truncated to just values?

 

Actually I am trying to compare two volume free spaces.

 

Please HELP me on this.

 

 

 

1 REPLY 1

JGPSHNTAP
4,709 Views

This is because you are specifically calling our a property...

 

You need to use the convertto-formattednumber cmdlet

 

 

Try this.

 

convertto-formattednumber (get-navol -name <volname>).sizeavailable datasize "0.0"

 

 

 

Public