查看完整版本: [轉貼]VMware vCenter VMotion 详解

chun 2012-6-19 16:39

[轉貼]VMware vCenter VMotion 详解

<a href="http://www.storageonline.com.cn/virtualtech/vmware/vmware-vmotion-detailed/">http://www.storageonline.com.cn/virtualtech/vmware/vmware-vmotion-detailed/</a>
<div><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">1. 革命性的虚拟机移动性</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">VMware VMotion作为VMware VI3和vSphere产品系列的一个重要特性,常常让很多用户感到惊奇,具体的实现方式也一直是一个谜。实际上,VMotion已经成为服务器虚拟化的一个标竿,如果没有VMotion功能的虚拟化,根本没办法运行生产环境。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/vmotion/" title="查看 vMotion 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">vMotion</a></span>最大的特性是"整个迁移过程虚拟机应用不会中断”,也就是说在虚拟机不停机的情况下将一台虚拟机从一个esx服务器上迁移到另外一台服务器上,这样可以非常方便的在不影响业务的前提下对esx主机进行维护。VMware 客户中 70% 都在生产中部署了 VMware VMotion 技术,此技术利用服务器、存储和网络连接的完全虚拟化,可将正在运行的整个虚拟机从一台服务器即刻移到另一台服务器中。VMware VMotion 使用 VMware 的集群文件系统来控制对虚拟机存储器的访问。在使用 VMotion 进行实时迁移的过程中,虚拟机的活动内存和准确的执行状态通过高速网络快速从一台服务器传输到另一台服务器,对虚拟机磁盘存储器的访问被即刻切换到新的物理主机。由于网络也由 VMware&nbsp;<span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/esx/" title="查看 ESX 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">ESX</a></span>进行了虚拟化,因此虚拟机会保留其网络标识和连接,从而确保实现无缝的迁移过程。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image139.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb124.png" width="562" height="444" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">通过 VMware VMotion,您可以:</p><ul style="list-style: none; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; font-size: 13px; line-height: 24px; background-color: rgb(244, 245, 247); "><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">在零停机、用户毫无察觉的情况下执行实时迁移。</li><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">持续地自动优化资源池中的虚拟机。</li><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">在无需安排停机、不中断业务运营的情况下执行硬件维护。</li><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">主动将虚拟机从发生故障或性能不佳的服务器中移出。</li></ul><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">2. VMotion 的主机配置</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">要成功使用 VMotion,必须先正确配置主机,请确保已在以下每个区域中正确地配置了主机:</p><ol style="margin: 0px; padding: 0px; list-style: none; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; font-size: 13px; line-height: 24px; background-color: rgb(244, 245, 247); "><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">必须针对 VMotion 正确许可每台主机。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">每台主机必须满足 VMotion 的共享存储器需求。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">每台主机必须满足 VMotion 的网络要求。</li></ol><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">2.1 VMotion 共享存储器要求</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">在通过 VMotion 迁移期间,所迁移的虚拟机必须位于源主机和目标主机均可访问的存储器上。共享存储器通常位于存储区域网络 (SAN) 上,但也可以使用 iSCSI和 NFS 共享存储器得以实现。</p><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">2.2 VMotion 网络要求</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">VMotion 要求在所有启用 VMotion 的主机之间设置千兆以太网 (GigE)。每台启用 VMotion 的主机都必须至少有两个以太网适配器,其中必须至少有一个是千兆以太网适配器:</p><ol style="margin: 0px; padding: 0px; list-style: none; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; font-size: 13px; line-height: 24px; background-color: rgb(244, 245, 247); "><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">在每台主机上,为 VMotion 配置 VMkernel 端口组。并且考量到性能,最好为VMotion网络绑定专用网卡,具体参考《<a href="http://www.storageonline.com.cn/virtualtech/vmware/vmware-esx-server-network-settings/" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">VMware ESX Server网络设置</a>》,《<a href="http://www.storageonline.com.cn/virtualtech/vmware/vmware-vcenter-distributed-vswitch/" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">VMware vCenter vDS 分布式交换机&nbsp;</a>》与《<a href="http://www.storageonline.com.cn/virtualtech/vmware/wmware-esx-server-load-balancing-configuration/" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">WMware ESX Server网络负载均衡配置</a>》。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">确保虚拟机在源主机和目标主机上可以访问相同的子网。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">确保用于虚拟机端口组的网络标签在主机之间是一致的。在通过 VMotion 迁移期间,vCenter Server 根据匹配的网络标签将虚拟机分配到端口组。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">为获取最佳 VMotion 性能,建议使用巨帧。</li></ol><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">3. CPU 兼容性和迁移</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">vCenter Server 在允许迁移正在运行或已挂起的虚拟机时会执行一些兼容性检查以确保虚拟机与目标主机兼容。VMotion 在基础&nbsp;<span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/esx/" title="查看 ESX 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">ESX</a></span>/<span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/esxi/" title="查看 ESXi 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">ESXi</a></span>&nbsp;系统之间传输虚拟机的运行状况。成功的迁移要求目标主机的处理器能够使用源主机的处理器在虚拟机迁移出源主机时使用的等效指令来执行。处理器的时钟速度和缓存大小以及处理器内核的数量可以不同,但处理器必须属于相同的供应商类别(AMD 或 Intel),并且使用兼容的功能集,以达到通过<span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/vmotion/" title="查看 vMotion 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">vMotion</a></span>&nbsp;迁移所需的兼容性。已挂起的虚拟机的迁移还要求虚拟机能够使用等效指令在目标主机上恢复执行。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">开始通过 VMotion 迁移或开始已挂起虚拟机的迁移时,迁移虚拟机向导会检查目标主机的兼容性,如果有阻碍迁移的兼容性问题存在,向导会生成错误消息。&nbsp;<br>虚拟机启动时,会确定可用的 CPU 功能集。虚拟机的 CPU 功能集基于主机的 CPU 功能集。但是,如果主机是使用增强型 VMotion 兼容性 (<span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/evc/" title="查看 EVC 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">EVC</a></span>) 的群集的一部分,或者如果虚拟机已应用 CPU 兼容性掩码,则主机的一些CPU 功能对虚拟机而言不可见。有关详细信息,请在 VMware 知识库中搜索《VMotion 和 CPU 兼容性常见问题答》。</p><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">4. 关于增强型 VMotion 兼容性</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">可以使用增强型 VMotion 兼容性 (Enhanced VMotion Compatibility,&nbsp;<span class="wp_keywordlink_affiliate" style="margin: 0px; padding: 0px; font-weight: bold; "><a href="http://www.storageonline.com.cn/tag/evc/" title="查看 EVC 中的全部文章" target="_blank" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; ">EVC</a></span>) 功能帮助确保群集内主机的兼容性。EVC 可以确保群集内的所有主机向虚拟机提供相同的 CPU 功能集,即使这些主机上的实际 CPU也是如此。使用 EVC 可避免因 CPU 不兼容而导致通过 VMotion 迁移失败。在“群集设置”对话框中配置 EVC。配置 EVC 时,请将群集中的所有主机处理器配置为提供基准处理能集。EVC 利用 AMD-V Extended Migration 技术(适用于 AMD 主机)和 Intel FlexMigration 技术(Intel 主机)屏蔽处理器功能,以便主机可提供早期版本的处理器的功能集。基准功能集必须等同于群集最小功能集的主机的功能集,或为主机功能集的子集。</p><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">5. VMotion 的虚拟机配置要求</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">以下虚拟机配置可能会阻止通过 VMotion 迁移:</p><ul style="list-style: none; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; font-size: 13px; line-height: 24px; background-color: rgb(244, 245, 247); "><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">不能使用“通过 VMotion 迁移”来迁移因群集目的而使用裸磁盘的虚拟机。</li><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">如果虚拟机使用目标主机上无法访问的设备所支持的虚拟设备,则不能使用“通过 VMotion 迁移”功能来迁移该虚拟机。(例如,不能迁移带有源主机上物理 CD 驱动器支持的 CD 驱动器的虚拟机。)在迁移虚拟机之前,请断开这些设备。</li><li style="margin: 5px 30px; padding: 0px; list-style: disc; line-height: 22px; color: rgb(69, 69, 69); ">如果虚拟机使用客户端计算机上设备所支持的虚拟设备,则不能使用“通过 VMotion 迁移”功能来迁移该虚拟机。在迁移虚拟机之前,请断开这些设备。</li></ul><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">6. VMotion 步骤</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">简单来说,VMotion 迁移会在以下三个阶段发生:</p><ol style="margin: 0px; padding: 0px; list-style: none; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; font-size: 13px; line-height: 24px; background-color: rgb(244, 245, 247); "><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">当请求通过 VMotion 迁移时,vCenter Server 通过其当前主机验证现有虚拟机是否处于稳定状况。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">此时,虚拟机状况信息(内存、寄存器和网络连接)将复制到目标主机。</li><li style="margin: 5px 30px; padding: 0px; list-style: decimal; line-height: 22px; color: rgb(69, 69, 69); ">虚拟机将恢复其新主机上的活动。如果迁移期间出错,虚拟机将恢复其原始状态和位置。</li></ol><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">发生VMotion开始时,就相当于在目标机器上创建一个新的虚拟机。在新虚拟机创建过程中的前10%部分和创建其他的虚拟机没什么两样。接下去,我们开始为该虚拟机启动VMM(虚拟机监控程序,是每个虚拟机必备的底层),这实际上就是启动了一个新的虚拟机,并为它清空了一段内存地址。此时,该虚拟机并没有访问磁盘,也没有执行任何指令,它只是准备好了接受内存段,然后填充到它自己的内存页表里。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">从虚拟机创建到10%这个点,我们开始从源虚拟机将内存段复制到目标虚拟机,该动作需要的时间取决于网络速度、网络拥塞、虚拟机正在使用的内存大小和内存变化的速度(此时虚拟机仍然在正常运行中)。当完成到80%时,我们假定可以在1秒或更短时间内完成内存复制。接着我们就暂停源虚拟机,复制剩余的内存段,启动目标虚拟机,并且从目标虚拟机上执行反向ARP,让网络交换机知道新的MAC地址。当到达90%,复制最后可能变化的内存到目标虚拟机。接着源虚拟机被破坏(只是解散配置和VMM),从而成功完成该次VMotion。</p><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">7. VMotion前期准备</h3><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">7.1 建立VMkernel Port Group</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image140.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb125.png" width="644" height="458" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image141.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb126.png" width="576" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">7.2 确保源主机和目标主机的兼容性</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">虽然这个过程很简单,配置过程却是有些麻烦,特别是遇到一些让人匪夷所思的问题时,思考解决办法往往让人头疼不已。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">1. 检查CPU是否兼容:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image142.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb127.png" width="577" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image143.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb128.png" width="587" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">2. 确保符合VMotion 网络要求:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image144.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb129.png" width="644" height="470" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">3. 确保所迁移的虚拟机必须位于源主机和目标主机均可访问的存储器上:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image145.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb130.png" width="644" height="294" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">4. 数据及网络映射图:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image146.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb131.png" width="636" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image147.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb132.png" width="644" height="431" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">4. 确保源主机没有连接软盘和CD/DVD:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image148.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb133.png" width="592" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">8. VMotion过程图解</h3><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">8.1. 开始迁移</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image149.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb134.png" width="442" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image150.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb135.png" width="595" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">8.2 选择迁移对象</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image152.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb136.png" width="598" height="484" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><h4 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">8.3 迁移成功</h4><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image153.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb137.png" width="644" height="238" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">迁移中虚拟机Guest OS的网络状况:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); "><a href="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image154.png" style="color: rgb(10, 149, 170); text-decoration: none; padding: 0px 3px; font-style: italic; "><img title="VMware VMotion 详解" border="0" alt="VMware VMotion 详解" src="http://www.storageonline.com.cn/wp-content/uploads/2011/06/image_thumb138.png" width="644" height="236" style="border-width: 0px; max-width: 600px; display: inline; "></a></p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">从这幅图上可以看到,其实在迁移过程中网络连接是有一段非常短暂的中断的。但对于绝大多数网络应用程序所采用的TCP/IP协议通信来说,连接往往会超时重试,数据包往往会丢包重发,所以在中断时间较短的情况下,迁移并不影响虚拟机的正常网络通信。</p><h3 style="margin-bottom: 15px; padding-top: 20px; padding-bottom: 3px; font-size: 18px; border-bottom-width: 1px; border-bottom-style: solid; border-bottom-color: rgb(216, 216, 216); color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; line-height: 24px; background-color: rgb(244, 245, 247); ">9. VMotion关键技术</h3><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">VMotion用到下述三项技术:</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">1. 虚拟机的全部状态信息被压缩在一套存储于共享存储器的文件中。作为载体的存储器类型可以是光纤通道(Fibre Channel),iSCSI存储区域网络(iSCSI Storage Area Network,SAN)或者网络附加存储器(Network Attached Storage,NAS)。VMware的群集虚拟机系统(VMFS)允许多台ESX服务器同时访问同一个虚拟机文件。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">2. 虚拟机的动态内存和执行状态在一个高速的网络上进行快速传输,允许虚拟机即时地在源ESX服务器和目标ESX服务器之间进行信息交换。在迁移过程中,VMotion只是在点阵图里对信息交换进行监控,所以整个转移过程对用户来说是透明的。一旦整个内存和系统状态全部复制到目标ESX服务器中,VMotion就会自动终止源虚拟机,同时将点阵图转移到目标ESX服务器中,并在目标ESX服务器中重新启动虚拟机。上述整个操作假如是在一个千兆以太网络中进行,那么不用两秒的时间就可以完成。</p><p style="margin-top: 0.7em; margin-bottom: 0.7em; padding-top: 10px; padding-bottom: 5px; line-height: 1.8em; color: rgb(22, 21, 20); font-family: Tahoma, 'Century gothic', Arial, Tahoma, sans-serif; background-color: rgb(244, 245, 247); ">3. 虚拟机使用的网络同样也会被目标ESX服务器虚拟化,确保在实时迁移之后,虚拟机的网络身份和连接能够得到保留。VMotion将MAC地址作为进程的一部分来进行管理。一旦目标机被激活,VMotion会检查网络路由器来确保它能识别虚拟机MAC地址新的物理位置。由于虚拟机使用VMotion来进行实时迁移,它的执行状态,网络身份和动态链接都能够得到保护,所以对于用户来说,整个迁移过程并没有引起服务器停机或者网络中断。</p></div>
頁: [1]
查看完整版本: [轉貼]VMware vCenter VMotion 详解