Powershell

OpsMgr Group Maintenance Mode Script with Prompt for Input

Group maintenance mode script for OpsMgr 2007 that prompts user for input. Intended to be used as a desktop shortcut for easy ad-hoc maintenance mode. Instructions for use: http://www.systemcenterforum.org/news/opsmgr-powershell-tip-desktop-shortcut-for-enabling-group-maintenance-mode Based on “One more group maintenance mode script” from Boris Y at http://blogs.msdn.com/boris_yanushpolsky/attachment/8034871.ashx

Create VM from Template SCVMM Powershell Script

This reusable Powershell script will create a new virtual machine from an existing VM template in any SCVMM library. Requires SCVMM 2008 Powershell extensions. Script has 3 required parameters. Run with no parameters and syntax will be echoed to the screen. Be sure to add a license key and administrator password to your template first! […]

Cloning Hyper-V VMs in Powershell Using (Import/Export)

by Taylor Brown, this script retrieves the Msvm_VirtualSystemManagmentService class and the MasterVM’s Msvm_ComputerSystem. It then loops 10 times, first changing the name of the VM and then exporting the VM and finally re-importing the VM. After it completes the 10 interactions it restores the name of original name of the MasterVM.