怎么样解决安装vmware tools gcc的gcc和kernel header问题

如何样解决安装VMware Tools的gcc和kernel header有关问题 - Linux/Unix当前位置:& &&&如何样解决安装VMware Tools的gcc和kernel header有如何样解决安装VMware Tools的gcc和kernel header有关问题&&网友分享于:&&浏览:0次怎么样解决安装VMware Tools的gcc和kernel header问题?在vm中的Red&Hat系统中安装vmware&tools时,总是遇到两个问题,而我是Linux系统的初学者,解决不了,又没有百度到正确的答案。请高手指点,在安装vmware&tools前需要怎么样做好充分的准备,当遇到这样的问题时解决思路又是怎样的?
两个问题的提示为:
“Searching&for&GCC.....
The&path&"&"&is&not&valid&path&to&the&gcc&binary.
Would&you&like&to&change&it&?&[yes]&"
回车后,显示为:
“&What&is&the&location&of&the&gcc&program&on&your&machine&?"
这是如果输入本机的gcc路径&/usr/bin/gcc,&也会显示错误。
望高手不吝赐教,谢过了!!!
”&Searching&for&a&valid&kernel&header&path.....
The&path&"&"&is&not&a&valid&path&to&the&2.4.20-8&kernel&headers.
Would&you&like&to&change&it&?&[yes]"
望高手不吝赐教,谢了!!!!!------解决思路----------------------把&&Red&Hat&换掉吧------解决思路----------------------#yum&install&gcc
#yum&install&kernel-headers
BTW,&2.4.20&is&a&pretty&old&kernel.&Get&yourself&a&better&linux...try&centos&6------解决思路----------------------Debian&VMware&Tools安装:
VMWare&Debian&Linux&图形界面&vmware&tools&安装
jin&gong&can&kao------解决思路----------------------引用:Quote: 引用:
#yum&install&gcc
#yum&install&kernel-headers
BTW,&2.4.20&is&a&pretty&old&kernel.&Get&yourself&a&better&linux...try&centos&6
我终于知道是因为我的red&hat的内核版本低了,可是百度了一些安装2.6内核的方法,并不成功。
有更好的教程可以共享吗?
Is&there&a&particular&reason&that&you&have&to&stick&with&2.4.20?
If&not,&just&download&the&CentOS&6.5&at&centos.org.&It's&almost&as&same&as&RHEL&and&it's&free------解决思路----------------------原因:
RedHat内核版本的头文件的位置发生了变化,
导致之前,相对旧的VMWare&Tools,找不到对应的头文件,因此而报错。
解决办法:
用当前,实际上已经存在的头文件,做个软链接:
sudo&ln&-s&/usr/src/linux-headers-$(uname&-r)/include/generated/uapi/linux/version.h&/usr/src/linux-headers-$(uname&-r)/include/linux/version.h
就可以了。
12345678910
12345678910
12345678910 上一篇:下一篇:文章评论相关解决方案 12345678910 Copyright & &&版权所有博客访问: 519485
博文数量: 120
博客积分: 2595
博客等级: 少校
技术积分: 1202
注册时间:
IT168企业级官微
微信号:IT168qiye
系统架构师大会
微信号:SACC2013
分类: LINUX
&linux的vmwaretools 是:vmware-tools-distrib,版本不知道,大小是198MB&系统是debiantools挂在到cdrom后,有文件bin\
installer\
vmware-install.pl执行./vmware-install.pl 提示bash: ./vmware-install.pl: /usr/bin/perl: bad interpreter: 权限不够换成root,su后,还是。得了把,perl vmware-install.pl等了一会,开始运行。前面几个都没问题,回车即可。Installing VMware Tools.
In which directory do you want to install the binary files?
[/usr/bin]
What is the directory that contains the init directories (rc0.d/ to rc6.d/)?
What is the directory that contains the init scripts?
[/etc/init.d]
In which directory do you want to install the daemon files?
[/usr/sbin]
In which directory do you want to install the library files?
[/usr/lib/vmware-tools]
/usr/lib/vmware-tools/modules/binary/smp-2.4.9-34.athlon-RH7/objects/vmci.o
that this program was about to install already exists. Overwrite? [yes]
In which directory do you want to install the documentation files?
[/usr/share/doc/vmware-tools]
The path "/usr/share/doc/vmware-tools" does not exist currently. This program
is going to create it, including needed parent directories. Is this what you
want? [yes]
The installation of VMware Tools 7.8.4 build-126130 for Linux completed
successfully. You can decide to remove this software from your system at any
time by invoking the following command: "/usr/bin/vmware-uninstall-tools.pl".
Before running VMware Tools for the first time, you need to configure it by
invoking the following command: "/usr/bin/vmware-config-tools.pl". Do you want
this program to invoke the command for you now? [yes]
Stopping VMware Tools services in the virtual machine:
&&&Guest operating system daemon:
&&&Virtual Printing daemon:
None of the pre-built vmmemctl modules for VMware Tools is suitable for your
running kernel.
Do you want this program to try to build the vmmemctl module
for your system (you need to have a C compiler installed on your system)?
Setup is unable to find the "make" program on your machine.
Please make sure
it is installed.
Do you want to specify the location of this program by hand?
What is the location of the "make" program on your
The answer "" is invalid.
It must be the complete name of a binary file.
##这里,没有安装make,所以另外安装sudo apt-get install make,比较小#
What is the location of the "make" program on your
machine? /bin/make
#错误的,用which make知道了。
The answer "/bin/make" is invalid.
It must be the complete name of a binary
What is the location of the "make" program on your
machine? /usr/bin/make
Setup is unable to find the "gcc" program on your machine.
Please make sure it
is installed.
Do you want to specify the location of this program by hand?
[yes] /usr/bin/gcc
The answer "/usr/bin/gcc" is invalid.
It must be one of "y" or "n".
Setup is unable to find the "gcc" program on your machine.
Please make sure it
is installed.
Do you want to specify the location of this program by hand?
[yes]##这里要yes,不堪就打上了gcc路径,错误了#
The answer "gcc" is invalid.
It must be one of "y" or "n".
Setup is unable to find the "gcc" program on your machine.
Please make sure it
is installed.
Do you want to specify the location of this program by hand?
What is the location of the "gcc" program on your machine? /usr/bin/gcc
##前提是 apt-get install gcc 几分钟而已。#Using compiler "/usr/bin/gcc". Use environment variable CC to override.
Your kernel was built with "gcc" version "4.1.3", while you are trying to use
"/usr/bin/gcc" version "4.3.2". This configuration is not recommended and
VMware Tools may crash if you'll continue. Please try to use exactly same
compiler as one used for building your kernel. Do you want to go with compiler
"/usr/bin/gcc" version "4.3.2" anyway? [no]
The memory manager driver (vmmemctl module) is used by VMware host software to
efficiently reclaim memory from a virtual machine.
If the driver is not available, VMware host software may instead need to swap
guest memory to disk, which may reduce performance.
The rest of the software provided by VMware Tools is designed to work
independently of this feature.
If you want the memory management feature, you can install the driver by
running vmware-config-tools.pl again after making sure that gcc, binutils, make
and the kernel sources for your running kernel are installed on your machine.
These packages are available on your distribution's installation CD.
[ Press Enter key to continue ]
None of the pre-built vmhgfs modules for VMware Tools is suitable for your
running kernel.
Do you want this program to try to build the vmhgfs module for
your system (you need to have a C compiler installed on your system)? [yes]
Using compiler "/usr/bin/gcc". Use environment variable CC to override.
Your kernel was built with "gcc" version "4.1.3", while you are trying to use
"/usr/bin/gcc" version "4.3.2". This configuration is not recommended and
VMware Tools may crash if youCU还限制代码文字么,少了一段,继续??'ll continue. Please try to use exactly same compiler as one used for building your kernel. Do you want to go with compiler "/usr/bin/gcc" version "4.3.2" anyway? [no] yes##没有办法,自动安装的gcc版本和系统不相同也是正常的,又不是我编译的系统#What is the location of the directory of C header files that match your runningkernel? [/usr/src/linux/include] The path "/usr/src/linux/include" is not an existing directory.##没有内核的头文件,安装 apt-get install& build-essential kernel-headers-`uname -r`#前面的build-essential不知道是干什么用的。我的uname -r是2.6.26-2-686#(安装记录看最后)#What is the location of the directory of C header files that match your runningkernel? [/usr/src/linux/include] /usr/src//linux-headers-2.6.26-2-common/includeThe path "/usr/src//linux-headers-2.6.26-2-common/include" is a kernel header file directory, but it does not contain the file "linux/version.h" as expected.This can happen if the kernel has never been built, or if you have invoked the "make mrproper" command in your kernel directory.& In any case, you may want torebuild your kernel.What is the location of the directory of C header files that match your runningkernel? [/usr/src/linux/include]&&&& ##我傻了,缺少一个version.h文件,我那找去阿,自己touch一个先。#What is the location of the directory of C header files that match your runningkernel? [/usr/src/linux/include] /usr/src/linux-headers-2.6.26-2-common/includeThe directory of kernel headers (version @@VMWARE@@ UTS_RELEASE) does not matchyour running kernel (version 2.6.26-2-686).& Even if the module were to compilesuccessfully, it would not load into the running kernel.What is the location of the directory of C header files that match your runningkernel? [/usr/src/linux/include] ##接下来怎么办?请求帮助#####补充:这是安装build-essential的记录 apt-get install build-essential
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
将会安装下列额外的软件包:
&&dpkg-dev g++ g++-4.3 libstdc++6-4.3-dev libtimedate-perl
建议安装的软件包:
&&debian-keyring g++-multilib g++-4.3-multilib gcc-4.3-doc libstdc++6-4.3-dbg
&&libstdc++6-4.3-doc
下列【新】软件包将被安装:
&&build-essential dpkg-dev g++ g++-4.3 libstdc++6-4.3-dev libtimedate-perl
共升级了 0 个软件包,新安装了 6 个软件包,要卸载 0 个软件包,有 15 个软件未被升级。
需要下载 5615kB 的软件包。
解压缩后会消耗掉 20.6MB 的额外空间。
您希望继续执行吗?[Y/n]y
获取:1 http://security.debian.org lenny/updates/main dpkg-dev 1.14.29 [771kB]
获取:2 http://mirrors.geekbone.org lenny/main libstdc++6-4.3-dev 4.3.2-1.1 [1389kB]
获取:3 http://security.debian.org lenny/updates/main dpkg-dev 1.14.29 [771kB]
获取:4 http://mirrors.geekbone.org lenny/main libstdc++6-4.3-dev 4.3.2-1.1 [1389kB]
获取:5 http://mirrors.geekbone.org lenny/main g++-4.3 4.3.2-1.1 [3414kB]
获取:6 http://mirrors.geekbone.org lenny/main g++ 4:4.3.2-2 [1368B]
获取:7 http://mirrors.geekbone.org lenny/main libtimedate-perl 1.1600-9 [32.9kB]
获取:8 http://mirrors.geekbone.org lenny/main build-essential 11.4 [7118B]
下载 4677kB,耗时 6min26s (12.1kB/s)
选中了曾被取消选择的软件包 libstdc++6-4.3-dev。
(正在读取数据库 ... 系统当前总共安装有 101896 个文件和目录。)
正在解压缩 libstdc++6-4.3-dev (从 .../libstdc++6-4.3-dev_4.3.2-1.1_i386.deb) ...
选中了曾被取消选择的软件包 g++-4.3。
正在解压缩 g++-4.3 (从 .../g++-4.3_4.3.2-1.1_i386.deb) ...
选中了曾被取消选择的软件包 g++。
正在解压缩 g++ (从 .../g++_4%3a4.3.2-2_i386.deb) ...
选中了曾被取消选择的软件包 libtimedate-perl。
正在解压缩 libtimedate-perl (从 .../libtimedate-perl_1.1600-9_all.deb) ...
选中了曾被取消选择的软件包 dpkg-dev。
正在解压缩 dpkg-dev (从 .../dpkg-dev_1.14.29_all.deb) ...
选中了曾被取消选择的软件包 build-essential。
正在解压缩 build-essential (从 .../build-essential_11.4_i386.deb) ...
正在处理用于 man-db 的触发器...
正在设置 libtimedate-perl (1.1600-9) ...
正在设置 dpkg-dev (1.14.29) ...
正在设置 libstdc++6-4.3-dev (4.3.2-1.1) ...
正在设置 g++-4.3 (4.3.2-1.1) ...
正在设置 g++ (4:4.3.2-2) ...
正在设置 build-essential (11.4) ...
安装kernel-headersdebian:/home/ayanmw# apt-get install linux-headers-2.6.26-2-686
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
将会安装下列额外的软件包:
&&cpp-4.1 gcc-4.1 gcc-4.1-base linux-headers-2.6.26-2-common
&&linux-kbuild-2.6.26
建议安装的软件包:
&&gcc-4.1-locales gcc-4.1-multilib gcc-4.1-doc libmudflap0-dev
下列【新】软件包将被安装:
&&cpp-4.1 gcc-4.1 gcc-4.1-base linux-headers-2.6.26-2-686
&&linux-headers-2.6.26-2-common linux-kbuild-2.6.26
共升级了 0 个软件包,新安装了 6 个软件包,要卸载 0 个软件包,有 0 个软件未被升级。
需要下载 7258kB 的软件包。
解压缩后会消耗掉 41.3MB 的额外空间。
您希望继续执行吗?[Y/n]y
获取:1 http://security.debian.org lenny/updates/main linux-headers-2.6.26-2-common 2.6.26-21lenny4 [3722kB]
错误 http://mirrors.geekbone.org lenny/main gcc-4.1-base 4.1.2-25
&&无法连接上 mirrors.geekbone.org:80 (222.73.255.64)。 - connect (111 拒绝连接)
获取:2 http://mirrors.sohu.com lenny/main gcc-4.1-base 4.1.2-25 [207kB]
获取:3 http://mirrors.geekbone.org lenny/main cpp-4.1 4.1.2-25 [2317kB]
获取:4 http://mirrors.geekbone.org lenny/main gcc-4.1 4.1.2-25 [417kB]
获取:5 http://mirrors.geekbone.org lenny/main linux-kbuild-2.6.26 2.6.26-3 [194kB]
获取:6 http://security.debian.org lenny/updates/main linux-headers-2.6.26-2-686 2.6.26-21lenny4 [400kB]
下载 7258kB,耗时 6min59s (17.3kB/s)
选中了曾被取消选择的软件包 gcc-4.1-base。
(正在读取数据库 ... 系统当前总共安装有 92743 个文件和目录。)
正在解压缩 gcc-4.1-base (从 .../gcc-4.1-base_4.1.2-25_i386.deb) ...
选中了曾被取消选择的软件包 cpp-4.1。
正在解压缩 cpp-4.1 (从 .../cpp-4.1_4.1.2-25_i386.deb) ...
选中了曾被取消选择的软件包 gcc-4.1。
正在解压缩 gcc-4.1 (从 .../gcc-4.1_4.1.2-25_i386.deb) ...
选中了曾被取消选择的软件包 linux-headers-2.6.26-2-common。
正在解压缩 linux-headers-2.6.26-2-common (从 .../linux-headers-2.6.26-2-common_2.6.26-21lenny4_i386.deb) ...
选中了曾被取消选择的软件包 linux-kbuild-2.6.26。
正在解压缩 linux-kbuild-2.6.26 (从 .../linux-kbuild-2.6.26_2.6.26-3_i386.deb) ...
选中了曾被取消选择的软件包 linux-headers-2.6.26-2-686。
正在解压缩 linux-headers-2.6.26-2-686 (从 .../linux-headers-2.6.26-2-686_2.6.26-21lenny4_i386.deb) ...
正在处理用于 man-db 的触发器...
正在设置 gcc-4.1-base (4.1.2-25) ...
正在设置 cpp-4.1 (4.1.2-25) ...
正在设置 gcc-4.1 (4.1.2-25) ...
正在设置 linux-headers-2.6.26-2-common (2.6.26-21lenny4) ...
正在设置 linux-kbuild-2.6.26 (2.6.26-3) ...
正在设置 linux-headers-2.6.26-2-686 (2.6.26-21lenny4) ...
阅读(17954) | 评论(0) | 转发(0) |
相关热门文章
给主人留下些什么吧!~~
请登录后评论。vmware安装出现的linux-headers问题及解决办法
Linux公社()是专业的Linux系统门户网站,实时发布最新Linux资讯,包括Linux、Ubuntu、Fedora、RedHat、红旗Linux、Linux教程、Linux认证、SUSE
我安装vmware的时候,出现如下问题:None of the pre-built vmmon modules for VMware Workstation is suitable for your running kernel. Do you want this program to try to build the vmmon module for your system (you need to have a C compiler installed on your system)? [yes] yesUsing compiler "/usr/bin/gcc". Use environment variable CC to override.What is the location of the directory of C header files that match your running kernel? [/usr/src/linux/include] 然后系统就找不到/usr/src/linux/include这个目录,终于找了解决办法。出现这种问题是因为缺少一个文件linux-headers,,不过用如下一个vmware的补丁就可以解决了:vmware-any-any-update109.tar.gz。他的下载地址:wget 在要求输入[/usr/src/linux/include]时,用ctul+c断开,然后安装vmware-any-any-update109.tar.gz#tar zxvf vmware-any-any-update109.tar.gz#cd vmware-any-any-update109#./runme.pl
你最喜欢的

我要回帖

更多关于 centos kernel header 的文章

 

随机推荐