Quickly build KVM and install Linux

Source: Internet
Author: User

Quickly build KVM and install Linux

Quickly build KVM and install Linux

1. Install KVM kernel and libmongod Components
Yum-y install kvm python-stronginst libvirt tunctl bridge-utils virt-manager qemu-kvm-tools virt-viewer

2. Load the KVM operating Module
[Root @ localhost ~] # Modprobe kvm
[Root @ localhost ~] # Modprobe-ls | grep kvm
Kernel/arch/x86/kvm. ko
Kernel/arch/x86/kvm/kvm-intel.ko
Kernel/arch/x86/kvm/kvm-amd.ko

3. Create a physical Bridge
Virsh iface-bridge eth0 br0
View Networks
[Root @ localhost ~] # Ifconfig
Br0 Link encap: Ethernet HWaddr 00: 0C: 29: C1: 62: 56
Inet addr: 192.168.150.136 Bcast: 192.168.150.255 Mask: 255.255.255.0
Inet6 addr: fe80: 20c: 29ff: fec1: 6256/64 Scope: Link
Up broadcast running multicast mtu: 1500 Metric: 1
RX packets: 4925 errors: 0 dropped: 0 overruns: 0 frame: 0
TX packets: 3937 errors: 0 dropped: 0 overruns: 0 carrier: 0
Collisions: 0 txqueuelen: 0
RX bytes: 532933 (520.4 KiB) TX bytes: 13484199 (12.8 MiB)
Eth0 Link encap: Ethernet HWaddr 00: 0C: 29: C1: 62: 56
Up broadcast running multicast mtu: 1500 Metric: 1
RX packets: 377686 errors: 0 dropped: 0 overruns: 0 frame: 0
TX packets: 110643 errors: 0 dropped: 0 overruns: 0 carrier: 0
Collisions: 0 FIG: 1000
RX bytes: 507725096 (484.2 MiB) TX bytes: 66233641 (63.1 MiB)

4. Create a Virtual Disk:
Qemu-img create-f qcow2/kvm/test003.img 5G

5. Create a virtual machine:
Qcow2 format
[Root @ localhost ~] # Virt-install -- name test003 -- ram 512 \
-- Vcpus = 1 -- disk path =/kvm/test003.img, size = 5, format = qcow2, bus = virtio \
-- Accelerate -- cdrom/tmp/CentOS-6.6-x86_64-minimal.iso \
-- Vnc -- vncport = 5910 -- vnclisten = 0.0.0.0 \
-- Network bridge = br0, model = virtio -- noautoconsole
Raw format:
[Root @ localhost ~] # Virt-install -- name test003 -- ram 512 \
-- Vcpus = 1 -- disk path =/kvm/test003.img, size = 5, bus = virtio \
-- Accelerate -- cdrom/tmp/CentOS-6.6-x86_64-minimal.iso \
-- Vnc -- vncport = 5910 -- vnclisten = 0.0.0.0 \
-- Network bridge = br0, model = virtio -- noautoconsole

6. VNC connection

-------------------------------------- Split line --------------------------------------

Getting started with Linux: KVM for Virtual Machine experience

RHEL6 KVM virtualization creates a bridge NIC-Bridge

RedHat Linux KVM Virtual Machine bridging

Installation/bridging settings of KVM in CentOS 5.6/virtual machine creation and operation

The/bin/qemu-KVM problem cannot be found when the kvm virtual machine is installed with libvirt In Ubuntu.

Install and configure the KVM Virtual Machine in RedHat6.5

-------------------------------------- Split line --------------------------------------

This article permanently updates the link address:

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.