服务器 频道

如何在VMware ESX下打开复制的VM

  【IT168 论坛采风】

  网友问题:不好意思,我是一个ESX的初学者,以前一直用vmware workstation.在workstation下面,一个VM 复制后,可以通过file -> open 选择vmx文件就可以打开这个虚拟机。但在ESX好像没有这样的操作现象。请问大家都是怎么创建虚拟机的?不会每次都要从头来安装吧?

  解决方案:

  方法1、ESX是不行的,但可以通过模板的方式,也可以通过克隆的方式。或是通过CONVERT的方式,推荐前两者。WINDOWS要用到SYSPREP等。
  方法2、How to create a template without virtual center

  One of the great things about using ESX server (or any other virtual server host really) is that you can deploy new servers really quickly and easily. In the VMWare offering you have to buy the Virtual Centre add-on which is aimed at managing multiple virutal host servers. Unfortunately if you're in the situation where you don't have or can't get this and are stuck with the "basic" ESX licence then you could be a bit stuck when it comes to cloning or creating template machines.

  Fear not though! Here is a handy little guide on how to achieve that same objective using only ESX and the p2v converter.

  Step 1 - Create a Template in ESX without Virtual Centre

      * Obtain a copy of windows 2003/2008 (Please note: In order for ESX to run 64 bit guess O/S the hosts
      * Hardware bios cpu setting must be set to use Virtualization Technology.) See below
      * Launch Vmware Infrastructure client and connect over to the ESX server
      * Right click the ESX server and chose to create new virtual machine
      * Select Typical under virtual machine creation
      * Call the Virtual machine WIN2K3-TEMPLATE
      * Select a local vmfs partition if one has been setup, or chose a vmfs partition on external storage.
      * Select the appropriate Guest Operating System, either 2003 or 2008 etc..
      * Select 1 cpu (This can be changed in the future)
      * Select 256 for memory (This can be increased in the future)
      * Select no nics (This can be increased in the future)
      * Set the virtual disk size to 10 GB

  Step 2 - Creating Client Virtual Server Image

      * Right click the server and choose edit settings
      * Select CD/DVD to use either client device, host device or data store iso, remember to select connected and connect at power on. Insert OS cd into ESX host, local client pc that you have connected to ESX from, or point CD drive to OS iso.
      * Click on Ok
      * Power on the virtual machine and install Windows
      * Customise Windows as per clients builds, please do not install any applications such as SQL or Exchange.
      * Install clients Anti Virus software (If mcafee don't load epo agent, but load virus scan)
      * Install vmtools and enable hardware acceleration.
      * Load latest Microsoft Patches and Anti Virus definitions.
      * Install BGinfo (This displays server information on the server's desktop.
      * Open Notepad and type in ".LOG" without quotation marks, save this file as MOD.LOG and place in the all users startup folder. This file will open each time an administrator logs onto the server and stamp the date and time. Should be use for admin to note down changes made to the server (Change Control). Remember to select save as type "all files" otherwise will stamp the file MOD.LOG.TXT
      * Enable Remote Desktop
      * Rename the administrator account to admin_local or to the clients preferred local admin name
      * Change the admin_local password
      * Run a disk defrag
      * Create a folder on the servers C: drive called "Sysprep"
      * Download sysprep and extract the contents to the Sysprep folder on the C: drive
      * Run Setupmgr.exe
      * Select create new
      * Select Sysprep setup
      * Select windows version
      * Select No, do not fully automate the installation
      * Type in Organisation name
      * Display leave at default
      * Select correct time zone
      * Enter product key
      * Leave the "use the following computer name" box blank
      * Select prompt the end user for password
      * Select typical Networking components
      * Select workgroup and leave name as workgroup
      * Click next on Telephony
      * Specify regional settings (Chose UK) and tick customise the default regional setting and click on custom and select UK
      * Click next to languages
      * Click next to network printers
      * Click next to run once
      * Click next to additional commands
      * Please enter a Identification string "Virtual Tech Solutions Ltd, Build %date% Gold Server Image Version 2.1″ please replace with clients details
      * Click finish
      * Check that a file in C:\Sysprep\sysprep.inf has been created
      * Double click on sysprep.exe in the C:\Sysprep folder and select shutdown mode as Shutdown and click reseal. The Virtual Server will now switch off. PLEASE DO NOT POWER ON THIS VIRTUAL SERVER!!!!

  Step 3 - Use Vmconverter to Copy the Template to a new Virtual Server

      * Launch Vmconverter
      * Select Convert Virtual Machine
      * Select Vmware Infrastructure Virtual Machine
      * type in the ESX servers IP address where the template resides
      * Enter username and password
      * Click next
      * Select the template server and click next
      * Select convert all disks and maintain size and click next
      * Select destination type as Vmware Infrastructure Virtual Machine
      * type in the ESX servers IP address where the template resides
      * Enter username and password
      * Click next
      * Type in the new servers name, click next
      * Select the target ESX server again, click next
      * Select the target VMFS partition to create the new virtual server from template on, click next
      * Select 1 nic and correct network
      * Don't customise the guest, click next
      * Select power on new virtual machine after creation and select finish.
  * Check conversion process and once finished log onto the ESX server and access the new servers console and complete the setup wizard.

  原帖:http://www.ixpub.net/thread-930641-1-1.html
 

0
相关文章