thx*_*ike 9 virtualbox vagrant
根据以下文档https://www.vagrantup.com/docs/virtualbox/boxes.html下载以下iso VBoxGuestAdditions_5.1.0.iso后
然后运行以下命令
sudo mkdir /media/VBoxGuestAdditions
sudo mount -o loop,ro VBoxGuestAdditions_5.1.0.iso /media/VBoxGuestAdditions
sudo sh /media/VBoxGuestAdditions/VBoxLinuxAdditions.run
Run Code Online (Sandbox Code Playgroud)
我收到并出错:
设置服务 vboxadd 失败,请查看日志文件 /var/log/VBoxGuestAdditions.log 了解详情。
当我查看此日志时,它引用了另一个日志文件/var/log/vboxadd-install.log。当我查看此日志时,我看到以下内容:
make KBUILD_VERBOSE=1 CONFIG_MODULE_SIG= -C /lib/modules/3.13.0-93-generic/build SUBDIRS=/tmp/vbox.0 SRCROOT=/tmp/vbox.0 -j2 modules
make[1]: Makefile: No such file or directory
make[1]: warning: -jN forced in submake: disabling jobserver mode.
make[1]: *** No rule to make target `Makefile'. Stop.
make: *** [vboxguest] Error 2
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
Run Code Online (Sandbox Code Playgroud)
我安装了以下软件包。我什至删除了它们并再次添加它们:
linux-headers-$(uname -r) linux-generic linux-image-generic linux-headers-generic linux-signed-generic dkms build-essential
我不确定如何进一步调试。对问题的任何帮助将不胜感激。
此外,我还尝试使用 Virtual Box 附带的 Guest 附加 CD。进入 CD 并接受安装后,出现以下情况 插入 Guest Additions CD 后,我收到以下错误:
Verifying archive integrity... All good.
Uncompressing VirtualBox 5.1.4 Guest Additions for Linux...........
VirtualBox Guest Additions installer
Removing installed version 4.3.20 of VirtualBox Guest Additions...
Copying additional installer modules ...
Installing additional modules ...
vboxadd.sh: Building Guest Additions kernel modules.
Failed to set up service vboxadd, please check the log file
/var/log/VBoxGuestAdditions.log for details.
Press Return to close this window...
Run Code Online (Sandbox Code Playgroud)
然后我继续查看文件 /var/log/VBoxGuestAdditions.log,这就是它的指示:
vboxadd.sh: failed: Look at /var/log/vboxadd-install.log to find out what went wrong.
vboxadd.sh: failed: Please check that you have gcc, make, the header files for your Linux kernel and possibly perl installed..
Run Code Online (Sandbox Code Playgroud)
然后我继续打开 /var/log/vboxadd-install.log 并看到以下内容:
/tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again. Stop.
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
Run Code Online (Sandbox Code Playgroud)
这使系统处于不良状态,除了重新开始映像外,无法恢复。
小智 13
似乎您没有满足一些先决条件,例如:
apt-get install build-essential module-assistant linux-headers-$(uname -r)
它对我有用。
| 归档时间: |
|
| 查看次数: |
45443 次 |
| 最近记录: |