A blog about my exerience with Clouds, Automation and Virtualization
A PowerShell function for Snapshot reporting in VMM2012
Hello
I am in the hotel waiting for the MMS 2012 to start so there is time for some automation ;-). Last week when I was teaching a course one of the attendes said after I showed the custom value function, that he also wanted a similar function for easy in the console check how many snapshots every VM had. In the VMM 2012 console I have not found an built-in function to actually show this.
I have modified the function and created the run script, this is scheduled to run once a hour so you have a updated view of your environment. At least in the Hyper-V for Windows 2008 R2 it is not recommended to use in production.
It is quite easy to create a new custom property that we then will populate,
In the GUI there is no way to remove a custom property, I can only remove it from assigned properties. During the course I created an property just for showing and want to get rid of it. Of course there is a powershell cmdlet for that:
# Script to use for scheduled updates of Custom values
2
#
3
# Niklas Akerlund / RTS 2012-04-16
4
5
ipmo 'C:\Program Files\Microsoft System Center 2012\Virtual Machine Manager\bin\psModules\VirtualMachineManager'| Out-Null
6
7
. .\Set-CVSnapshot.ps1
8
Set-CVSnapshot
And in the VMM Console it looks like this
I will talk to some VMM responsibles at MMS and see if they find an interest and build the view instead of me running it in a sheduled task (as the information is there in the database)