vboxadd.sh: Building Guest Additions kernel modules. Failed to set up service vboxadd, please check the log file /var/log/VBoxGuestAdditions.log for details.

Estava instalando o VirtualBox 5.1.10 Guest Additions na minha máquina virtual para reconhecimento de arquivos fora da camada da mesma, quando recebi o seguinte erro:

[root@host01 VBOXADDITIONS_5.1.10_112026]# sh VBoxLinuxAdditions.run
Verifying archive integrity... All good.
Uncompressing VirtualBox 5.1.10 Guest Additions for Linux...........
VirtualBox Guest Additions installer
Removing installed version 5.1.10 of VirtualBox Guest Additions...
vboxadd.sh: Stopping VirtualBox 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.

Verificando o log:

[root@host01 VBOXADDITIONS_5.1.10_112026]# cat /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..
chcon: can't apply partial context to unlabeled file `/usr/lib64/VBoxGuestAdditions/mount.vboxsf'
[root@host01 VBOXADDITIONS_5.1.10_112026]# cat /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.

A solução encontrada foi instalar os seguintes pacotes:

1.yum update gcc

2. yum update

3. yum install kernel-uek-devel

Related posts

Leave a Comment