Microsoft Press mcts training kit 70 - 648 server virtualization phần 6 pptx

65 295 0
Microsoft Press mcts training kit 70 - 648 server virtualization phần 6 pptx

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

Lesson 1: Exploring System Center Virtual Machine Manager CHAPTER 5 303 3. The SCVMM Administrator Console uses port 8100 to communicate with SCVMM Server. 4. SCVMM reserves 10 percent of CPU, 512 MB of RAM, 100 MB of disk space, 10,000 I/O operations per second, and 10 percent of network bandwidth for Hyper-V Hosts. 5. The SCVMM Library installation creates two blank VHDs: Blank Disk Small (16 GB) and Blank Disk Large (60 GB). 304 CHAPTER 5 Automating Virtual Machine Creation Lesson 2: Automating Virtual Machine Creation Now that you understand how to use SCVMM, you can move on to discover the SCVMM features related to virtual machine creation and management. You’ve already seen that virtual machine creation with Hyper-V Manager is mostly an interactive process. Now you’ll learn how to rely on existing virtual machines to generate new VMs. You’ll also learn how to rely on templates to generate new VMs. Templates greatly reduce the time it takes to generate a VM because they build VMs from files that already contain guest operating systems and even applications if the applications lend themselves to the duplication process. After this lesson, you will understand: n How to duplicate a virtual machine by copying virtual hard disks. n How to clone a virtual machine. n How to depersonalize the VM clone image by using the System Preparation Tool. n How to install a guest operating system in a VM by using the PXE boot process. n How to create and manage templates. n How to deploy a virtual machine from the SCVMM library. n How to allow end users to generate their own VMs through the SCVMM Self-Service portal. Estimated lesson time: 40 minutes Manually Creating a Duplicate Virtual Machine When you manage multiple virtual machines, you quickly learn that generating a new VM from scratch can take considerable time—not nearly as much time as generating a new physical machine, but time nevertheless. Yet, when you consider that a VM is mostly composed of virtual hard disks and all you need to do to generate a new VM is copy the virtual hard disks to another folder, you begin to see the impact server virtualization has on standard datacenter operations. Even better, if you can automate the process or make it available through self-service, you turn your datacenter into a dynamic environment that can quickly respond to changing business needs. Generating a new VM from an existing VM can be a simple process, but like physical machines, virtual machines must be depersonalized before you can use a duplicate of the system image to create a new machine. In the physical world, duplicating a machine uses the following process: 1. You create a reference computer. The reference computer is a computer that includes an operating system and possibly an application such as a Web server or a database engine. In addition, the reference computer has been personalized and configured to the organization’s standards. This includes any utilities or security components such as antivirus and antimalware engines. Lesson 2: Automating Virtual Machine Creation CHAPTER 5 305 2. You depersonalize the reference computer. This involves using the Microsoft System Preparation Tool to remove items such as computer name, security identifier (SID), administrative account, and more. This generalizes the installation so that it can be reused without any conflicts within the same environment. Depersonalization renders the machine unusable until it has been repersonalized. 3. You capture a disk or file image copy of the disks that make up the reference computer. This capture can be performed through the ImageX tool that is included in the Windows Automated Installation Kit. ImageX captures a file-based image of the disk and stores it in a WIM format. In many cases, you only need to capture the operating system disk. You store the image on a file share that is accessible by the other computers on which you want to install the new image. 4. You deploy the image to new or existing computers. If the target computer does not include an operating system, you use either components from the Windows AIK or the Windows Deployment Services to send the image to the new systems. If you use WDS, you need to boot the system from the network interface through the PXE process (the F12 key), connect to a WDS server, and download the image. Both processes—interactive image copying with WAIK tools and remote image copying through WDS—rely on Windows PE to boot to a temporary operating system, copy the image, and then reboot into the newly installed operating system. 5. After the system is booted into the newly installed operating system, the operating system is repersonalized, generating a new SID, reassigning the administrative account, naming the computer, and possibly joining a Windows domain. This process can either be interactive or automated through unattended response files. At this point the computer is ready to take on a new role within your infrastructure. The advantage of this process is that you do not need to run through a standard installation and configuration each time you deploy a new computer. However, it has some disadvantages: n When you work with physical computers, you must destroy the reference computer to generate a depersonalized version of the newly configured operating system. n When it is time to update the reference system—which occurs each time new updates are available for operating system and other components on the configured system— you must re-create the reference computer by re-copying the image to the system, personalizing it, updating the system, depersonalizing the system once again, and then regenerating the source image. When you work with virtual machines, you’ll find that working with reference systems is much easier than in the physical world. For one thing, you never need to regenerate the reference system. Instead of depersonalizing the reference computer, you generate a clone of the reference computer and depersonalize the clone. This way, you can always rely on the original reference computer to install updates and regenerate a depersonalized image. Of course, you must shut down the reference computer when you depersonalize the cloned version to ensure that the two systems do not conflict with each other. 306 CHAPTER 5 Automating Virtual Machine Creation Another major advantage of virtual machines is that you do not need to generate an image of the disk drives that make up the machine because the disk drives are already in file format (using the VD format). This also saves considerable time. Therefore, the same duplication process is simplified when applied to virtual machines (see Figure 5-23): 1. You create a reference VM. You set it up the same way you would create a reference physical system. Shut down the VM. 2. You copy the VHDs that make up the reference computer. This can be as simple as copying the VHDs from one folder to another. The process will be much faster if the VHDs are dynamically expanding VHDs because they will only include the actual used space in the VHD. 3. In Hyper-V Manager, you create a new VM based on the existing VHD copies. 4. You boot the new VM to depersonalize it, making sure the reference computer is still off. Once again, you use the System Preparation Tool to do this. 5. To deploy a new VM, you duplicate the VHDs that make up the depersonalized computer. 6. In Hyper-V Manager, you create a new VM based on the existing VHD copies and boot it up. 7. When the system is booted, you proceed with the repersonalization. At this point the computer is ready to take on a new role within your infrastructure. SysPrep Copy Copy Monthly Updates Keep the Reference VMs on standby until updates are needed. Inspect and compress VHDs. Reapply SysPrep as needed. (Each time updates are applied to the Reference VMs) Copy and re-personalize to provision a new system. Provision as Needed Windows Server 2008 Standard edition Windows Server 2008 Enterprise edition 2 3 1 4 Reference VMs Windows Server 2008 Standard edition Windows Server 2008 Enterprise edition FIGURE 5-23 Managing reference and source VMs The major advantage of this process is that it only takes a few minutes and your reference computer remains intact throughout the process. When updates are available, all you need to do is launch the reference computer, update it, repeat step 2—copying the updated VHDs to the depersonalized machine’s folder—and then repeat step 4 to depersonalize it again. Lesson 2: Automating Virtual Machine Creation CHAPTER 5 307 More Info OFFLINE VHD SERVICING Microsoft also offers an offline virtual machine servicing tool that lets you install updates on virtual machines that are turned off while stored in the SCVMM Library. Find it at http://www.microsoft.com/downloads/details.aspx?FamilyID=8408ecf5-7afe-47ec- a697- eb433027df73&DisplayLang=en. exaM tIp DUPLICATION VS. EXPORT When you generate a VM to use as a source or seed machine, do not use the Hyper-V Export tool. This tool does not generate a copy of the VM. Instead, it exports the actual virtual machine and the exported virtual machine is no longer usable until it has been imported. Note, however, that the exported machine is still available on the original host. Cloning a Virtual Machine When you perform the VM duplication process in Hyper-V alone, you need to use manual processes to make the copies of the VMs. However, when you use SCVMM, you can use a special process called VM cloning to prepare the machine duplicate. Cloning is much faster than manually duplicating the VHDs because it copies the entire VM including configuration and any other files that may be part of the VM. Cloning is useful when you need to generate a copy of a reference computer or when you simply want to generate a backup of a virtual machine. You can only clone a VM when it is stopped. The VM can either be on a host or in the SCVMM Library. To clone a VM, you use the Virtual Machines view and then the Clone command. This command is listed at the bottom of the Actions pane and is only available when the VM is stopped. This command launches the New Virtual Machine Wizard, which takes you through the steps required to modify the parameters of the new VM (see Figure 5-24). Note that when you clone a new VM, the following occurs: n The guest operating system within the new VM is identical to the source VM. This is fine for seed machines because you will later depersonalize the VM. n The hardware settings for the VM can be modified during the cloning process. n You can also move the VM to a new host during the cloning process. Be wary of cloning VMs. Several other tools are available for generating new VMs in SCVMM and they may be more appropriate if your purpose is not to generate a new seed machine. 308 CHAPTER 5 Automating Virtual Machine Creation FIGURE 5-24 Cloning a VM with the New Virtual Machine Wizard Using Sysprep to Prepare a Virtual Machine for Duplication After the VM has been cloned, you can use the System Preparation Tool within the cloned VM to turn it into a seed VM by following these steps: 1. Boot the cloned VM and log on with local administrative credentials. 2. Open Windows Explorer and go to %SYSTEMROOT%\SYSTEM32\SYSPREP. 3. Launch SYSPREP.exe. 4. In the Sysprep dialog box, select the following options (see Figure 5-25): n System Cleanup Action: Enter System Out-of-Box Experience (OOBE) n Select the Generalize option n Shutdown Options: Shutdown 5. Click OK. Sysprep will depersonalize the system and shut it down. Your cloned VM system is ready for duplication. You can use the cloning process once again to generate a new working VM from this seed machine. Lesson 2: Automating Virtual Machine Creation CHAPTER 5 309 FIGURE 5-25 Using the System Preparation Tool You can also run the System Preparation Tool through the command line with the following command: C:\Windows\System32\Sysprep.exe /oobe /generalize /shutdown Creating and Managing VM Templates Although you can clone a VM and then depersonalize the VM using the System Preparation Tool, you can also perform this task automatically through the Administrator Console in SCVMM by generating a VM template. When you generate a template VM, SCVMM automatically transforms the VM into a depersonalized virtual machine to be used as a seed machine for the generation of new VMs. The template generation process automatically applies the System Preparation Tool to a VM that already includes a Windows operating system. The template will also be stored in the Library to support the generation of new VMs from a central source. In fact, several activities are performed when you generate a template (see Figure 5-26). FIGURE 5-26 The tasks performed during the creation of a template 310 CHAPTER 5 Automating Virtual Machine Creation You should create as many templates as you need. For example, if your datacenter runs two versions of Windows Server, the Standard and the Enterprise editions, you should have a VM template for each. This way, you can quickly provision new VMs whenever you need them. IMportant USING SCVMM ON SANS Storage area networks usually include special tools that support high-speed duplication of information from one location to another within the SAN through the SAN Transfer feature. If you store the SCVMM Library on a SAN, SCVMM will be able to use these tools to perform high-speed VM duplications. This will greatly speed up the generation of VMs from templates and the cloning or duplication of VMs, which can be quite large in file size. exaM tIp CREATING TEMPLATES Remember that templates can only be created from VMs that are stopped. Creating and Managing VMs with SCVMM As you’ve seen, SCVMM offers several tools for VM management and administration that are not available in either Hyper-V Manager or the Failover Clustering Management console. In fact, any organization that must manage VMs on an ongoing basis should seriously consider running SCVMM as well as Hyper-V in their environment. Creating a New VM with SCVMM The process of creating a new VM in SCVMM—even (and especially) a new VM from scratch— is considerably different from the same process in Hyper-V Manager. It proceeds as follows: 1. Launch the SCVMM Administrator Console and select the Virtual Machines view. 2. In the Actions pane, select New Virtual Machine. The New Virtual Machine Wizard will launch, and several actions will be presented. 3. Follow the directions in the wizard. Table 5-5 outlines the major differences you will find when creating a new VM in SCVMM compared to Hyper-V. Figures 5-27 through 5-29 illustrate some of the available options. TABLE 5-5 The SCVMM New Virtual Machine Wizard WIZARD PAGE ACTION Select Source Two actions are available and offer different options. n Use An Existing Virtual Machine, Template, Or Virtual Hard Disk This lets you generate a new VM from an existing VM. Lesson 2: Automating Virtual Machine Creation CHAPTER 5 311 WIZARD PAGE ACTION n Create The New Virtual Machine With A Blank Virtual Hard Disk Select this option to create a new virtual machine from scratch. Note that you do not need to use a blank disk and can use an existing hard disk that already includes a guest operating system. Virtual Machine Identity This is where you name the VM and provide a description for it. Descriptions are very useful, especially when you run hundreds of VMs. Configure Hardware When you configure hardware, you can create a brand new profile for the VM or you can draw upon an existing hardware profile that was pre-created and stored in the Library. Hardware profiles are provided in a drop-down list. Select Destination Once again, this page gives you two options: n Place The Virtual Machine On A Host This copies the files associated with the VM to the target host. You can even start the VM immediately. n Store The Virtual Machine In The Library This stores the VM in the library for later use. You then need to deploy the VM from the Library to a host before you can start it. Select Host (Host Only) When you choose to place the VM on a host, SCVMM uses Intelligent Placement to locate an appropriate host from your pool of hosts. Hosts do not need to be in a failover cluster to belong to this pool. Intelligent Placement is based on special host ratings. You can customize these ratings on this page. To do so, select Customize Ratings. This presents a special dialog box that includes two tabs. Note that changes in this dialog box only change the ratings for this particular placement. To change the ratings for all placements, you must access this dialog box through the Administration View. Placement Options tab Configures how host ratings are calculated. n Placement Goal Load Balancing or Resource Maximization. n Resource Importance You can modify CPU usage, memory free, disk I/O, and network utilization on each host. VM Load tab n Lets you refine host ratings based on the anticipated resource utilization of this VM. When the VM is based on an existing VM, the displayed settings are based on past performance of the source VM. 312 CHAPTER 5 Automating Virtual Machine Creation WIZARD PAGE ACTION When you return to the Select Host page, you will see that SCVMM presents available hosts based on the Intelligent Placement settings. Hosts are rated with a five-star method. Hosts with the most resources are displayed first. You can choose which host offers the most resources to place your VM. Select Library Server (Library Placement Only) When you choose to place the VM in the Library, you will be given the option to store the VM in one of the Library shares. If you placed the Library on a SAN, you will be able to use SAN Transfer. If SAN Transfer is not available, this page will tell you why. Select Path When you place the VM on a host, you can select the path to the folder that will store the files that make up the VM. When you place the VM in the Library, you choose where to place the VM in the folder structure of the Library share. Select Networks (Host Placement Only) Lets you choose which network to attach to the VM’s adapter(s). Additional Properties (Host Placement Only) Configures which actions will be applied to the VM. Summary Lets you view and copy the Windows PowerShell script to be used to generate the new VM. FIGURE 5-27 Customizing placement ratings [...]... Windows Server 2008 without Hyper-V x64 Standard, Enterprise, and Datacenter editions Windows Server 2008 without Hyper-V x 86 Standard, Enterprise, and Datacenter editions Windows Server 2008 Web Server edition Windows Server 2003 x 86 with Service Pack 2 Standard, Enterprise, and Datacenter e ­ ditions Windows Server 2003 x64 with Service Pack 2 Standard, Enterprise, and Datacenter e ­ ditions Windows Server. .. Installing the SCVMM Self-Service Portal The SCVMM Self-Service Portal must be installed on a server operating system that includes Internet Information Services (IIS) This installation can be on a number of platforms Table 5 -6 outlines the available platforms for portal installation Table 5 -6   Supported Platforms for the SCVMM Self-Service Portal Platform Windows Server 2008 with Hyper-V x64 Standard, Enterprise,... tools such as Virtual Server or VMware Server need to implement new host servers running Hyper-V and then perform a virtual machine conversion to transform existing virtual machines into Hyper-V VMs n Organizations already using hardware-based server virtualization ­ Organizations using tools such as VMware ESX or Citrix XenServer need to convert their host ­ ervers s to Hyper-V and then convert their... first create Self-Service User roles Chapter Summary CHAPTER 5 327 C C H APTER 6 C Migrating to Hyper-V M N ow that your Hyper-V host server or resource pool infrastructure is ready, you can move on to populate it with production-oriented virtual machines This means t ­ ransforming your production machines into virtual machines running on Hyper-V C ­ hapter 1, “Implementing Microsoft Hyper-V,” introduced... controllers, Internet Information Services (IIS) Web servers, Exchange servers, Microsoft SQL Server machines, and more In Linux ­ nvironments, ­ e w ­ orkloads supporting migration include similar services In both Windows and Linux e ­ nvironments, you can also migrate clustered servers as well as servers running either NLB or other server load-balancing technologies Keep the ­ ollowing in mind when... Protocol address pools with new DNS server addresses when the conversion is complete SQL Server servers  To migrate databases running on Microsoft SQL Server, create new virtual machines running the appropriate version of SQL Server ideally version 2008—and then use the SQL Server data migration process to move the workload Begin with the analysis of your databases with the SQL Server Upgrade Advisor and follow... installation Click Next 4 Choose the x64 Hardware Profile from the drop-down list and click Next 5 Choose the WS08_Enterprise Guest OS Profile from the drop-down list and click Next You created this profile in Lesson 1 and can now apply it to new VMs generated from this template 6 Choose ServerCore01 as the Library Server and click Next This will store the template within this server s Library share 7 Click... (Find the Advisor at http://www .microsoft. com/downloads/details.aspx?FamilyId=­ 5A6C5E9F 4CD 9-4 E42-A21C-7291E7F0F852&displaylang=en.) Copy the databases—detaching and attaching the databases from one machine to the other—and perform any required manual modifications Convert the database to the new format if possible and decommission the source servers Even better, with SQL Server 2008, capture the entire... as virtual machines in other formats that can be transferred into Hyper-V format This will give you more hands-on practice for the exam objective in this chapter CHAPTER 6 329 Lesson 1: Working with Migration Scenarios When you migrate existing machines—physical or virtual—to host them on the Microsoft Windows Server 2008 Hyper-V role, you need to understand and perform the following tasks, which... running on Microsoft Virtual PC or Microsoft Virtual Server to Hyper-V n Migrations of machines that have been captured in disk image format using t ­ hird-party tools such as Acronis True Image Echo or Symantec Ghost n Migrations of machines that are running as virtual machines within a VMware e ­ nvironment n Migrations of machines that are running as virtual machines within a Citrix XenServer environment . installation. TABLE 5 -6 Supported Platforms for the SCVMM Self-Service Portal PLATFORM Windows Server 2008 with Hyper-V x64 Standard, Enterprise, and Datacenter editions Windows Server 2008 without Hyper-V x64. Datacenter editions Windows Server 2008 without Hyper-V x 86 Standard, Enterprise, and Datacenter editions Windows Server 2008 Web Server edition Windows Server 2003 x 86 with Service Pack 2 Standard,. off while stored in the SCVMM Library. Find it at http://www .microsoft. com/downloads/details.aspx?FamilyID=8408ecf 5-7 afe-47ec- a69 7- eb433027df73&DisplayLang=en. exaM tIp DUPLICATION VS.

Ngày đăng: 09/08/2014, 11:21

Từ khóa liên quan

Tài liệu cùng người dùng

Tài liệu liên quan