1. 查看CPU是否支持虚拟化
cat /proc/cpuinfo | grep -E 'vmx|svm'
2. 清理环境:卸载KVM
yum remove `rpm -qa | egrep 'qemu|virt|kvm'` -y
rm -rf /var/lib/libvirt /etc/libvirt/
3. 安装软件
centos7 yum install *qemu* *virt* librbd1-devel -y
centos6 yum groupinstall "Virtualization" "Virtualization Client" "Virtualization Platform" "Virtualization Tools" -y
4. 启动服务
systemctl start libvirtd.service
systemctl enable libvirtd
5. 查看kvm模块加载
[root@LVMServer ~]# lsmod |grep kvm kvm_intel 174841 6 kvm 578518 1 kvm_intel irqbypass 13503 5 kvm
6. 创建虚拟机
virt-manager打开图形界面,新建虚拟机,需要实现将镜像传到服务器
选择安装介质
填写内存和CPU
填写磁盘大小
填写虚拟机名称