Thursday, January 22, 2009

手动删除VMware-Player完全指南

今天安装了VMware-Player,但是Windows底下做的RHEL5系统不能打开,因此想要把它卸载了,但是我想着直接安装VMware Workstation应该就会自动删除了吧,谁知不但不自动删除,还因为在安装VW的时候第一个题是选项里点了no,因此不小心把VMware-Player的安装DB给删掉了,这下惨了,得手动删除了。后悔阿,其实如果没删除db的话用sudo vmware-uninstall.pl就可以删除,可是...后来在网上找了不多久问题就解决了,给出来以免以后再遇到同样的问题,同时也方便大家。

1、先用新立德找所有能找到的含有关键字“vmware”的包,注意看看地下的注释,不要删错了,如果实在不确定先不要删。

2、由于错误提示是:
The following VMware kernel modules have been found on your system that were
not installed by the VMware Installer. Please remove them then run this
installer again.

vmmon
vmblock
vmnet

Execution aborted.
因此我们的主要任务是删掉vmmon vmblock vmnet这三个kernel modules。因此先将这几个文件删除:

查找:
# find /lib/modules/ | grep vmmon
找到的文件夹类似于:
/lib/modules/2.6.24-23-generic/misc/
这里面还有6个需要删除的modules 每个kernel module都是有两个分别以 ".o" 和 ".ko" 结尾的文件,删除这几个文件:
# rm /lib/modules/2.6.24-23-generic/misc/vm*
这时由于我没有测试,应该就能重新安装VMware-player或者安装新的VMware虚拟机了。
如果还不可以或者需要完全卸载的话责需要找出所有的vmware文件:
# find / -name vmware
一般一个文件夹里都含有几个vmware安装时生成的文件,或者一个vmware目录的上层有几个vm开头的文件。只要分别删除找到的文件就可以了。

由于还要学习,时间不多,就粗略写一下把,请触类旁通。

最后给出我刚删除了VP后安装VW的日志,希望那些想要完全删除VP的人能用的上(我第一次安装失败了,因为没有删除/tmp里面的几个vmware关联的文件夹):

icnpunk:~/Desktop/vmware-distrib$ sudo ./vmware-install.pl
A previous installation of VMware Workstation has been detected.

The previous installation was made by the tar installer (version 4).

Keeping the tar4 installer database format.

Uninstalling the tar installation of VMware Workstation.

Stopping VMware services:
Virtual machine monitor done
Bridged networking on /dev/vmnet0 done
Host network detection done
DHCP server on /dev/vmnet1 done
Host-only networking on /dev/vmnet1 done
DHCP server on /dev/vmnet8 done
NAT service on /dev/vmnet8 done
Host-only networking on /dev/vmnet8 done
Virtual ethernet done

The removal of VMware Workstation 6.0.5 build-109488 for Linux completed
successfully. Thank you for having tried this software.

Installing VMware Workstation.

In which directory do you want to install the binary files?
[/usr/bin]

What is the directory that contains the init directories (rc0.d/ to rc6.d/)?
[/etc]

What is the directory that contains the init scripts?
[/etc/init.d]

In which directory do you want to install the daemon files?
[/usr/sbin]

In which directory do you want to install the library files?
[/usr/lib/vmware]

The path "/usr/lib/vmware" does not exist currently. This program is going to
create it, including needed parent directories. Is this what you want?
[yes]

In which directory do you want to install the manual files?
[/usr/share/man]

In which directory do you want to install the documentation files?
[/usr/share/doc/vmware]

The path "/usr/share/doc/vmware" does not exist currently. This program is
going to create it, including needed parent directories. Is this what you want?
[yes]

The installation of VMware Workstation 6.0.5 build-109488 for Linux completed
successfully. You can decide to remove this software from your system at any
time by invoking the following command: "/usr/bin/vmware-uninstall.pl".

Before running VMware Workstation for the first time, you need to configure it
by invoking the following command: "/usr/bin/vmware-config.pl". Do you want
this program to invoke the command for you now? [yes]

Making sure services for VMware Workstation are stopped.

Stopping VMware services:
Virtual machine monitor done
Bridged networking on /dev/vmnet0 done
Host network detection done
DHCP server on /dev/vmnet1 done
Host-only networking on /dev/vmnet1 done
DHCP server on /dev/vmnet8 done
NAT service on /dev/vmnet8 done
Host-only networking on /dev/vmnet8 done
Virtual ethernet done

Configuring fallback GTK+ 2.4 libraries.

In which directory do you want to install the theme icons?
[/usr/share/icons]

What directory contains your desktop menu entry files? These files have a
.desktop file extension. [/usr/share/applications]

In which directory do you want to install the application's icon?
[/usr/share/pixmaps]

Trying to find a suitable vmmon module for your running kernel.

None of the pre-built vmmon modules for VMware Workstation is suitable for your
running kernel. Do you want this program to try to build the vmmon module for
your system (you need to have a C compiler installed on your system)? [yes]

Using compiler "/usr/bin/gcc". Use environment variable CC to override.

What is the location of the directory of C header files that match your running
kernel? [/lib/modules/2.6.24-23-generic/build/include]

Extracting the sources of the vmmon module.

Building the vmmon module.

Using 2.6.x kernel build system.
make: Entering directory `/tmp/vmware-config0/vmmon-only'
make -C /lib/modules/2.6.24-23-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.24-23-generic'
CC [M] /tmp/vmware-config0/vmmon-only/linux/driver.o
CC [M] /tmp/vmware-config0/vmmon-only/linux/hostif.o
CC [M] /tmp/vmware-config0/vmmon-only/common/comport.o
CC [M] /tmp/vmware-config0/vmmon-only/common/cpuid.o
CC [M] /tmp/vmware-config0/vmmon-only/common/hash.o
CC [M] /tmp/vmware-config0/vmmon-only/common/memtrack.o
CC [M] /tmp/vmware-config0/vmmon-only/common/phystrack.o
CC [M] /tmp/vmware-config0/vmmon-only/common/task.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciContext.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciDatagram.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciDriver.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciDs.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciGroup.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciHashtable.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciProcess.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciResource.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmciSharedMem.o
CC [M] /tmp/vmware-config0/vmmon-only/common/vmx86.o
CC [M] /tmp/vmware-config0/vmmon-only/vmcore/moduleloop.o
LD [M] /tmp/vmware-config0/vmmon-only/vmmon.o
Building modules, stage 2.
MODPOST 1 modules
CC /tmp/vmware-config0/vmmon-only/vmmon.mod.o
LD [M] /tmp/vmware-config0/vmmon-only/vmmon.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.24-23-generic'
cp -f vmmon.ko ./../vmmon.o
make: Leaving directory `/tmp/vmware-config0/vmmon-only'
The module loads perfectly in the running kernel.

/dev is dynamic:
Trying to find a suitable vmblock module for your running kernel.

None of the pre-built vmblock modules for VMware Workstation is suitable for
your running kernel. Do you want this program to try to build the vmblock
module for your system (you need to have a C compiler installed on your
system)? [yes]

Extracting the sources of the vmblock module.

Building the vmblock module.

Using 2.6.x kernel build system.
make: Entering directory `/tmp/vmware-config0/vmblock-only'
make -C /lib/modules/2.6.24-23-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.24-23-generic'
CC [M] /tmp/vmware-config0/vmblock-only/linux/block.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/control.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/dbllnklst.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/dentry.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/file.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/filesystem.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/inode.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/module.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/stubs.o
CC [M] /tmp/vmware-config0/vmblock-only/linux/super.o
LD [M] /tmp/vmware-config0/vmblock-only/vmblock.o
Building modules, stage 2.
MODPOST 1 modules
CC /tmp/vmware-config0/vmblock-only/vmblock.mod.o
LD [M] /tmp/vmware-config0/vmblock-only/vmblock.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.24-23-generic'
cp -f vmblock.ko ./../vmblock.o
make: Leaving directory `/tmp/vmware-config0/vmblock-only'
Unable to make a vmblock module that can be loaded in the running kernel:
insmod: error inserting '/tmp/vmware-config0/vmblock.o': -1 File exists
There is probably a slight difference in the kernel configuration between the
set of C header files you specified and your running kernel. You may want to
rebuild a kernel based on that directory, or specify another directory.

The vmblock module enables dragging or copying files from within a guest and
dropping or pasting them onto your host (guest to host drag and drop and file
copy/paste). The rest of the software provided by VMware Workstation is
designed to work independently of this feature (including host to guest drag
and drop and file copy/paste).

If you would like the guest to host drag and drop and file copy/paste features,
you can install the driver by running vmware-config.pl again after making sure
that gcc, binutils, make and the kernel sources for your running kernel are
installed on your machine. These packages are available on your distribution's
installation CD.
[ Press Enter key to continue ]

/dev is dynamic:
You have already setup networking.

Would you like to skip networking setup and keep your old settings as they are?
(yes/no) [yes]

Trying to find a suitable vmnet module for your running kernel.

None of the pre-built vmnet modules for VMware Workstation is suitable for your
running kernel. Do you want this program to try to build the vmnet module for
your system (you need to have a C compiler installed on your system)? [yes]

Extracting the sources of the vmnet module.

Building the vmnet module.

Using 2.6.x kernel build system.
make: Entering directory `/tmp/vmware-config1/vmnet-only'
make -C /lib/modules/2.6.24-23-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.24-23-generic'
CC [M] /tmp/vmware-config1/vmnet-only/driver.o
CC [M] /tmp/vmware-config1/vmnet-only/hub.o
CC [M] /tmp/vmware-config1/vmnet-only/userif.o
CC [M] /tmp/vmware-config1/vmnet-only/netif.o
CC [M] /tmp/vmware-config1/vmnet-only/bridge.o
CC [M] /tmp/vmware-config1/vmnet-only/filter.o
CC [M] /tmp/vmware-config1/vmnet-only/procfs.o
CC [M] /tmp/vmware-config1/vmnet-only/smac_compat.o
SHIPPED /tmp/vmware-config1/vmnet-only/smac_linux.x386.o
LD [M] /tmp/vmware-config1/vmnet-only/vmnet.o
Building modules, stage 2.
MODPOST 1 modules
WARNING: could not find /tmp/vmware-config1/vmnet-only/.smac_linux.x386.o.cmd for /tmp/vmware-config1/vmnet-only/smac_linux.x386.o
CC /tmp/vmware-config1/vmnet-only/vmnet.mod.o
LD [M] /tmp/vmware-config1/vmnet-only/vmnet.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.24-23-generic'
cp -f vmnet.ko ./../vmnet.o
make: Leaving directory `/tmp/vmware-config1/vmnet-only'
The module loads perfectly in the running kernel.

Do you want to install the Eclipse Integrated Virtual Debugger? You must have
the Eclipse IDE installed. [no]

The file /etc/rc2.d/S90vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc2.d/K08vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc3.d/S90vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc3.d/K08vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc5.d/S90vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc5.d/K08vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc0.d/K08vmware that this program was about to install already
exists. Overwrite? [yes]

The file /etc/rc6.d/K08vmware that this program was about to install already
exists. Overwrite? [yes]

Creating a new VMware VIX API installer database using the tar4 format.

Installing VMware VIX API.

You must read and accept the VMware VIX API End User License Agreement to
continue.
Press enter to display it.
\*内容省略*\

Do you accept? (yes/no) yes

Thank you.

In which directory do you want to install the VMware VIX API binary files?
[/usr/bin]

In which directory do you want to install the VMware VIX API library files?
[/usr/lib/vmware-vix/lib]

The path "/usr/lib/vmware-vix/lib" does not exist currently. This program is
going to create it, including needed parent directories. Is this what you want?
[yes]

In which directory do you want to install the VMware VIX API document pages?
[/usr/share/doc/vmware-vix]

The path "/usr/share/doc/vmware-vix" does not exist currently. This program is
going to create it, including needed parent directories. Is this what you want?
[yes]

The installation of VMware VIX API 1.1.5 build-109488 for Linux completed
successfully. You can decide to remove this software from your system at any
time by invoking the following command: "/usr/bin/vmware-uninstall-vix.pl".

Starting VMware services:
Virtual machine monitor done
Virtual ethernet done
Bridged networking on /dev/vmnet0 done
Host network detection done
Host-only networking on /dev/vmnet1 (background) done
DHCP server on /dev/vmnet1 done
Host-only networking on /dev/vmnet8 (background) done
DHCP server on /dev/vmnet8 done
NAT service on /dev/vmnet8 done

The configuration of VMware Workstation 6.0.5 build-109488 for Linux for this
running kernel completed successfully.

You can now run VMware Workstation by invoking the following command:
"/usr/bin/vmware".

Enjoy,

--the VMware team


Copyright © 2006 - 2009 iCNPunk.BlogSpot.COM All rights reserved By ZerOnenOreZ & Blogger
Template Designed By iCNPunk Fixed for IE7