1、安装GCC开发工具 RdWLinux联盟 # Install software called by by VMware Tools RdWLinux联盟 yum install gcc RdWLinux联盟 2、安装内核文件 RdWLinux联盟 # Install kernel header files RdWLinux联盟 yum install kernel-devel RdWLinux联盟 3、检查内核文件的版本是否匹配,如果不匹配需要进行升级 RdWLinux联盟 # Check it matches the running kernel RdWLinux联盟 uname -r # running kernel RdWLinux联盟 rpm -q kernel-devel # installed kernel headers RdWLinux联盟 4、第3不中如果不匹配,则需要升级内核文件,升级完后,重新启动系统 RdWLinux联盟 # It the two versions do not match, run RdWLinux联盟 yum -y upgrade kernel kernel-devel RdWLinux联盟 # then reboot (but only if they did not match). RdWLinux联盟 5、查找内核文件的位置,安装VMware-tool工具时候需要(我装的时候,会自动查找到,不需要手工指定) RdWLinux联盟 # Find out where the kernel headers are RdWLinux联盟 ls -d /usr/src/kernels/$(uname -r)*/include RdWLinux联盟 # You may need this later. RdWLinux联盟 6、下载虚拟机工具安装包 RdWLinux联盟 即:VMware-tool安装包,并解压(具体就是在虚拟机工具栏上,点击"VM"->"Install VMware Tools",会出现安装包,选择*.gz的文件,解压到一个目录下就可以) RdWLinux联盟 以下是命令行中具体实现方法,我是在图形界面下实现的 RdWLinux联盟 # If you already have VMwareTools-5.5.2-29772.tar.gz RdWLinux联盟 on disk, SKIP THIS STEP! RdWLinux联盟 # Download VMware-workstation-5.5.2-29772.tar.gz from vmware.com RdWLinux联盟 # Extract the VMware Tools iso from it RdWLinux联盟 tar --strip-components=3 -zxvf VMware-workstation-5.5.2-29772.tar.gz \ RdWLinux联盟 vmware-distrib/lib/isoimages/linux.iso RdWLinux联盟 # Create a temporary mount point RdWLinux联盟 mkdir /mnt/vmtools-temp RdWLinux联盟 # Mount the image RdWLinux联盟 mount -o loop linux.iso /mnt/vmtools-temp RdWLinux联盟 # Copy VMware Tools from the mount RdWLinux联盟 cp /mnt/vmtools-temp/VMwareTools-5.5.2-29772.tar.gz /tmp/ RdWLinux联盟 # Unmount the image and tidy up RdWLinux联盟 umount /mnt/vmtools-temp RdWLinux联盟 rmdir /mnt/vmtools-temp RdWLinux联盟 rm linux.iso RdWLinux联盟 # Unpack VMware Tools to a temporary directory RdWLinux联盟 cd /tmp/ RdWLinux联盟 tar zxvf VMwareTools-5.5.2-29772.tar.gz RdWLinux联盟 7、进入解压目标目录,执行以下代码,一路回车按下来 RdWLinux联盟 cd /tmp/vmware-tools-distrib/ RdWLinux联盟 ./vmware-install.pl RdWLinux联盟 8、直到该步骤,拷贝粘贴第5步的路径,然后一直按回车,直到选择屏幕分辨率。 RdWLinux联盟 What is the location of the directory of C header files that match your running RdWLinux联盟 kernel? [/usr/src/kernels/2.6.18-1.2849.fc6-i686/include] RdWLinux联盟 我安照网上的安装步骤,做到这步后就安装上下去了。提示以下错误: RdWLinux联盟 What is the location of the directory of C header files that match your running RdWLinux联盟 kernel? [/usr/src/linux/include] /usr/src/kernels/2.6.20-1.2952.fc6-i686/include RdWLinux联盟 The directory of kernel headers (version @@VMWARE@@ UTS_RELEASE) does not match RdWLinux联盟 your running kernel (version 2.6.20-1.2952.fc6). Even if the module were to RdWLinux联盟 compile successfully, it would not load into the running kernel. RdWLinux联盟 请各位高手看看我应该怎么做才能解决这个问题。谢谢。 RdWLinux联盟
|