gpt4 book ai didi

centos - 安装 vagrant 时缺少 centos 7 的 yum 包

转载 作者:太空宇宙 更新时间:2023-11-03 17:14:22 26 4
gpt4 key购买 nike

我刚刚安装了centos 7,然后尝试安装vagrant。安装 virtualbox 然后 vagrant 之后,当我运行 vagrant up 我得到:

VirtualBox is complaining that the kernel module is not loaded. Please
run `VBoxManage --version` or open the VirtualBox GUI to see the error
message which should contain instructions on how to fix this error.

我运行“VBoxManage --version”但出现错误

The vboxdrv kernel module is not loaded. Please recompile the kernel module and install it by sudo /etc/init.d/vboxdrv setup

我运行 sudo/etc/init.d/vboxdrv setup 我得到了

Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> 

缺少什么包?

最佳答案

您必须通过以下方式安装“gcc”和“kernel-devel”:

sudo yum install gcc kernel-devel

然后运行重新编译virtual box:

sudo /etc/init.d/vboxdrv setup

你现在可以运行:

vagrant up

关于centos - 安装 vagrant 时缺少 centos 7 的 yum 包,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25611331/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com