LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   rpm remove, but system says not installed (https://www.linuxquestions.org/questions/linux-newbie-8/rpm-remove-but-system-says-not-installed-580218/)

lonecrow 08-27-2007 01:43 PM

rpm remove, but system says not installed
 
This is what happens when I try to remove a rpm... can anybody tell me why?

Code:

[root@localhost matt]# rpm -ivh VMware-workstation-5.5.1-19175.i386.rpm
Preparing...                ########################################### [100%]
        package VMwareWorkstation-5.5.1-19175 is already installed
[root@localhost matt]# rpm -e VMware-workstation-5.5.1-19175.i386.rpm
error: package VMware-workstation-5.5.1-19175.i386.rpm is not installed
[root@localhost matt]#


acid_kewpie 08-27-2007 01:45 PM

you don't uninstall an installation file, you uninstall a package...

rpm -e VMware-workstation

would you try to uninstall "setup.exe" in windows?

b0uncer 08-27-2007 01:48 PM

You're not supposed to enter the full rpm name (including version and .rpm) when removing the package. rpm looks for the package by it's name, the version is automatically the latest because there usually can't be two same packages installed at the same time with different versions. So the correct command to remove would be
Code:

rpm -e VMware-workstation
In installation you need to provide the full package name of course, so rpm knows which file to work with, if you happened to have several files there for example. But with removal only the name is needed, rpm finds out the version information from it's database. If you use yum as your package manager, for example, you also don't use versions or .rpm in the package names, just the name part:
Code:

yum install VMware
and so on, provided that such a package existed in the yum reposities.

Code:

man rpm
man yum

yum applies to Fedora series, and to the other distributions that happen to use yum. The naming scheme is pretty common among package managers (use full filename to install single package, but only the name-part without version or .xxx when removing or using automated package management program).

lonecrow 08-27-2007 04:22 PM

Quote:

Originally Posted by acid_kewpie (Post 2872429)
you don't uninstall an installation file, you uninstall a package...

rpm -e VMware-workstation

would you try to uninstall "setup.exe" in windows?

Why does it tell me it is already installed then?

custangro 08-27-2007 04:26 PM

Do you know how to see if something is in the RPM database? Try:

Code:

rpm -qa | grep VMware

lonecrow 08-27-2007 04:37 PM

Quote:

Originally Posted by custangro (Post 2872584)
Do you know how to see if something is in the RPM database? Try:

Code:

rpm -qa | grep VMware

Yep already did

Code:

[root@localhost matt]# rpm -qa | grep VMware
VMwareWorkstation-5.5.1-19175


colucix 08-27-2007 05:06 PM

Actually, these work:
Code:

rpm -e VMware-workstation-5.5.1-19175.i386
rpm -e VMware-workstation-5.5.1-19175

and this not:
Code:

rpm -e VMware-workstation-5.5.1-19175.i386.rpm
Anyway, the normal usage is the one suggested above: you need only the package name (w/o version, w/o architecture, w/o extension). If you re-read posts from acid_kewpie and bOuncer, you already have the solution! ;)

reddazz 08-27-2007 05:18 PM

Quote:

Originally Posted by lonecrow (Post 2872592)
Yep already did

Code:

[root@localhost matt]# rpm -qa | grep VMware
VMwareWorkstation-5.5.1-19175


From that output, you could uninstall the rpm by doing
Code:

#rpm -e VMwareWorkstation
or using the version number as well
Code:

#rpm -e VMwareWorkstation-5.5.1-19175

acid_kewpie 08-28-2007 01:30 AM

Quote:

Originally Posted by lonecrow (Post 2872580)
Why does it tell me it is already installed then?

because you install a package FROM a file... e.g. you double click on setup.exe to install a windows program. that contains a package. sorry, but i'm not wrong...

lonecrow 08-28-2007 04:15 PM

Quote:

Originally Posted by acid_kewpie (Post 2872994)
because you install a package FROM a file... e.g. you double click on setup.exe to install a windows program. that contains a package. sorry, but i'm not wrong...

Im not saying you were wrong, but I just don't get it.

Here, Ive done as you said, dropping the .rpm, but im getting the same result, where:

Code:

[root@localhost matt]# rpm -ivh VMware-workstation-5.5.1-19175.i386.rpm
Preparing...                ########################################### [100%]
        package VMwareWorkstation-5.5.1-19175 is already installed
[root@localhost matt]# rpm -e VMware-workstation-5.5.1-19175.i386
error: package VMware-workstation-5.5.1-19175.i386 is not installed

...

stickman 08-28-2007 04:18 PM

Quote:

Originally Posted by b0uncer (Post 2872433)
You're not supposed to enter the full rpm name (including version and .rpm) when removing the package. rpm looks for the package by it's name, the version is automatically the latest because there usually can't be two same packages installed at the same time with different versions. So the correct command to remove would be
Code:

rpm -e VMware-workstation

That's not entirely correct. It is possible to have multiple versions of the same RPM on your system (ie kernel). In such cases, you need to be specific on which version you need to remove.

reddazz 08-28-2007 04:22 PM

Quote:

Originally Posted by lonecrow (Post 2873826)
Im not saying you were wrong, but I just don't get it.

Here, Ive done as you said, dropping the .rpm, but im getting the same result, where:

Code:

[root@localhost matt]# rpm -ivh VMware-workstation-5.5.1-19175.i386.rpm
Preparing...                ########################################### [100%]
        package VMwareWorkstation-5.5.1-19175 is already installed
[root@localhost matt]# rpm -e VMware-workstation-5.5.1-19175.i386
error: package VMware-workstation-5.5.1-19175.i386 is not installed

...

Did you try what I suggested above?

acid_kewpie 08-28-2007 04:22 PM

as stated clearly quite a few times now, the package is called "VMware-workstation" or "VMware-workstation-5.5.1-19175" it even says it right there in the output you pasted in... "package VMwareWorkstation-5.5.1-19175 is already installed" . please read the replies fully in future. thanks...

[whoops, slight mistake from me there of course... it's VMwareWorkstation not VMware-workstation. i'll leave my typo in place for everyone elses amusement! :D]

lonecrow 08-28-2007 07:12 PM

Thanks Redazz, usefull and diplomatic (not like everyone :O) as usual!

this:

Code:

rpm -e VMwareWorkstation
indeed worked out! In the future, I do I know how to spell the name correctly? meaning, how did you came up with "VMwareWorkstation" instead of "VMware-Workstation" or "vmwareworkstation"...?

Thanks very much!

acid_kewpie 08-29-2007 02:12 AM

as above, it was written in the output you pasted to us in the first place. it fair to say that in 99.9% of other occasions it's just the first part of the file name. seems odd that vmware deviated from that.


All times are GMT -5. The time now is 05:14 AM.