Your kernel headers for kernel 3.10...4 cannot found

Issues related to applications and software problems
Post Reply
Vahids
Posts: 4
Joined: 2014/09/17 15:02:24

Your kernel headers for kernel 3.10...4 cannot found

Post by Vahids » 2015/01/13 04:20:28

Hello,

I wants to install VirtualBox so I downloaded rpm file from VirtualBox web-site and installed by rpm command.
It's the error:

Code: Select all

[vahid@localhost Downloads]$ sudo service vboxdrv setup
Stopping VirtualBox kernel modules                         [  OK  ]
Uninstalling old VirtualBox DKMS kernel modules            [  OK  ]
Trying to register the VirtualBox kernel modules using DKMSError! echo
Your kernel headers for kernel 3.10.0-123.el7.x86_64 cannot be found at
/lib/modules/3.10.0-123.el7.x86_64/build or /lib/modules/3.10.0-123.el7.x86_64/source.
                                                           [FAILED]
  (Failed, trying without DKMS)
Recompiling VirtualBox kernel modules                      [FAILED]
  (Look at /var/log/vbox-install.log to find out what went wrong)
and It's the tail of vbox-install.log:

Code: Select all

[vahid@localhost Downloads]$ tail /var/log/vbox-install.log 
------------------------------
Done.
Attempting to install using DKMS

Creating symlink /var/lib/dkms/vboxhost/4.3.20/source ->
                 /usr/src/vboxhost-4.3.20

DKMS: add completed.
Failed to install using DKMS, attempting to install without
Makefile:183: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again.  Stop.
I installed Development Group packages, linux-header, dkms and all of this packages:
binutils qt gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-devel dkms
I set the KERN_DIR with /usr/src/kernels/3.10.0-123.13.2.el7.x86_64 and export KERN_DIR
but still same error.

:cry:

Vahids
Posts: 4
Joined: 2014/09/17 15:02:24

Re: Your kernel headers for kernel 3.10...4 cannot found

Post by Vahids » 2015/01/13 05:17:49

I found the issue.
It was booting time. I chooses another Kernel in grub booting, not default one and It's fixed now.

Thanks to myself :D

Post Reply