在 CentOS 5.X 安装 VMWare Tools

Abstract
安装VMWare Tools有很多优点,不过在CentOS下安装比较麻烦,本文是我的安装心得。

Introduction
使用环境 :
VMWare 6.0.2 + CentOS 5.1

安装VMWare Tools有几个优点:
1.可以支援其他解析度,不再局限于640 x 480和800 x 600。
2.Host OS与Guest OS传档时,只需滑鼠拖曳即可。
3.滑鼠在Host OS与Guest OS切换时,不需再按Ctrl + Alt。

根 据以前的经验,若Guest OS是Fedora与Windows XP时,只要在VMWare选VM -> Install VMWare Tools...,就会在桌面出现VMWare Tools图示让你安装,但若Guest OS为CentOS时,桌面上并没有任何图示出现,请依照以下步骤为CentOS安装VMWare Tools。

Step 1:
将VMWare的光碟机设定成C:/Program Files/VMware/VMware Workstation/linux.iso,VMWare Tools在这个iso档内。

vmware_tools_centos_00.gif


Step 2:
进入CentOS桌面后,将光碟机打开,看到了VMWareTools-6.0.2-59824.i386.rpm与VMWareTools-6.0.2.59824.tar.gz。

vmware_tools_centos_01.gif


看到rpm你应该很兴奋,因为CentOS与Fedora/RHEL师出同源,所以应该可以用,但经我测试结果,是可以安装,安装过程也没有错误,但可惜安装完没有VMWare Tools该有的功能,所以只能用tarball来安装了。

Step 3:
将VMWareTools-6.0.2.59824.tar.gz复制到home directory,进行解压缩。

[ root@localhost ~ ] # tar zxvf VMwareTools- 6.0.2 - 59824 .tar.gz


Step 4:
进入解压缩后的vmware-tools-distrib目录

[ root@localhost ~ ] # cd vmware-tools-distrib/


Step 5:
执行vmware-install.pl安装VMWare Tools

[ root@localhost vmware-tools-distrib ] # ./vmware-install.pl


之后出现很多问题,都接受预设值一直按enter即可,唯一问到萤幕解析度问题,若你想使用其他解析度,请自行设定如下:

Please choose one of the following display sizes that X will start with ( 1  - 
15 ):

[ 1 ]    " 640x480 "
[ 2 ] " 800x600 "
[ 3 ]    " 1024x768 "
[ 4 ]    " 1152x864 "
[ 5 ]    " 1280x800 "
[ 6 ]    " 1152x900 "
[ 7 ]    " 1280x1024 "
[ 8 ]    " 1376x1032 "
[ 9 ]    " 1400x900 "
[ 10 ]    " 1400x1050 "
[ 11 ]    " 1440x900 "
[ 12 ]    " 1680x1050 "
[ 13 ]    " 1600x1200 "
[ 14 ]    " 1920x1200 "
[ 15 ]    " 2364x1773 "
Please enter a number between 
1  and  15 :

[ 2 ]   3


最后出现以下讯息,表示安装成功。

X Window System Version  7.1.1
Release Date: 
12  May  2006
X Protocol Version 
11 ,  Revision  0 ,  Release  7.1.1
Build Operating System: Linux 
2.6.9 - 67 .ELsmp i686 Red Hat ,  Inc.
Current Operating System: Linux localhost.localdomain 
2.6.18 - 53.1.19 .el5 # 1  SMP Wed May  7   08 : 20 : 19  EDT  2008  i686
Build Date: 
19  January  2008
Build ID: xorg-x11-server 
1.1.1 - 48.26 .el5_1 .5  
        Before reporting problems
,  check http://wiki.x.org
        to make sure that you have the latest version.
Module Loader present
Markers: (--) probed
,  (**) from config file ,  ( == ) default setting ,
        (++) from command line
,  (!!) notice ,  (II) informational ,
        (WW) warning
,  (EE) error ,  (NI) not implemented ,  (??) unknown.
(++) Log file: 
" /tmp/vmware-config0/XF86ConfigLog.2977 " ,  Time: Fri Jun   6   15 : 14 : 32   2008
(++) Using config file: 
" /tmp/vmware-config0/XF86Config.2977 "

X is running fine with the new config file.

FreeFontPath: FPE 
" unix/:7100 "  refcount is  2 ,  should be  1 ;  fixing.
Starting VMware Tools services in the virtual machine:
   Switching to guest configuration:                       
[   确定   ]
   Guest filesystem driver:                                
[   确定   ]
   Mounting HGFS shares:                                   
[ 失败 ]
   Guest memory manager:                                   
[   确定   ]
   Guest vmxnet fast network device:                       
[   确定   ]
   Blocking file system:                                   
[   确定   ]
   DMA setup:                                              
[   确定   ]
   Guest operating system daemon:                          
[   确定   ]

The configuration of VMware Tools 
6.0.2  build- 59824  for Linux for this running 
kernel completed successfully.

You must restart your X session before any mouse or graphics changes take 
effect.

You can now run VMware Tools by invoking the following command: 
" /usr/bin/vmware-toolbox "  during an X server session.

To use the vmxnet driver
,  restart networking using the following commands: 
/etc/init.d/network stop
rmmod pcnet32
rmmod vmxnet
modprobe vmxnet
/etc/init.d/network start

To make use of the virtual printer
,  you will need to restart the CUPS service

Enjoy
,

--the VMware team


重新启动CentOS,你就会发现新的萤幕解析度出现,并且滑鼠不需再切换,且可使用拖曳的方式传档。

Conclusion
以前在VMWare 5时,虽然VMWare Tools可以拖曳传档,但速度非常慢,但在VMWare 6的传档速度非常快,看来进步不少。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章