Centos 6.5 KVM Virtualization Platform Deployment

Source: Internet
Author: User
Tags svm

About KVM

Kernel-based virtual Machine is an open source system virtualization module that has been integrated into various major distributions of Linux since Linux 2.6.20. It is managed using Linux's own scheduler, so its core source code is few compared to Xen. KVM has become one of the mainstream VMM in academia today.

KVM Virtualization requires hardware support (such as Intel VT Technology or AMD V technology). is hardware-based full virtualization. The early days of Xen were software-based simulations of para-virtualization, and the new version was full virtualization based on hardware support. But Xen itself has its own process scheduler, storage Management module, etc., so the code is rather large. The widely circulated business system virtualization software VMware ESX series is a software-based simulation of the full-virtualization.


KVM Virtualization Platform Deployment

Check if the hardware environment supports virtualization

[[email protected] ~]# egrep--color ' (VMX|SVM) '/proc/cpuinfo vmx means INTEL,SVM represents AMD

Note: (I built the Centos6.5 x64 in VMware and supported the CPU Inter vt-x virtualization technology, the physical machine bios is turned on, but the check module does not have VMX.)

Workaround (for VMware Testers only): to implement nested virtualization on workstation, you need to edit the VMX file for the virtual machine, add vhv.enable = "TRUE" to locate the virtual machine installation file with a. vmx suffix, add it.

# cat/proc/cpuinfo FLAGS:FPU vme de PSE TSC MSR PAE MCE cx8 APIC Sep MTRR PGE MCA cmov Pat PSE36 clflush DTS MMX fxsr SS E SSE2 SS Syscall NX rdtscp LM constant_tsc up Arch_perfmon pebs BTS xtopology tsc_reliable nonstop_tsc aperfmperf unfair_ Spinlock PNI pclmulqdq vmx ssse3 cx16 pcid sse4_1 sse4_2 x2apic popcnt AES Xsave AVX hypervisor lahf_lm ida Arat EPB xsave Opt PLN pts DTS Tpr_shadow vnmi ept vpid

Mounting module

[[email protected] ~]# modprobe kvm[[email protected] ~]# modprobe kvm_intel[[email protected] ~]# lsmod | grep kvmkvm_intel 55496 0 KVM 337772 1 kvm_intel

Installing the KVM Management tool

# yum Install QEMU-KVM qemu-kvm-tools-y# ln-sv/usr/libexec/qemu-kvm/usr/sbin/# Rpm-qa | grep kvmqemu-kvm-tools-0.12.1.2-2.479.el6.x86_64qemu-kvm-0.12.1.2-2.479.el6.x86_64

QEMU-KVM standard options

The standard options for QEMU-KVM include the specified host type, CPU mode, NUMA, floppy drive device, optical drive device, and hardware device. -name name: Set the virtual machine name,-m machine: Specifies the type of host to impersonate, such as STANDARD PC, isa-only pc, or INTEL-MAC, you can use the QEMU-KVM  -m ? " Get all supported types;-m megs: Set the RAM size of the virtual machine;-cpu model: Set the CPU model, such as Coreduo, qemu64, etc., you can use "QEMU-KVM -CPU ?" Get all supported models;-smp n[,cores=cores][,threads=threads][,sockets=sockets][,maxcpus=maxcpus]: Set the number of CPUs in the analog SMP architecture, etc., The core number of each CPU and the number of sockets on the CPU; you can simulate up to 255 cpu;maxcpus on a PC to specify the maximum number of CPUs for hot insertion;-numa opts: Specifies a NUMA device that emulates multiple nodes;-fda  File-fdb file: Using the specified file as the floppy image, file for/dev/fd0 indicates the use of the physical floppy drive;-HDA FILE-HDB FILE-HDC FILE-HDD  file: Use the specified file as the hard disk image;-cdrom file: Using the specified file as the CD-ROM image, it is important to note that-cdrom and-HDC cannot be used at the same time; specify file as/dev/ CDROM can use the physical optical drive directly;-drive option[,option[,option[,...]] : Defines a hard disk device with many available sub-options. File=/path/to/somefile: Hardware image file path; If=interface: Specifies the type of interface to which the hard drive device is connected, that is, the controller type, such as IDE, SCSI, SD, MTD, Floppy, Pflash, and virtio, etc. ; Index=index: Sets the index number of the different devices in the same controller type, namely the identification number; Media=media: Defines whether the media type is hard disk or disc (CDROM); snapshot= Snapshot: Specifies whether the current hard drive device supports the snapshot feature:On or Off;cache=cache: defines how the physical machine cache can be used to access block data with a value of none, writeback, unsafe, and Writethrough four; Format=format: Specifies the format of the image file, The specific format can be found in the qemu-img command;-boot [order=drives][,once=drives][,menu=on|off]: Defines the boot order of the boot device, each device using a character representation Different architectures support devices and their representation characters are different, on the X86 PC architecture, A, b means the floppy drive, C for the first drive, D for the first optical drive device, N-P for the network adapter, and the default for the hard disk device;-boot order=dc,once =d


This article is from the "Chun Blog" blog, please be sure to keep this source http://ssc4469.blog.51cto.com/6315913/1685592

Centos 6.5 KVM Virtualization Platform Deployment

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.