Redhat5.4 安装 vmware7.1 无法启动

安装时有这样的错误:(下面的错误不是REDHAT产生的,不过也相差不多)

make: Entering directory `/tmp/vmware-config0/vmnet-only'
make -C /lib/modules/2.6.22-6-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.22-6-generic'

CC [ M] /tmp/vmware-config0/vmnet-only/driver.o
CC [ M] /tmp/vmware-config0/vmnet-only/hub.o
CC [ M] /tmp/vmware-config0/vmnet-only/userif.o
/tmp/vmware-config0/vmnet-only/userif.c: 在函数 ‘VNetCopyDatagramToUser’ 中:
/tmp/vmware-config0/vmnet-only/userif.c:630 : 错误: ‘const struct sk_buff’ 没有名为 ‘h’ 的成员
/tmp/vmware-config0/vmnet-only/userif.c:630 : 错误: ‘const struct sk_buff’ 没有名为 ‘nh’ 的成员
/tmp/vmware-config0/vmnet-only/userif.c:636 : 错误: ‘const struct sk_buff’ 没有名为 ‘h’ 的成员
make[ 2 ] : *** [ /tmp/vmware-config0/vmnet-only/userif.o] 错误 1
make[ 1 ] : *** [ _module_/tmp/vmware-config0/vmnet-only] 错误 2
make[ 1 ] : Leaving directory `/usr/src/linux-headers-2.6 .22 -6 -generic'
make: *** [vmnet.ko] 错误 2
make: Leaving directory `/tmp/vmware-config0/vmnet-only'

Unable to build the vmnet module.

 

 

在启动时弹出提示框:

 before you can run vmware workstation,several modules must be compiled and loaded into the running kernel

install_log :/tmp/vmware-root/setup-22883.log



查看里面的内容,有提示错误 的地方是这样的:

Mar 08 09:51:03.168: app-3079419584| Building module vmnet.
Mar 08 09:51:03.168: app-3079419584| Extracting the sources of the vmnet module.
Mar 08 09:51:03.180: app-3079419584| Building module with command: /usr/bin/make -C /tmp/vmware-root/modules/vmnet-only auto-build SUPPORT_SMP=1 HEADER_DIR=/
lib/modules/2.6.32.9-67.fc12.i686/build/include CC=/usr/bin/gcc GREP=/usr/bin/make IS_GCC_3=no VMCCVER=4.4.3
Mar 08 09:51:10.266: app-3079419584| Failed to compile module vmnet!



根据上面的提示,是安装不了vmnet,

通过查找find / -name  vmnet*

得到:/usr/lib/vmware/modules/source/vmnet.tar


解压安装,出现上面第一块那样的错误。


而这个错误可以这样纠正的:

当前路径是/usr/lib/vmware/modules/source
tar -vxf  vmnet.tar

得到vmnet-onlyr的文件夹,里面有这样的一个文件 compat_netdevice.h,把它打开:

gedit compat_netdevice.h 

把这个文件中的这样的一段内容:

struct napi_struct {

int dummy;

};

把这段内容注释掉。


再重新执行命令:make

这时没有报错,并生成一个vmnet.o文件。

执行下面的命令(也就是把vmnet.o文件复制到 /lib/modules/`uname -r`/misc/下,并改成vmnet.ko)

 cp -p vmnet.o  /lib/modules/`uname -r`/misc/vmnet.ko

 cp  vmnet.o  /lib/modules/`uname -r`/misc/


完成之后,执行

/etc/init.d/vmware restart


然后再去打开应用程序,这时会成功启动了。



另外一些小的疑问,就是安装完成软件后,不知道该软件的相关目录,以及如何去卸载

我个人认为:它主要的路径在/usr/lib/+与软件相关的文件名,

如/usr/lib/vmware-installer里面有VM的卸载工具。

也可以用命令vmware-installer -u vmware-workstation


另一个是/etc/init.d/ 主要是软件的配置文件。

/lib 是编译器的地方。

当然rpm 的卸载就相对比较简单,直接用命令就可以了。

 

参考于:http://jportal.javaeye.com/blog/524953

 

 

 

 

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值