search
Categories
Sponsors
VirtualMetric Hyper-V Monitoring, Hyper-V Reporting
Archive
Blogroll

Badges

Microsoft PowerShell MVP
MCSE
Sponsors

Cozumpark Bilisim Portali
Assign static mac id for virtual machine with Powershell on SCVMM
Posted in Virtual Machine Manager, Windows Powershell | No Comment | 4,956 views | 28/04/2009 02:06

A few weeks ago, i had to assign static mac ids for virtual machines. I wrote this script to assign static mac ids to virtual machines on SCVMM 2008 with Powershell:

1
2
3
4
5
Add-PSSnapin -name Microsoft.SystemCenter.VirtualMachineManager
Get-Vmmserver localhost
$VMNo = $args[0]
$MAC = New-PhysicalAddress -Commit
New-VirtualNetworkAdapter -VM $VMNo -PhysicalAddress $MAC

You can identify your VM’s with their Mac ID’s. So, I think assigning static mac id is better. I hope, it works for you.



Leave a Reply