LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Red Hat (https://www.linuxquestions.org/questions/red-hat-31/)
-   -   Can rpm packages be over installed? (https://www.linuxquestions.org/questions/red-hat-31/can-rpm-packages-be-over-installed-731342/)

maitrey 06-08-2009 12:21 AM

Can rpm packages be over installed?
 
I have two rpm packages:
1)ns-2.0.0.0-0.dl.web.rpm.bin
2)ns-2.0.0.0-0.dl.rcd.rpm.bin
If I install ns-2.0.0.0-0.dl.web.rpm.bin it installs succesfully and after that if I install this ns-2.0.0.0-0.dl.rcd.rpm.bin this also installs successfuly
When I do a rpm -qa | grep ns
It shows both the packages
I want to have an over installation . How do I prevent the existence of both the packages?

unSpawn 06-08-2009 05:29 AM

Quote:

Originally Posted by maitrey (Post 3566469)
I want to have an over installation .

Do you mean you want to reinstall the packages?


Quote:

Originally Posted by maitrey (Post 3566469)
How do I prevent the existence of both the packages?

Like it sez in the Metallica lyrics:
Not dead which eternal lie
Stranger eons death may die

Drain you of your sanity

Uninstall The Thing That Should Not Be.

maitrey 06-08-2009 11:21 PM

No I donot want to reinstall. I install one package and without uninstalling the !st package I want to install the 2nd one. At a time I want only the existence of a single package.

Valery Reznic 06-09-2009 02:16 AM

Quote:

Originally Posted by maitrey (Post 3567555)
No I donot want to reinstall. I install one package and without uninstalling the !st package I want to install the 2nd one. At a time I want only the existence of a single package.

You mean, that when you install second package first one should be uninstalled ?

In this case Obsolete: tag should help

colucix 06-09-2009 02:38 AM

Quote:

Originally Posted by maitrey (Post 3567555)
No I donot want to reinstall. I install one package and without uninstalling the !st package I want to install the 2nd one. At a time I want only the existence of a single package.

What is the reason for this? If the two rpm contains different files you have to keep them both. If they contain the same files, just install the second one, since it will overwrite the first one that will result completely unnecessary.

unixmen 06-09-2009 04:42 PM

maybe you mean .
rpm -Uvh and not rpm -ivh

on this way you will install 2 versions of the same package

maitrey 06-09-2009 11:16 PM

How to use the Obsolete tag?I am new to making rpm packages.Can anyone elaborate with an example?

Valery Reznic 06-10-2009 12:11 AM

Quote:

Originally Posted by maitrey (Post 3568713)
How to use the Obsolete tag?I am new to making rpm packages.Can anyone elaborate with an example?

In the spec file of the package foo put
Code:

Obsolete: bar
In the spec file for package bar put
Code:

Obsolete: foo
Somewhere I saw recommendation to use it as
Code:

Obsolete: bar
Conflict: bar

and

Code:

Obsolete: foo
Conflict: foo

But I don't remember reason for using Conflict tag


All times are GMT -5. The time now is 02:33 AM.