1

In order to get VirtualBox 5.2 working on my Centos 7 VM, apparently, I need to install kernel headers. However there seems to be a mismatch on my system. When I run uname -r the following version is returned.

3.10.0-514.el7.x86_64

But when I check the kernels directory, ll /usr/src/kernels/, a different version is returned, as shown below.

drwxr-xr-x 22 root root 4096 Nov 23 07:12 3.10.0-862.14.4.el7.x86_64

Notice the version difference between the two. Should these two values match?

I tried searching for the 514 version with, yum search "kernel-headers-uname-r == $(uname -r)" --disableexcludes=all, but there was nothing found. See below.

Warning: No matches found for: kernel-headers-uname-r == 3.10.0-514.el7.x86_64 No matches found.

So the question is: Which headers do I install and if necessary where can I find the 514 version.

System Info:
Host: Windows 10
Client: Centos 7 - This is where I am installing Virtual Box and the kernel headers

navig8tr
  • 1,724
  • 8
  • 31
  • 69
  • I'm voting to close this question as off-topic because it's not about programming, but rather about RHEL(Fedora?/CentOS?) and belongs to https://unix.stackexchange.com/questions/tagged/linux – tink Nov 25 '18 at 03:52
  • Have you tried `sudo yum update`? – giwiro Nov 25 '18 at 04:01
  • Really wild stab in the dark -- but have you rebooted since you updated the kernel??? (you may well have installed `3.10.0-862`, but if you haven't rebooted since, you are still running on your old kernel) – David C. Rankin Nov 25 '18 at 04:20

1 Answers1

0
  1. find your kernel-devel at this link, for example: kernel-devel-3.10.0-693.el7.x86_64.rpm, then download it.

  2. rpm -i kernel-devel-3.10.0-693.el7.x86_64.rpm

check /usr/src/kernel/ folder.

VictorV
  • 637
  • 7
  • 16