云计算国产化之路 vnc登录 文件系统直通(virtio-9p) 扩展qemu接口 gpg WARNING 珍藏博客 虚拟内存情况dommemstat分析 免密码自动登录脚本 Linux网桥 测试网段IP占用情况 Linux 进程状态 systemc强制依赖 调试openstack ut uefi p2v 重做ubuntu内核 virsh创建虚拟机简介 virtio IO路径 虚拟化层升级后磁盘无法卸载卷 vmtouch使用 Taint flags 主机和虚拟机文件共享处理的几种方法 kvm分析工具 kvm中对磁盘的io cache 虚拟化不同导致的guestos中软件安装差异(未解决) 设备直通(PCI Assignment)到底是咋整的 virtio到底是咋整的 内核启动参数 虚拟化实时性提升(零)之配置步骤 中断虚拟化(pic)到底是咋整的 中断虚拟化(apic)到底是咋整的 Raid卡配置丢失导致服务器无法启动 tainted kernels cpu stuck for 23s问题分析 虚拟化实时性提升(一)之hostOS切换为强实时系统 内存虚拟化到底是咋整的 qemu-kvm中vcpu虚拟化到底是咋整的 风河虚拟化技术点分析 使用qga的好处 qemu迁移代码分析 虚拟机串口配置及其导出到主机pts和console.log System-based I/O vs. Raw I/O 虚拟机使用Hugepage(大页) 硬件辅助分页(hardware assisted paging) 修改centos7默认启动项目 virtio的工作流程——kernel中virtio-pci初始化(2) virtio的工作流程——qemu中virtio-backend初始化(1) qmp ceilometer取不到memory.usage指标 Virtio-Balloon超详细分析 slabtop输出 虚拟机磁盘cache导致的host os kernel崩溃 虚拟机cpu和memory性能优化测评 PCI配置空间(PCI Configuration Space) centos下网卡设备直通(VT-dpci passthrough)遇到的问题及其解决思路 libguestfs详解 yum卸载软件包及其依赖 通过原始Centos ISO来定制自己的ISO centos下网卡设备直通(VT-d,pci passthrough) (占位符)window虚拟机中拔盘如何通知到libvirt和qemu后端的 cirrus漏洞分析CVE-2017-2615 XSA-208 qcow2随笔 控制寄存器概览 ceilometer对接postgresql 解压initrd和vmlinuz qemu guest agent验证 QEMU升级指南(待续) ubuntu中kdump的配置 qemu(2.3)接口梳理 热迁移导致的FC存储场景下的multipath卷残留问题分析 virsh命令(4)secret,snapshot,pool,volume部分 virsh命令(3)之interface,filter,network virsh命令(2)monitor,host,nodedev部分 virsh命令(1)之domain部分 QEMU内存管理之FlatView模型(QEMU2.0.0) ovirt基于sanock的高可用(主机粒度HA) Sanlock防脑裂场景功能测试用例 gnocchi配置及与ceilometer对接指南 make patch for libvirt in centos centos使用sanlock指导 高可用nfs资料 ubuntu14中使用sanlock指导 LVM操作指南 sanlock相关功能验证流程汇总 make patch for libvirt in ubuntu libvirt.so.0-version `LIBVIRT_PRIVATE_1.2.7' not found gdb debug libvirt 基于ubuntu社区源码包编译libvirt compile libvirt(centos) No PCI buses available nfs lead to Linux halt nfs install and config anti-virus for cloud platform nova fetch image from glance(something about _base) token auth process ovs入门指南 virt software anti-virus something about ceilometer disk sample context interview questions openstack vm injection openstack Restful and RPC murano 概览 创建虚拟机流程(compute节点)之网络创建 创建虚拟机流程之compute_api之虚拟机实例填充之配额检测 创建虚拟机流程之compute_api之基本参数生成 创建虚拟机流程之compute_api 创建虚拟机流程(主) 创建虚拟机之image 创建虚拟机流程之准备网桥 创建虚拟机流程之virt 创建虚拟机流程之compute节点 CI/CD研发流程之工程创建 CI/CD研发流程之代码合入 CI/CD研发流程之UT(单元测试) 向openstack社区合入代码记 openstack/ceilometer/gnocchi杂谈 影子页表原理 mem_add(exec.c) qemu编译安装调试 openstack/ceilometer/gnocchi之Grafana简介 openstack wiki etcd openstack计量ceilometer openstack计费cloudKitty enventlet backdoor USB 安装VMWARE ESX pycharm设置指南 无法执行modprobe -a kvm-intel解决办法 QEMU配置项 网络不通小记 libvirt之XML(虚拟机定义文件) openstack-horizon 证书认证 ceilometer与ceph对接 openstack定时任务剖析(TODO) 服务器重启后mongodb进程无法启动 ubuntu14下新增openstack服务到service的导引 ERROR 1045(28000)-数据库连不上 Python两个内置函数—locals和globals unknown exit, hardware reason 31

无法执行modprobe -a kvm-intel解决办法

2015年03月03日

本人在服务上安装了vmware ESX,然后其中创建了几台虚拟机,安装了openstack的Liberty版本。
但是无法使用kvm,按照官方指导设置kvm的时候报错。

从字面意思可以查看是无法加载kvm_intel模块,由于服务器本人确认没有问题。 所以问题只可能出现在vmware虚拟机上。

打开SSH

默认ESX的ssh 是关闭的,可以在troubleshooting里面打开,具体操作谷歌一把。 修改VMware虚拟机

主要参考这里,为避免链接失效,现摘录如下:(需要在vmware的虚拟机磁盘文件中追加vhv.enable = “TRUE”)

Enable vmx/svm flags for the Guest/Nested hypervisor in Vmware ESXi5.5 from CLI
    The official guide - https://communities.vmware.com/docs/DOC-8970 - for enabling hardware assisted virtualization (VMX/SVM CPU flags) for the guest hypervisor is to use the web client. For those of us using this setup just for testing and using the free vsphere client, this method is not compatible.
    So how can vmware ESXi 5.5 be instructed to provide the CPU virtualization vmx flag to the guest hypervisor without web client ?
    There are two workarounds: one from the regular vsphere client and one from the ESXi 5.5 shell. Steps:
         Shutdown the nested/guest hypervisor (Ubuntu KVM in my case)
         Locate the guest hypervisor virtual machine configuration file (<VM-name.vmx>), edit and add the following line at the end:
        vhv.enable = "TRUE"
        Save and close the file.
         Identify the nested hypervisor vm ID and reload it's configuration with the [b]vim-cmd esxi command:[/b]
        ~ # vim-cmd vmsvc/getallvms | grep -i ubun
        44     VM6-Ubuntu-KVM        [datastore1] VM6-Ubuntu-KVM/VM6-Ubuntu-KVM.vmx             ubuntu64Guest      vmx-08
        ~ # vim-cmd vmsvc/reload 44
         Start the nested VM
        Verify that the nested hypervisor correctly detects the vmx flag
        Once the virtual machine started, login and check the /proc/cpuinfo file:
        $sudo grep -c vmx /proc/cpuinfo
        4

至此执行modprobe -a kvm-intel可以无误了。


默认情况下加载kvm_intel模块netst特性也是关闭的

通过以下方法删除模块,然后指定参数加载

另外,为了使得修改永久生效可以修改/etc/modprobe.d/kvm.conf

options kvm_intel nested=1