Widget to display volume capacity changes

Hi guys,

I'm looking for a way to get any volume that has had a size change (ie a volume that has been extended or shrunk) over the last 7 days to be shown in a table.

The reason for this is that although the capacity forecast tells us how long it anticipates a volume will have before it reaches capacity, it doesn't factor in if one of our infrastructure team has increased that volume's capacity 4 times in the last 5 days or whenever.

On a secondary note, the Volume Size value seems to be recorded in kb or bytes and I need that to be formatted to MB or GB (GB would be better to be honest)

I'd be eternally grateful to anyone who has some natty SWQL queries to get that info out.

Thanks!

Parents
  • Hi

    What do you think about this?

    SELECT 
    N.Caption AS [Node]
    ,V.Caption AS [Volume]
    ,Round(MIN(DiskSize)/1024/1024/1024,0) AS [MinDisk_GB]
    ,Round(MAX(DiskSize)/1024/1024/1024,0) AS  [MaxDisk_GB]
    ,N.DetailsUrl AS [_LinkFor_Node]
    ,V.DetailsUrl AS [_LinkFor_Volume]
    --,PercentDiskUsed
    FROM Orion.VolumeUsageHistory AS VS
    INNER JOIN Orion.Volumes AS V on VS.VolumeID=V.VolumeID
    INNER JOIN Orion.Nodes AS N ON V.NodeID=N.NodeID
    WHERE
        VS.DateTime>GETUTCDATE()-7 --Check last x days
        AND V.VolumeTypeID IN (4,100) --Fixed disk or mount point
    GROUP BY N.Caption,V.Caption, N.DetailsUrl, V.DetailsUrl
    HAVING MAX(VS.DiskSize)<>MIN(VS.DiskSize)

    Add this to a custom query widget.

  • This is fantastic - is there a way to modify this to show used space growth in MB (or GB) rather than percentage of capacity? It's just that we regularly increase the size of virtual disks and so the percentage used may not indicate correctly the growth of a volume - for example, a 200GB disk might at one point have 180GB used, and so we increase the disk capacity to 300 GB thus reducing the used percentage would reduce to 60% then when the disk usage increases to say 240GB, even though the disk space usage in real terms the used percentage would be 80%, so this would report as the disk shrinking rather than actually increasing in usage by 60GB.

    Hope that example makes sense! So do you think it is possible to use the change in the actual disk usage in GB?

    Thanks!

Reply
  • This is fantastic - is there a way to modify this to show used space growth in MB (or GB) rather than percentage of capacity? It's just that we regularly increase the size of virtual disks and so the percentage used may not indicate correctly the growth of a volume - for example, a 200GB disk might at one point have 180GB used, and so we increase the disk capacity to 300 GB thus reducing the used percentage would reduce to 60% then when the disk usage increases to say 240GB, even though the disk space usage in real terms the used percentage would be 80%, so this would report as the disk shrinking rather than actually increasing in usage by 60GB.

    Hope that example makes sense! So do you think it is possible to use the change in the actual disk usage in GB?

    Thanks!

Children
No Data