Building Flexible HyperV Environments Windows Server 2012 HyperV Live Migration and Live Storage Migration Ben Armstrong Senior Program Manager Lead Microsoft Corporation VIR304 Mobility Core to Private Cloud ID: 763932
Download Presentation The PPT/PDF document "Building Flexible Hyper-V Environments W..." is the property of its rightful owner. Permission is granted to download and print the materials on this web site for personal, non-commercial use only, and to display it on your personal computer provided you do not modify the materials and that you retain all copyright notices contained in the materials. By downloading content from our website, you accept the terms of this agreement.
Building Flexible Hyper-V Environments Windows Server 2012 Hyper-V Live Migration and Live Storage Migration Ben ArmstrongSenior Program Manager LeadMicrosoft Corporation VIR304
Mobility Core to Private Cloud Virtualization is the basis of a Microsoft private cloudVirtual machine mobility is key an efficient and responsive private cloud deployment
Agenda Live Migration
Live Migration without Infrastructure You can even live migrate virtual machines between two Hyper-V servers with no shared infrastructureNeed to be in the same domain Entire virtual machine moved (VHDs + running state) with no downtime
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks Negotiation
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks LM Connection
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks LM Connection Storage Migration
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks LM Connection Virtual Hard Disks Storage Mirror
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks LM Connection Virtual Hard Disks Storage Mirror Live Migration
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks LM Connection Virtual Hard Disks Storage Mirror Live Migration
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks LM Connection Virtual Hard Disks
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine LM Connection Virtual Hard Disks
Hyper-V Server 1 Hyper-V Server 2VMMS VMMS Virtual Machine Virtual Hard Disks
Demo Live Migration
PowerShell Move-VM "File Server 1" "benarm-zeta" ` -IncludeStorage –DestinationStoragePath ` "J:\Virtual Machines\File Server 1"
Agenda Live Migration using SMB
Live Migration with SMB Storage is not moved, just the running virtual machineLike live migration in a cluster, without high availability Requires SMB 3.0 VIR306: Hyper-V over SMB2: Remote File Storage Support in Windows Server 2012 Hyper-V
Setting up SMB for Live Migration There are a couple of steps involved in getting this rightBoth users and computers need access to the share
Setting up the share – Share Permissions
Setting up the share – Share Permissions
Setting up the share – Share Permissions
Setting up the share – File Permissions
Setting up the share – File Permissions
Setting up the share
Setting up the share
PowerShell MD X:\VMSICACLS.EXE X:\VMS --% /Grant NTDEV\benarm :(CI)(OI)FICACLS.EXE X:\VMS --% /Grant NTDEV\benarm-epsilon$:(CI)(OI)FICACLS.EXE X:\VMS --% /Grant NTDEV\benarm-zeta$:(CI)(OI)FICACLS.EXE X:\VMS /Inheritance:RNew-SmbShare -Name VMS -Path X:\VMS –FullAccess ` NTDEV\ benarm , NTDEV\ benarm -epsilon$, NTDEV\ benarm -zeta$
Demo Live Migration - SMB
PowerShell Move-VM "File Server 2" "benarm -zeta"
Agenda Live Migration and Clusters
Live Migration Improvements Live Migration in Windows Server 2008 R2 is greatbut how to make it better?
Live Migration Improvements Live Migration in Windows Server 2008 R2 is greatbut how to make it better?Faster Concurrent live migrationDeeper integration into clusteringEtc… WSV324: Building a Highly Available Failover Cluster Solution with Windows Server 2012 from the Ground UP
Live Migration between clusters You can move a virtual machine between two clustersFollow these steps:Remove the virtual machine from the source cluster Use Hyper-V Manager to live migrate the virtual machine to a node in the destination clusterJoin the virtual machine to the destination clusterVirtual machine never needs to be turned offHowever, it is not protected from hardware failure during the course of the migration.
Demo Live Migration between Clusters
Agenda Live Migration Security
Configuring Live Migration
Ensure Live Migration Networks are Secure Physically SecureIPSec / other encryption options
Managing security and authentication This gets very complicated once more than two computers are involvedAnd sometimes even when there are only two computers involved
Credentials Understanding credential security
Credentials Understanding credential security Credentials
Understanding credential security Credentials
How this affects Hyper-V Live Migrate
Live Migrate How this affects Hyper-V Live Migrate
How this affects Hyper-V Live Migrate a VM to me Live Migrate
How to make this work? Two options:Allow user credentials to be shared between the Hyper-V servers – just for the purposes of live migration Enable “Constrained Delegation” in Active DirectoryMake it look like we are actually logged into the Hyper-V server that starts the live migrationPowerShell RemotingRemote Desktop
Enabling Constrained Delegation On the domain controller, open Active Directory Users and Computers .In the console tree, under DomainName, click Computers.Right-click the computer running Hyper-V, and then click Properties.On the Delegation tab, click Trust this computer for delegation to specified services only . Click either Use any authentication protocol or Use Kerberos only . Click Add , and then click Users and Computers.Type the name of the other computer running Hyper-V, and then click OK.From the list of available services, select Microsoft Virtual System Migration Service and CIFS and then click OK .
More Resources Taylor Brown’s Blog:http://blogs.msdn.com/b/taylorb/ Official Documentation:http://technet.microsoft.com/en-us/library/jj134199
PowerShell Remoting with CredSSPOn the server: Enable-WSManCredSSP Server On the clientEnable-WSManCredSSP Client – DelegateComputer <FQDN of the server > Establish the session: New- PSSession <FQDN of the Server> -Authentication CredSSP -Credential <User> | Enter- PSSession Or just run a command: ICM <FQDN of the Server> {<command to run>} -Authentication CredSSP -Credential <User>
Remote Desktop Hopefully I do not need to tell you how to use this
Agenda Storage Migration
Storage Migration Move any part of a running virtual machine with no need to turn it offVHDsConfig files SnapshotsEtc…Perform storage upgrades with no downtimeRespond to I/O bottlenecks with no downtime
Hyper-V VHD Software Storage Migration Architecture Virtual Machine Source Device Destination Device VHD
Hyper-V VHD Software Storage Migration Architecture Virtual Machine Source Device Destination Device VHD VHD
Hyper-V VHD Software Storage Migration Architecture Virtual Machine Source Device Destination Device VHD VHD
Hyper-V VHD Software Storage Migration Architecture Virtual Machine Source Device Destination Device VHD VHD
Hyper-V VHD Software Storage Migration Architecture Virtual Machine Source Device Destination Device VHD
Demo Storage Migration
PowerShell Move-VMStorage "File Server 3" ` -DestinationStoragePath ` "K:\Virtual Machines\File Server 3"
Storage Migration – Performance Data is moved with an un-buffered file copy operationXCOPY /JCauses a lot of I/O churn
Configuring Storage Migration
Agenda Importing virtual machines
Improvements to VM Import Basic building block of mobilityImprovements:Allow you to import a raw XML file Provide ability to “fix up” virtual machine during import
Demo Importing a VM
PowerShell PS C:\> Import-VM "C:\Users\benarm\Desktop\Import\76F5DA48-5181-4E75-83ED-FB2F65B56C8F.xml" -Copy -VhdSourcePath "C:\Users\benarm\Desktop\Import"Import-VM : Unable to import virtual machine due to configuration errors. Please use Compare-VM to repair the virtual machine. At line:1 char:1 + import- vm "C:\Users\benarm\Desktop\Import\76F5DA48-5181-4E75-83ED-FB2F65B56C8F.x ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified : (:) [Import-VM], VirtualizationOperationFailedException + FullyQualifiedErrorId : Microsoft.HyperV.PowerShell.Commands.ImportVMCommand
PowerShell PS C:\> $ VMCompatReport = Compare-vm "C:\Users\benarm\Desktop\Import\76F5DA48-5181-4E75-83ED-FB2F65B56C8F.xml" -Copy -VhdSourcePath "C:\Users\benarm\Desktop\Import" PS C:\> $ VMCompatReport VM : Microsoft.HyperV.PowerShell.VirtualMachine OperationType : ImportVirtualMachine Destination : BENARM-EPSILON Path : C:\Users\benarm\Desktop\Import\76F5DA48-5181-4E75-83ED-FB2F65B56C8F.xml SnapshotPath : VhdDestinationPath : C:\Users\Public\Documents\Hyper-V\Virtual Hard Disks VhdSourcePath : C:\Users\benarm\Desktop\Import Incompatibilities : {33012, 14420}
PowerShell PS C:\> $ VMCompatReport.Incompatibilities | ft message Message ------- Could not find Ethernet switch 'Public'. Cannot assign the specified number of processors for virtual machine 'A random virtual machine' is out of range. The range is 1 through 12. (Virtual machine ID 76F5DA48-5181-4E75-83ED-FB2F65B56C8F)
PowerShell PS C:\> Set- VMProcessor -VM $VMCompatReport.VM -count 2PS C:\> get-vmnetworkadapter -VM $VMCompatReport.VM | disconnect- vmnetworkadapter PS C:\> import- vm $ VMCompatReport Name State CPUUsage (%) MemoryAssigned (M) ---- ----- ----------- ----------------- A random virtual machine Off 0 0
Agenda Comparing Technologies
Zero Downtime Protects against hardware failure Protects against site failureProtects against data corruptionAutomatic response to failure Workgroup compatible Live Migration J L L L L L Storage Migration J L L L L J Import / Export L L L L L J Clustering K J K L J L Hyper-V Replica L J J K L J Backup L J K J L J
Agenda Q & A
SIA, WSV, and VIR Track Resources DOWNLOAD Windows Server 2012 Release Candidate microsoft.com/ windowsserver #TEVIR304 DOWNLOAD Microsoft System Center 2012 Evaluation microsoft.com/ systemcenter Hands-On Labs Talk to our Experts at the TLC
Resources Connect. Share. Discuss. http ://europe.msteched.com Learning Microsoft Certification & Training Resources www.microsoft.com/learning TechNet Resources for IT Professionals http://microsoft.com/technet Resources for Developers http://microsoft.com/msdn
Evaluations http://europe.msteched.com/sessions Submit your evals online
© 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.