I have installed CentOS 7 as a guest under VMWare Workstation 7 on a Windows 7 host, and the problem is that I can't drag and drop files, nor copy and paste. VMWare's documentation has the following:


Where they basically say that:

  1. In order to enable drag and drop, you have to install the vmhgfs driver.
  2. In order to install vmhgfs, you have to first install the open source Open VMware tools (the open-vm-tools package), and then install the VMWare's supplied VMWare Tools on top of that.

The problem is that, when installing the latter, it requires you to compile a kernel module, and when doing so, it asks for the path to the kernel headers, and no matter what you add, it says that the path is not valid. Basically, it's the same problem described here:


If you google it, you'll find that there's a lot of people with the same problem. The solution usually suggested is to install the kernel-devel package, but I've done so, and it doesn't work either. I have two different kernel header packages installed:

  • kernel-devel-3.10.0-229.el7.x86_64
  • kernel-devel-3.10.0-229.l4.l.el7.x86_64

I've tried giving VMWare's installer all the following paths:

  • /usr/src/kernels/3.10.0-229.el7.x86_64
  • /usr/src/kernels/3.10.0-229.el7.x86_64/include
  • /usr/src/kernels/3.10.0-229.el7.x86_64/include/linux
  • /usr/src/kernels/3.10.0-229.l4.l.el7.x86_64
  • /usr/src/kernels/3.10.0-229.l4.l.el7.x86_64/include
  • /usr/src/kernels/3.10.0-229.l4.l.el7.x86_64/include/linux

And no matter what, it says that it's not a valid path.

As I said, if you google this, you'll find a lot of people with the same problem, while for others it seems to simply "work", without doing anything. What's going on?


Is gcc installed? I agree that you need the kernel development headers to recompile the extensions in, but then you also need the compiler as well.

You can find out with: yum list gcc

Minimal installs of CentOS won't include a compiler, and installing the kernel headers doesn't require one. So folks who do a standard "developer" install would have no issues, but those that do a minimal would always have an issue.

  • Yes, gcc is installed: gcc.x86_64. If I call the compiler with "gcc", it says "gcc: fatal error, no input files". – PaulJ Apr 19 '16 at 15:53

This video has a good explantation: https://www.youtube.com/watch?v=cG29Ro_naN4

What it comes down to is that your kernel version and kernel devel need to match.

yum update
yum install gcc kernel-devel

To find the kernel version:

uname -r

To find the kernel-devel version:

rpm -q kernel-devel

If the versions do NOT match:

yum update kernel

Now the version should match and you should be able to install vmware tools.

Your Answer

By clicking "Post Your Answer", you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.