“Centos7 使用kvm创建虚拟机”的版本间的差异

来自CloudWiki
跳转至: 导航搜索
(创建页面,内容为“==安装kvm== [root@controller ~]# cd /etc/yum.repos.d [root@controller yum.repos.d]# ls local.repo [root@controller yum.repos.d]# vi local.repo <nowiki>[kvm…”)
 
安装kvm
第1行: 第1行:
==安装kvm==
+
==1. KVM环境配置==
[root@controller ~]# cd /etc/yum.repos.d
+
关闭Selinux
 +
<nowiki>root@ localhost ~]#vim /etc/sysconfig/selinux
 +
# 修改SELINUX=disabled
 +
# 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=disabled
 +
# SELINUXTYPE= can take one of these two values:
 +
#    targeted - Targeted processes are protected,
 +
#    mls - Multi Level Security protection.
 +
SELINUXTYPE=targeted
  
[root@controller yum.repos.d]# ls
 
 
local.repo
 
 
[root@controller yum.repos.d]# vi local.repo
 
 
 
 
<nowiki>[kvm]
 
name=kvm
 
baseurl=file:///opt/kvm_yum
 
gpgcheck=0
 
enabled=1
 
 
</nowiki>
 
</nowiki>

2019年11月11日 (一) 07:38的版本

1. KVM环境配置

关闭Selinux root@ localhost ~]#vim /etc/sysconfig/selinux # 修改SELINUX=disabled # 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=disabled # SELINUXTYPE= can take one of these two values: # targeted - Targeted processes are protected, # mls - Multi Level Security protection. SELINUXTYPE=targeted