RedHat.Enterprise.Linux.5 VMtools 安装
按照Readme中的安装方法,一步步按照默认的设置下来,出现如下错误:
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 2.6.18-8.el5xen) does not match.
可以使用
[root@localhost ~]# uname -r // 查看内核版本号
查看目录/usr/src/ 根本没有linux这个目录
在网上收到资料:没有安装 kernel-xen-devel rpm包,在安装盘中找到这个rpm包:kernel-xen-devel-2.6.18-8.el5.i686.rpm
安装:
[root@localhost ~]# rpm -ivh kernel-xen-devel-2.6.18-8.el5.i686.rpm
再使用vmware-install.pl安装,即可自动找到配套的the directory of C header files
注意,网上还有人说需要安装的rpm包是kernel-devel,经过测试,安装kernel-devel-2.6.18-8.el5.i686.rpm包后依然无法自动找到the
directory of C header files,如果手动改目录为:/usr/src/kernels/2.6.18-8.e15-i686/include,会出现错误:
The directory of kernel headers (version 2.6.18-8.el5) does not match your running kernel (version 2.6.18-8.el5xen). Even if
the module were tocompile successfully, it would not load into the running kernel.
这就是安装的rpm不正确导致的。
安装好kernel-xen-devel-2.6.18-8.el5.i686.rpm包后,这样就一直enter,装完VMware Tools
在安装的最后阶段,会出现:
Do you want to change your guest X resolution? (yes/no) [no] y
Please choose one of the following display sizes (1 - 13):
[1] "640x480"
[2]< "800x600"
[3] "1024x768"
[4] "1152x864"
[5] "1280x800"
[6] "1152x900"
[7] "1280x1024"
[8] "1376x1032"
[9] "1400x1050"
[10] "1680x1050"
[11] "1600x1200"
[12] "1920x1200"
[13] "2364x1773"
Please enter a number between 1 and 13:
[3]
到了这步,千万别重启看效果,还要修改xorg config设置,不然重启后会报X-WINDOWS出错。
进入/etc/X11/,用文本打开xorg.conf,加上以下几段:
Section "Monitor"
Identifier "vmware"
EndSection
Section "InputDevice"
Identifier "Mouse0"
Driver "vmmouse"
Option "Protocol" "Auto"
Option "Device" "/dev/input/mouse0"
EndSection
然后找到 含有"ServerLayout" 的section, 在Section跟EndSection之间加上以下一行。
InputDevice "Mouse0" "CorePointer"
终于大功告成,重启看看效果了
重启之后,resolution不知道为何并没有变化,有待进一步研究,但是Mouse移进移出VMware可以不用再使用Ctrl+Alt键了