Hyper-V in Windows Server 2008 R2
Download
Report
Transcript Hyper-V in Windows Server 2008 R2
Implementing and Managing Microsoft®
Hyper-V 2.0
Nicola Ferrini
[email protected]
Level 300 - Advanced
Who Am I ?
• Trainer
• Technical Writer
• Systems Engineer
• Server & Application Virtualization Technology Specialist
• Technet Speaker
• Microsoft System Center Influencer
• More on:
http://www.nicolaferrini.it/curriculum.shtml
http://www.windowserver.it/ChiSiamo/Staff/tabid/71/Default.aspx
Agenda
• Evaluating and Planning for Virtualization
• Configuring the Hyper-V Server Role
• Creating and Configuring Virtual Hard Disks and Virtual Machines
• Implementing High Availability for Server Virtualization
• Integrating VMM with Hyper-V
• Creating and Deploying Virtual Machines Using VMM 2008 R2
• Managing Virtual Machines Using Virtual Machine Manager 2008
• Configuring and Managing the VMM Library
• Configuring User Roles and the VMM Self-Service Portal
Virtualization Modes
Profile Virtualization
Document redirection
Offline files
Presentation
Virtualization
Management
Desktop
Virtualization
Application
Virtualization
What Is Server Virtualization?
Server virtualization enables multiple virtual machines to run on one
physical host
Benefits:
• Server consolidation
• Service or application isolation
• Simplified server deployment and management
Increased service and application availability
• Multiple operating systems can run on one consistent
platform
What Is Hyper-V?
OS
Provided by
ISV/IHV/OEM
Parent Partition
Microsoft Hyper-V
Microsoft / Citrix
Child Partitions
VM
Worker
Processes
Applications
Applications
Applications
Applications
Windows Server
2003, 2008
Non-Hypervisor
Aware OS
Supported
Linux
Distributions
WMI Provider
User
Mode
VM Services
Windows Server
2008
Windows
Kernel
VS
P
IHV
Drivers
VMBus
Windows
Kernel
Kernel
Mode
VSC
Emulation
VMBus
Windows hypervisor
“Designed for Windows” Server Hardware
Linux
VSC
VMBus
Ring -1
Features of Hyper-V in Windows Server 2008 R2
Improved VHD
Live Migration
performance
Enhanced
networking
support
Dynamic virtual
machine storage
Hyper-V in
Windows Server
2008 R2
Cluster shared
volumes
Enhanced
processor
support
Requirements and Limits for Virtual Machines and
Hyper-V
Host computer components
Virtual machine components
Component
Description
Component
Description
Logical processors
64
Virtual processors
4
Virtual processors per
logical processor
8
Memory
64 GB
Virtual IDE disks
4
Virtual machines per
server
384 running
virtual
machines
Virtual SCSI disks
256
Memory
1 TB
Virtual hard disk
capacity
2040 GB
Storage
No limits
imposed by
Hyper-V
Snapshots
50
No limits
imposed by
Hyper-V
Virtual network
adapters
12
Physical network
adapters
Demonstration: How to manage Hyper-V
In this demonstration, you will see how to manage and
configure Hyper-V using Hyper-V Manager
Using and Configuring iSCSI Storage
iSCSI Initiator
iSCSI storage:
• Uses the existing IP network
• Is configured using the iSCSI
initiator
• Should use a dedicated NIC
• Required for virtual machine failover
clustering
Settings for Virtual Machines
Virtual Machine Settings
Exporting and Importing Virtual Machines in Hyper-V
Originating Computer
Exported Virtual Machine
Destination Computer
Imported Virtual Machine
What Are Hyper-V Virtual Machine Snapshots?
Snapshots:
Snapshot files:
• Are a point-in-time copy
of a virtual machine
• Virtual machine configuration
.XML file
• Do not affect the
running state of a virtual
machine
• Save state files
• Differencing disk (.AVHD)
Demonstration: Using Snapshots in Hyper-V R2
In this demonstration, you will learn how to:
• Take and manage a virtual machine snapshot
• Create a snapshot
• Revert to a previous snapshot
• Merge snapshots
Planning Hyper-V Hosts
When planning Hyper-V hosts:
• Simplify and standardize the host platform
• Consider using the Server Core installation option
• Automate and standardize administration of the virtual server
environment by:
• Standardizing the host and virtual server configuration
• Implementing remote management solutions at the host
server level
• Implementing VMM
Guidelines for Designing Virtual Machines
Guidelines:
• Simplify and standardize the host platform
• Plan virtual machines for specific server roles by:
• Monitoring the servers before virtualization
• Configuring each virtual machine with a hardware
configuration that is similar to the hardware required on
a physical server
• Deploy Windows Server 2008 or Windows Server 2008 R2–
based virtual machines whenever possible
• Consider other options for ensuring physical server utilization
Designing Virtual Machines for SQL Server
Guidelines:
• Ensure that the Hyper-V integration components are installed
• Plan virtual machine hardware settings to match physical
server hardware
• Use fixed-size disks and SCSI controllers for database and log
file drives
• To ensure adequate CPU capacity:
• Remember virtual machines are limited to four
processors
• Do not over-commit CPU resources
• Remember networking-intensive workloads require more
CPU capacity
Designing Virtual Machines for Exchange Server
When designing virtual machines for Exchange Server:
• Use standard server sizing rules
• Configure appropriate storage
• Do not use virtual machine snapshots
• Configure adequate CPU resources
• Consider how to use Hyper-V and native Exchange Server high
availability
• Consider I/O requirements
Designing Virtual Machines for SharePoint
When designing virtual machines for SharePoint:
• Configure virtual machine hardware like physical server hardware
• Do not take snapshots of virtual servers
• Avoid over-committing the virtual CPUs
• Consider deploying all of the servers in a server farm on a single
physical server
• Assign adequate memory
• Use only Internet Protocol Version 4 (IPv4)
• Choose the right storage implementation for the SharePoint
server role
What Is a Failover Cluster?
Failover Cluster Functionality in Windows Server
2008 R2
• Clustered Shared Volumes
• Live migration
• Processor compatibility mode
• Windows PowerShell cmdlets for failover clusters
• Additional tests in cluster validation
Configuration Options for a Failover Cluster Quorum
Quorum Modec
Description
Node Majority
• Only nodes in the cluster have a vote
• Quorum is maintained when more than
half of the nodes are online
Node and Disk
Majority
• The nodes in the cluster and a disk
Node and File
Share Majority
• The nodes in the cluster and a file share
No Majority: Disk
Only
• Only the quorum-shared disk has a vote
• Quorum is maintained when the shared
witness have a vote
• Quorum is maintained when more than
half of the votes are online
witness have a vote
• Quorum is maintained when more than
half of the votes are online
disk is online
How Does a Failover Cluster Work with Hyper-V
Nodes?
Shared Bus or
iSCSI Connection
A dedicated network
connects the
failover cluster nodes
Planning a Failover Clustering Strategy for Hyper-V
1 Identify the applications that require high availability
Identify the application components that must be highly
2 available
3 Identify the application characteristics
4 Identify the total capacity requirements
5 Create the Hyper-V design
Best Practices for Failover Clusters Running Hyper-V
• Use Windows Server 2008 R2 as the Hyper-V host
• Plan for failover scenarios
• Plan the network design for failover clustering
• Plan the shared storage for failover clustering
• Use the recommended failover cluster quorum mode
• Deploy standardized Hyper-V hosts
• Develop standard management practices
Implementing Hyper-V and Failover Clustering
Install and configure Windows Server 2008 or Windows
1 Server 2008 R2
2 Configure shared storage
3 Install the Hyper-V and Failover Clustering features
4 Validate the cluster configuration
5 Create the cluster
6 Create a virtual machine on one of the cluster nodes
7 Make the virtual machine highly available
Demonstration: Implementing Failover Clustering
for Hyper-V
• In this demonstration, you will see how to implement
failover clustering for Hyper-V
Configuring Clustered Shared Volumes
CSV benefits:
• Fewer LUNs required
• Better use of disk space
• Virtual machine files are in a single logical location
• No special hardware required
• Increased resiliency
To implement CSV:
1 Create and format volumes on shared storage
2 Add the disks to failover cluster storage
3 Add the storage to the CSV
What Is Live Migration?
Considerations for Implementing Live Migration
• Verify basic requirements
• Configure a dedicated network adapter for the private virtual
network
• Use similar host hardware
• Verify network configuration
• Manage Live Migrations
Demonstration: Implementing Live Migration
• In this demonstration, you will see how to implement Live
Migration
What Is VMM 2008 R2?
VMM 2008 R2 provides centralized administration and management
of your virtual environment
VMM is used to:
• Manage Hyper-V hosts
• Manage virtual server hosts
• Manage VMware hosts
• Manage and deploy virtual machines
• Perform physical-to-virtual (P2V) and virtual-to-virtual (V2V)
conversions
Infrastructure Components of VMM 2008 R2
VMM Server
VMM Database
VMM Library
VMM Administrator
Console
Hosts
Host groups
VMM Self-Service
Portal
What’s New in VMM 2008 R2?
What’s new:
• Windows Server 2008 R2 Hyper-V Host Management
• Enhanced Support for SAN Transfers
• Enhanced Support for Shared Storage
• Quick Storage Migration
• Maintenance Mode for Hosts
• Support for VMware Port Groups for Virtual Switches
• Support for Virtual Machine Permissions Assigned in Hyper-V
Demonstration: Managing SCVMM 2008 R2
• In this demonstration, you will learn how to manage
SCVMM 2008 R2
What Is Windows PowerShell?
Windows PowerShell is:
• A scripting and command-line technology
• Directly accessible through a command shell,
msh.exe
• Used by GUI tools
Windows PowerShell features include:
• Cmdlets
• Scripting support
• Aliases
• Access to cmd.exe
commands
• Variables
• Pipelining
• Signed scripts
Using Windows PowerShell to Manage VMM
The VMM command shell includes the standard PowerShell cmdlets,
as well as a set of cmdlets specifically for VMM, such as:
• Get-VMCheckPoint
• Get-VMCheckpoint -MostRecent –vm "VM01" | RestoreVMCheckpoint
• Get-Help Get-VMMServer
Types of Hosts That VMM 2008 R2 Supports
• Windows Server based host in trusted domain
• Windows Server based host in non-trusted domain
• Windows Server based host in perimeter
• ESX based host
Supported Virtualization platforms:
• Virtual Server 2005 R2
• Hyper-V
• VMware ESX Server 3.0 or above
• VMware ESX Server 3.5i
• VMware VirtualCenter (VC) 2.5 (VMware Infrastructure 3
[VI3])
• VMware vSphere 4 (VI3 features only)
Demonstration: Adding Hosts to SCVMM
• In this demonstration, you will learn how to add hosts to
SCVMM 2008 R2
Supported Guest Operating System Platforms for
Virtual Machines
Server operating systems that the child partition supports:
Windows 2000 Server SP4
Windows Server 2003 SP2 (x86 Edition or x64 Edition)
Windows Server 2003 R2 SP2 (x86 Edition or x64 Edition)
Windows Server 2008 (x86 Edition or x64 Edition)
Windows Server 2008 R2
SUSE Linux Enterprise Server 10 with SP2 (x86 Edition or x64 Edition)
SUSE Linux Enterprise Server 10 with SP1 (x86 Edition or x64 Edition)
SUSE Linux Enterprise Server 10 with SP2 (x86 Edition or x64 Edition)
SUSE Linux Enterprise Server 11 (x86 Edition or x64 Edition)
Red Hat Enterprise Linux (RHEL) 5.2 and 5.3 (x86 Edition or x64 Edition)
(Emulated devices only)
Client operating systems supported in child partition:
Windows XP SP3 (x86 Edition or x64 Edition)
Windows Vista SP1 (x86 Edition or x64 Edition)
Windows 7 (x86 Edition or x64 Edition)
Integration Services improves integration between the physical
computer and the virtual machine
Sources for Deploying New Virtual Machines
What Is Host Rating?
Represents suitability of the physical machine to the host virtual
machine
Host rating:
•Depends on:
• CPU usage
• Memory usage
• Disk I/O
• Network usage
•Is a recommendation, not a mandatory condition
•Calculation metric can be changed
What Is Virtual Machine Placement?
Evaluation and selection of the most suitable host for the virtual
machine
Types:
• Automatic placement
• Intelligent placement
Considerations:
• Default path must be configured
• Host compatibility must be checked
Demonstration: Creating and Placing a New
Virtual Machine Using VMM 2008 R2
• In this demonstration, you will learn how to use VMM to
create a new virtual machine, place it on the host, and
store it in a library
Demonstration: Deploying a New Virtual Machine
from the VMM Library
• In this demonstration, you will learn how to deploy a
virtual machine from the VMM library
What Is P2V Conversion?
Converts an operating system that is running on physical hardware
to an operating system running inside a virtual machine
Considerations:
• VHDs are made from disk images from source computer
• New virtual machine has the same computer identity as the
physical computer
Requirements for the Source and Destination
Computers in the P2V Process
Requirements for the source
computer:
Requirements for the
destination computer:
• RAM size
• Virtualization platform
• Volume size
• RAM size
• ACPI BIOS
• Cannot be in perimeter
• Cannot be in perimeter
Considerations for the operating system:
• NT 4.0 is not supported
• Itanium versions are not supported
• Windows Server 2003 Sp1 is not supported
Online and Offline P2V Conversions
Online conversion uses VSS to convert the physical server to a
virtual machine while the operating system and applications are
running on the physical server
Offline conversion uses Windows PE to convert the physical server to
a virtual machine while the operating system and applications are
not running on the source server
Usage Scenarios for P2V Conversion
Scenarios:
• Consolidating servers
• Decommissioning of old hardware
• Simplifying support for old operating systems
Prioritizing Virtualization Candidates:
1. Underutilized computers that are not business critical
2. Computers with low utilization
3. Computers with higher utilization
4. The remaining underutilized computers
What Is V2V conversion?
Converts existing VMware virtual machines to virtual machines
running on Hyper-V
Converting VMware-based virtual machines:
• From ESX host, Library or File Share
• Original VM is unaffected
• .vmdk files are used as source to build .vhd
V2V Conversion Requirements
Requirements:
• Operating system in virtual machine
• Virtual machine files
• .vmx
• .vmdk
Requirements for the destination host server:
• Windows Server 2008 64-bit with Hyper-V
• Cannot be in perimeter network
• At least 256MB RAM and memory for virtual machine
Methods and Considerations for the V2V process
Methods:
• Conversion directly from an ESX Server host
• Conversion from the VMM library
• Conversion from a Windows or NFS share
Demonstration: Performing a V2V Conversion
• In this demonstration, you will learn how to convert a
VMware virtual machine, from the VMM library, by using a
V2V conversion
Migrating Virtual Machines Between Hosts
When migrating, be aware that:
• Migration is supported only between compatible
platforms
• During migration, virtual machine files are moved to
the new host
• The virtual machine remains online during migration
• You can move virtual machines by LAN or SAN transfer only
• You can use Quick Storage Migration to move
the virtual machine storage between storage
systems while the virtual machine is running
Methods for Performing Virtual Machine Migration
Between Hosts
• Use the Migrate action
• Use the Migrate Storage action
• Drag and drop the virtual machine onto a host
• Drag and drop the virtual machine onto a host group
Considerations for Virtual Machine Migration
Considerations:
• SAN storage issues
• Permission issues
• Migration of virtual machines with checkpoints
• Status of the ESX Server host
Demonstration: Performing Virtual Machine
Migration Using Quick Storage Migration (QSM)
• In this demonstration, you will learn how to migrate a
virtual machine between storage locations
What Is Virtual Machine Cloning?
Creates new virtual machines based on existing machines, and
creates backups of existing virtual machines
Considerations:
• You must stop virtual machines before cloning them
• During cloning, the operating system is not generalized
Considerations for Virtual Machine Cloning
Considerations:
• You cannot make changes to a cloned operating system
• You can clone a virtual machine from the library
• VMM assigns a different machine name to a cloned
virtual machine if you deploy it on the same host as
the original
Actions for Operating and Managing Virtual Machines
Action
Description
Start
• Starts a virtual machine that is
Stop
• Stops a virtual machine, and does
Pause
• Suspends execution of a virtual
Save state
• Suspends execution of a virtual
Discard
Saved state
• Discards the state that was saved
Shut down
• Shuts down the guest operating
Connect to
virtual
machine
• Connects to a virtual machine by
stopped, paused, or in a saved state
not save any state information
machine, and keeps all virtual
machine state in memory
machine, and saves the current
virtual machine state to disk to
release memory and CPU resources
for other virtual machines
for a virtual machine that is in a
saved state, and turns off the virtual
machine
system on the virtual machine
using Remote Desktop Protocol
(RDP)
Deploying, Migrating, and Storing Virtual Machines
Action
Description
New virtual
machine
• Starts a wizard for creating new
Clone
• Clone existing virtual machine
Deploy
• Removes virtual machine from VMM
Migrate
• Migrate virtual machine between
Migrate
Storage
• Migrate storage location of virtual
Store in
Library
• Stores virtual machine in VMM
Delete
• Delete virtual machine from VMM
virtual machine
Library and place it on a host
hosts
machine
Library for later deployment
Admin Console and delete all virtual
machine files
Managing Virtual Machine Configurations and Disks
Management options:
• Repair
• Disable undo disks
• Install virtual guest services
• View networking
• Disable
• Convert to fixed type of virtual hard disk
• Compact virtual hard disk
• Expand virtual hard disk
• Use and existing virtual hard disk
• Create a new virtual hard disk
• Pass-through to physical drive on host
Virtual Hard Disk Configuration
What Is Virtual Machine Checkpoint?
By creating checkpoints for a virtual machine, you can
restore the virtual machine to a previous state
Checkpoints:
•
•
•
•
Are created in the VMM Administration Console
Can be created while the virtual machine is running
Are portable
Are the same as Hyper-V snapshots
Virtual Machine Management
Considerations for Using VMM Checkpoints
Before restoring to a checkpoint state, you should perform a
backup
Checkpoints:
• Affect virtual machine performance
• Are not a replacement for backup
• Are stored with the virtual machine on a host
Demonstration: Creating and Managing Checkpoints
In this demonstration, your instructor will show you how to
create and manage virtual machine checkpoint
What Is the VMM Library?
VMM Library is:
• A catalog of resources that you can use to create and configure
virtual machines in VMM
VMM Library:
• Is hosted on a VMM Library Server
• Can have one or more library shares
• Content in a library share can be organized by creating
subfolders
• Content is refreshed (indexed) once per hour by default
VMM Library Resources
File-based resources:
•
•
•
•
Virtual hard disks
Virtual floppy disks
ISO files
Windows PowerShell (ps1)
scripts
• Answer files (inf, xml)
• Virtual machine templates
• Hardware profiles
• Guest operating system
profiles
• Virtual machines that are not
in use
• VMware virtual machines
What Are the Library Server and Library Group?
A library server is:
• A central repository of resources that you can use to create
virtual machines
A library server:
• Is configured as a default library
server
• Used to add additional library servers
• Used to align library servers to host
groups by using library groups
What Is a Hardware Profile?
A hardware profile is:
• A library resource containing hardware specifications that can
be applied to a new virtual machine or a virtual machine
template
Hardware profiles:
• Ensure consistent hardware configurations
• Can manage hardware profiles are managed in library view
• Can create a profile from scratch, from a template, or a
hardware configuration of a virtual machine
Hardware Profiles Settings
BIOS Startup order:
• Processor
• Memory
• Floppy drive
• COM1 and COM2
• IDE devices
• Network adapter
• Priority
• Availability
What Is the Guest Operating System Profile?
A guest operating system profile is:
• A collection of operating system settings that can be imported
into a virtual machine template
Guest operating system profiles:
•
•
•
•
Are database objects
Are used in process of creation of new virtual machine
Can be changed later
Are not associated to virtual machines created based on it
Guest Operating System Profile Settings
• Identity information
- Computer name
• Admin Password
• Product Key
• Time zone
• Operating system
• Domain/Workgroup
• Answer file
• [GUIRunOnce]
Commands
Demonstration: Creating Hardware and Guest
Operating System Profiles
In this demonstration, your instructor will show you how to
create hardware profile and guest operating system profiles
What Is the Virtual Machine Template?
Virtual machine templates are:
• A standardized group of hardware and software settings
that you can use for new virtual machines
Two types of virtual machine templates:
• Customized templates
• Non-customized templates
Virtual machine template components:
• Hardware profile
• Virtual hard disk
• Guest operating system profile (optional)
Virtual Machine Template Settings
Settings:
• General settings
• Hardware Configuration
• Operating system
Configuration
• Custom Properties
• Quota Points
Demonstration: Creating and Modifying the
Virtual Machine Template
In this demonstration, your instructor will show you how to
create and modify the virtual machine template
Role Types
Administrators:
• Full access to all actions
• Full access to all objects
• Can use the Admin console or PowerShell interface
Delegated Administrators:
• Full access to most actions
• Scope can be limited by host groups and Library servers
• Can use the Admin console or PowerShell interface
Self-Service users
• Limited access to a subset of actions
• Scope can be limited by host groups and Library share
• Can use the Self-Service Portal or PowerShell interface
Creating a User Role in VMM 2008 R2
Select the user
role profile
Wizard
configuration
options
Demonstration: Creating A User Role
• In this demonstration, you will see how to:
Add new members to the administrator profile
Create a delegated administrator profile, and delegate
specific host groups and libraries to that profile
Implementing VMM Self-Service Portal
To implement the VMM Self-Service Portal:
1. Install the VMM Self-Service Portal
2. Create or configure host groups
3. Add default virtual machine paths
4. Create a self-service user role
5. Assign self-service user accounts or groups as virtual
machine owners
6. Create virtual machine templates (optional)
Requirements for the VMM Self-Service Portal
Hardware requirements
Recommendations
Up to 10 concurrent
connections
Enables monitoring and managing the
hardware and software in a distributed
environment
Enables automated installation and
configuration of software and operating
system updates
More than 10 concurrent
connections
Operating system
Requirements
Windows Server 2003 and
Windows Server 2003 R2
• Web Server
• Windows Powershell
• .NET Framework 2.0
Windows Server 2008 and
Windows Server 2008 R2
• Web Server server role with selected
role services
• Windows Powershell
Demonstration: Configuring User Access to the
Self-Service Portal
• In this demonstration, you will see how to use the VMM
Self-Service Portal
Thank you!