Common Parameters of the qemu-kvm Command Line Virtual System

Source: Internet
Author: User
Article Title: common parameters of the qemu-kvm command line virtual system. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.

For example, to install a Windows 7 system, common parameters are as follows:

Qemu-kvm-m 1024-localtime-M pc-smp 1-drive file = Windows7_x86.img, cache = writeback, boot = on-net nic, macaddr = 52: 54: 00: 12: 34: 80-net tap-cdrom Windows7.iso-boot d-name kvm-win7, process = kvm-win7-vnc: 2-usb-usbdevice tablet

-M 1024: Set the virtual system memory to 1024 MB.

-Localtime: Make the virtual system consistent with the host system time

-M pc: the virtual system type is pc.

-Smp: 1 CPU

-Drive file = Windows7_x86.img, cache = writeback, boot = on

Hard Disk option. The virtual disk is Windows7_x86.img, And the cache mode is writeback.

-Net nic, macaddr = 52: 54: 00: 12: 34: 80 nic option, manually specify the mac address.

-Net tap type network, equivalent to "Bridge Mode"

-Cdrom windows 7.iso Optical Drive

-Boot d startup sequence. D Represents the optical drive.

-Name kvm-win7, process = kvm-win7 name the Virtual Machine for easy identification

-Vnc: 2 here is the control window through vnc connection, and here is the port 5902. Available client IP: 2 connection.

-Usb device tablet enables the tablet function on the usb device. Enable this function to synchronize the mouse inside and outside the VM.

In addition, after the disk and network card are installed with a semi-virtualization driver, you can add if = virtio in-drive to use the disk semi-virtualization, add model = virtio to-net nic to use the semi-virtualization driver of the nic.

For example, to install a Windows 7 system, common parameters are as follows:

Qemu-kvm-m 1024-localtime-M pc-smp 1-drive file = Windows7_x86.img, cache = writeback, boot = on-net nic, macaddr = 52: 54: 00: 12: 34: 80-net tap-cdrom Windows7.iso-boot d-name kvm-win7, process = kvm-win7-vnc: 2-usb-usbdevice tablet

-M 1024: Set the virtual system memory to 1024 MB.

-Localtime: Make the virtual system consistent with the host system time

-M pc: the virtual system type is pc.

-Smp: 1 CPU

-Drive file = Windows7_x86.img, cache = writeback, boot = on

Hard Disk option. The virtual disk is Windows7_x86.img, And the cache mode is writeback.

-Net nic, macaddr = 52: 54: 00: 12: 34: 80 nic option, manually specify the mac address.

-Net tap type network, equivalent to "Bridge Mode"

-Cdrom windows 7.iso Optical Drive

-Boot d startup sequence. D Represents the optical drive.

-Name kvm-win7, process = kvm-win7 name the Virtual Machine for easy identification

-Vnc: 2 here is the control window through vnc connection, and here is the port 5902. Available client IP: 2 connection.

-Usb device tablet enables the tablet function on the usb device. Enable this function to synchronize the mouse inside and outside the VM.

In addition, after the disk and network card are installed with a semi-virtualization driver, you can add if = virtio in-drive to use the disk semi-virtualization, add model = virtio to-net nic to use the semi-virtualization driver of the nic.

Related Article

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.