Subscribe

Volume TotalSize

How can I get the total size of a volume, regardless of the snap reserve setting?

(do I really need to calculate my self??)

In a new empty 100g volume with the default 20% snap reserve, SystemManager reports 100g TotalSpace and 80g AvailableSpace,

while the toolkit returns this:

PS C:\> Get-NaVol testvol |fl

Autosize                     : NetApp.Ontapi.Filer.Volume801.Autosize

BlockType                    : 32_bit

ChecksumStyle                : block

CloneChildren                :

CloneParent                  :

ContainingAggregate          : aggr0

DiskCount                    : 2

ExpiryDate                   :

ExpiryDateDT                 :

FilesPrivateUsed             : 504

FilesTotal                   : 3112959

FilesUsed                    : 96

FormattedExpiryDate          :

InodefilePrivateCapacity     : 31142

InodefilePublicCapacity      : 31142

IsChecksumEnabled            : True

IsInconsistent               : False

IsInvalid                    : False

IsSnaplock                   : False

IsUnrecoverable              : False

IsWraparound                 :

MirrorStatus                 : unmirrored

Name                         : testvol

OwningVfiler                 : vfiler0

PercentageUsed               : 0

PlexCount                    : 1

Plexes                       : {/aggr0/plex0}

QuotaInit                    : 0

RaidSize                     : 7

RaidStatus                   : raid4

RemoteLocation               :

Reserve                      : 0

ReserveRequired              : 0

ReserveUsed                  : 0

ReserveUsedActual            : 0

Sis                          :

SizeAvailable                : 85899227136

SizeTotal                    : 85899345920

SizeUsed                     : 118784

SnapAutodelete               : NetApp.Ontapi.Filer.Volume801.SnapAutodelete

SnaplockType                 :

SnapshotBlocksReserved       : 20971520

SnapshotPercentReserved      : 20

SpaceReserve                 : volume

SpaceReserveEnabled          : True

State                        : online

Type                         : flex

Uuid                         : ab87be12-e5de-11e0-b64b-00a0982a3129

ExpiryDateSpecified          : False

IsInvalidSpecified           : True

IsUnrecoverableSpecified     : True

IsWraparoundSpecified        : False

PercentageUsedSpecified      : True

SpaceReserveEnabledSpecified : True

TotalSize                    : 85899345920

Used                         : 0

Available                    : 85899227136

Dedupe                       : False

Aggregate                    : aggr0

DedupeEnabled                : False

IsDedupeEnabled              : False

Re: Volume TotalSize

Hi Sjallabais!

You can use the SnapshotBlockReserved and SnapshotPercentReserved members returned by Get-NaVol to calculate the size of the volume including the snap reserve, or you can use the Get-NaSnapshotReserve cmdlet like this:

PS C:\> (Get-NaVol testvol).TotalSize + (Get-NaSnapshotReserve testvol).Size

21474836480

Hope that helps!

Steven

Re: Volume TotalSize

And Get-NaVolSize works pretty good too. 

PS C:\> get-navolsize testvol

      VolumeSize

      ----------

     21474836480

Volume TotalSize

Thanks!

(although for easier coding, it would have been nice that i was available directly from the Get-NaVol cmdlet)

/Sjalla