Install and run Windows in Centos of OpenVZ Virtualization

Source: Internet
Author: User
Tags windows remote desktop

OpenVZ is synonymous with Linux-based VPS. Generally, OpenVZ cannot directly Virtualize Windows servers. However, we can install KVM in LinuxVPS to build a Windows environment.

This solution applies to CentOS 5 series 32-bit and 64-bit systems. The virtualization environment is OpenVZ. Of course, the virtualization of the XEN and KVM architectures is also possible, because the virtualization of the later two systems can run Windows directly, this is an alternative.


I. Clean up the memory
Yum remove httpd # Delete apache. For other components, add yum-y update # update all components.

Run the preceding commands by Using SSH to delete unnecessary services and save system memory.


2. Download related one-click packages and resources
1. VNC + fluxbox one-key package
wget http://soft.kwx.gd/vnc-server/fluxbox_anejd.sh;sh fluxbox_anejd.sh


During this period, you must enter the VNC password. Follow the system prompts to enter the password and confirm the password (twice the same ).


2. qemu one-key package
wget http://soft.kwx.gd/tools/windows_anejd.sh;sh windows_anejd.sh

3. Download the Operating System (ghostversion is recommended)

You can download an ISO image file from www.xitong5.com or upload it to the/root directory.


4. Download VNC at the same time (Remote Control of Windows)

: Http://soft.kwx.gd/tools/vncviewer.zip

For more information, see FluxBox desktop + VNC Server one-key installation package graphic tutorial.


3. Establish a system
1. Create a Virtual Disk
qemu-img create -f qcow kwxgd.img 10G

Run the preceding command in SSH. kwxgd. img is the name of the virtual disk, and 10 Gb indicates the size of the virtual disk. Create a virtual disk based on your own VPS.


2. Try to log on to VNC

Use your vps ip Address: 1 (Port: 1) to log on to VNC.


3. After downloading the operating system, create a virtual machine (automatically running)
qemu -cdrom winxp.iso -m 256M -boot d kwxgd.img

Run the above command on the SSH client of VNC, where "winxp. iso "is the image file of your operating system CD," kwxgd. "img" is the virtual disk name, "M" indicates the memory size of the virtual machine, Please modify according to your situation.


Iv. Post-Management

Run the following command to enable Windows:


qemu -hda kwxgd.img -boot c -m 512M -k de -usb -redir tcp:3389::3389

"-Redir tcp: 3389: 3389" can be added to the backend to map to Windows 3389. After the system is enabled, you can directly connect to Windows through Windows Remote Desktop.

Note: before installing the system, use disk tools such as PQ to partition and set the partition of the system disk as "function" or "bootable ". It has been tested that Windows runs very slowly in OpenVZ, and it seems that it can only be used for hanging up, so do not make too much expectations for Windows in this environment.

Finally, I would like to thank the Hostloc user "_________ Cc" for providing the tutorial.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.