Step

  
of configuring KVM network in RedHat

KVM is a virtual machine. After installing KVM on RedHat system, you need to configure the KVM network. How to operate? The following small series will introduce you to the RedHat configuration KVM network method, interested friends may wish to understand.

kvm must be configured on the basis of RedHat 6 later on, we need to have at least 4GB of memory, cpu virtualization support, 25G disk space, 1Gbps network interface

One: modify the file < Br>

1: Copy the file (because my public network ip is set on eth2)

# cp /etc/sysconfig/network-scripts/ifcfg-eth2 /etc/sysconfig/network- Scripts/ifcfg-br0

2: Modify the ifcfg-eth2 file

# vi /etc/sysconfig/network-scripts/ifcfg-eth2

DEVICE=“eth2”

NM_CONTROLLED=“no”

BOOTPROTO=static

HWADDR=“00:22:19:B8:D9:FE”

IPV6INIT =“yes”

MTU=“1500”

ONBOOT=yes

TYPE=“Ethernet”

NAME=“System eth2&rdquo ;

BRIDGE=“br0”

UUID=“f2f96e91-9957-43bf-97b7-0cd67d8bb1e2”

Remove IP, netmask, change NM_controlled to no The internet Manage with networkmanager, use network management, add red part

3: modify ifcfg-br0 file

# vi /etc/sysconfig/network-scripts/ifcfg-br0

DEVICE=“br0”

BOOTPROTO=static

IPV6INIT=“yes”

MTU=“1500”

NM_CONTROLLED=“no&rdquo ;

ONBOOT=yes

TYPE=“Bridge”

IPADDR=10.200.117.95

GATEWAY=10.200.117.1

NETMASK=255.255.255.0

DNS1=10.200.117.18

Modify or add the red part

Two: Restart the service

Because we just managed the network Change to network (default use networkmanager management), now restart the network service, service network restart.

Three: confirm the configuration

ifconfig && brctl show

[root @cdsh2950b ~]# brctl show

bridge name bridge idSTP enabledinterfaces

br0 8000.002219b8d9fenoeth2

vnet0

virbr0 8000.525400c835f0yesvirbr0-nic

Four: Create a new virtual machine through virt-manager, I installed the system through the network PXE, so you need to remember the mac address, jumpstart Auto install above to register it.

The above is the introduction of RedHat configuration KVM network. It should be noted that KVM has requirements for RedHat system configuration, otherwise it cannot be configured.

Copyright © Windows knowledge All Rights Reserved