vmware虚拟机的vmwaretool

    安装VMwaretool,如果VMwaretool是灰色的,在虚拟机设置中,先移除CD/DVD然后在重新添加上就就可以了,然后把VMwareTools-10.2.5-8068393.tar.gz复制出来执行vmware-install.pl,根据提示配置。

    在安装VMwaretool,执行

    ./vmware-install.pl

    时出现如下内容,表明当前系统中存在找open-vm-tools这个软件,根据提示内容需要更新到指定给你版本或者卸载掉。

    For kernels >= 4.0.0, the open-vm-tools packages need to be of version 10.0.0 or higher for VMware Host Guest Filessystem (vmhgfs) to function with VMware Tools. Please upgrade open-vm-tools packages and rerun this installer, or uninstall open-vm-tools packages. Alternatively, you can disable using vmhgfs when VMware Tools are configured

    搞了好久,怎么弄就不行,最后卸载得了。在Ubuntu中卸载

    apt-get remove open-vm-tools

    搜了一些内容后知道open-vm-tools和VMwaretool功能是一样的,两个同时存在会冲突。

    删除时出现如下问题

    E: Could not get lock /var/lib/dpkg/lock - open (11: Resource temporarily unavailable) E: Unable to lock the administration directory (/var/lib/dpkg/), is another prod ess using it?

    执行ps afx|grep apt

    然后杀死进程,再运行apt-get remove open-vm-tools,如果还是被占用,就删除锁定文件,锁定的文件会阻止 Linux 系统中某些文件或者数据的访问,这个概念也存在于 Windows 或者其他的操作系统中。

    一旦你运行了 apt-get 或者 apt 命令,锁定文件将会创建于 /var/lib/apt/lists/、/var/lib/dpkg/、/var/cache/apt/archives/ 中。

     这有助于运行中的 apt-get 或者 apt 进程能够避免被其它需要使用相同文件的用户或者系统进程所打断。当该进程执行完毕后,锁定文件将会删除。

     所以:

          1:移除对应目录下的锁文件:

          2:强制重新配置软件包:

          3:更新软件包源文件:

    rm /var/lib/dpkg/lock dpkg —configure -a apt update

    卸载VMwaretool

    /usr/bin/vmware-uninstall-tools.pl