今天在安装VMTools时,我也碰到此问题了。已解决!
安装环境:
VMWare 5.5.1 + Ubuntu8.10
----------------问题及解决-----------------------
What is the location of the directory of C header files that match your running kernel? [/usr/src/linux/include]
The path "/usr/src/linux/include" is not an existing directory.
这一步是让你指定c头文件所在的位置,我们进入/usr/src目录,应该这里有两个目录linux-headers-2.6.31-14和 linux- headers-2.6.31-14-generic,现在我们要做的就是新建一个软链接linux,让它指向linux-headers-2.6.31 -14-generic,命令如下
ln -s linux-headers-2.6.31-14-generic linux
现在我们就有了linux这个目录,包含了c头文件,但我们继续配置,还可能会出现以下错误:
What is the location of the directory of C header files that match your running kernel? [/usr/src/linux/include]
The directory of kernel headers (version @@VMWARE@@ UTS_RELEASE) does not match your running kernel (version 2.6.31-14-generic). Even if the module were to compile successfully, it would not load into the running kernel.
What is the location of the directory of C header files that match your running kernel? [/usr/src/linux/include]
我们明明以及指向了正确的linux内核头文件夹了,但还是报错了,我们可以这样修改:
进入/usr/src/linux/include/linux目录,修改下面的version.h文件
增加下面一行:
#define UTS_RELEASE "2.6.31-14-generic"
保存退出,继续配置vmware, 安装成功!
友情提示:出现此问题时,不需要中断VMWare Tools的安装,新启动个 Terminal 操作即可!