侧边栏壁纸
博主头像
聆尘风博主等级

欲买桂花同载酒,终不似,少年游

  • 累计撰写 56 篇文章
  • 累计创建 17 个标签
  • 累计收到 2 条评论

目 录CONTENT

文章目录

Linux KVM的环境配置及安装

聆尘风
2024-03-19 / 0 评论 / 0 点赞 / 14 阅读 / 2301 字

KVM环境配置

基础配置

前提:必须要

2核

2cpu

4G运行

50及以上硬盘

配置网络:

vi /etc/sysconfig/network-scripts/ifcfg-ens33

进去后配置网卡文件

ONBOOT=yes

保存并推出,重启网卡服务

service network restart

更新软件源:

yum update -y

更新不了请看文章Linux update不能更新-聆尘风

关闭防火墙和selinux

systemctl stop firewalld	#关闭防火墙
systemctl disable firewalld #永久关闭防火墙自启动
systemctl status firewalld  #查看防火墙状态

关闭selinux

vi /etc/sysconfig/selinux
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disable
# SELINUXTYPE= can take one of three values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted
#配置SELINUX = disabled
#配置完成后保存并退出
#重新启动
reboot

下载虚拟环境

yum -y install qemu-kvm virt-install libvirt tunctl bridge-utils virt-manager qemu-kvm-tools virt-viewer virt-v2v libguestfs-tools  #安装相关的软件

启动libvirt服务:

systemctl start libvirtd

创建软链接

ln -s /usr/libexec/qemu-kvm /usr/bin/qemu-kvm

完成后

0

评论区