LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-05-2012, 05:44 PM   #1
john@ackley.net
LQ Newbie
 
Registered: Mar 2005
Location: Virgin Islands
Distribution: Red Hat 9.0
Posts: 13

Rep: Reputation: 0
yum - how to re-install a package


CentOS 6.3
I have broken install (some executable files accidently overwritten)

I tried:
<code>
yum erase wine
yum install wine
</code>
does not restore missing files

how to erase a package and re-install?

yum erase wine
leaves all the executable files in place
 
Old 08-05-2012, 06:56 PM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,308

Rep: Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744
Code:
yum reinstall wine
http://linux.die.net/man/8/yum ?
Alternatively, try 'yum clear all', then reinstall, or http://hacktux.com/yum/force/reinstall ?
Just be careful & take a good backup before you start.

You might even find that if you've managed to erase part of wine, the a 'yum update wine' will work.
 
Old 08-05-2012, 07:04 PM   #3
john@ackley.net
LQ Newbie
 
Registered: Mar 2005
Location: Virgin Islands
Distribution: Red Hat 9.0
Posts: 13

Original Poster
Rep: Reputation: 0
thanks
goes through the motions
but no luck


"wine" is one of the executable needing replacement

Installed:
wine.x86_64 0:1.2.3-1.el6

Complete!
[root@paradise bin]# ls -l wine*
-rw-r--r--. 1 root root 0 Aug 5 19:59 wine
-rwxr-xr-x. 1 root root 1055376 Apr 11 2011 wine64
-rwxr-xr-x. 1 root root 1582 Apr 11 2011 wineboot
-rwxr-xr-x. 1 root root 1582 Apr 11 2011 winecfg
. . .
 
Old 08-05-2012, 07:06 PM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,308

Rep: Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744
Remove those files by hand; it should then notice the problem when you try to install/reinstall it.
 
Old 08-05-2012, 07:10 PM   #5
john@ackley.net
LQ Newbie
 
Registered: Mar 2005
Location: Virgin Islands
Distribution: Red Hat 9.0
Posts: 13

Original Poster
Rep: Reputation: 0
http://hacktux.com/yum/force/reinstall

same lack of result
 
Old 08-05-2012, 07:16 PM   #6
john@ackley.net
LQ Newbie
 
Registered: Mar 2005
Location: Virgin Islands
Distribution: Red Hat 9.0
Posts: 13

Original Poster
Rep: Reputation: 0
deleted /usr/bin/wine*

yum reinstall wine
. . .
Installed:
wine.x86_64 0:1.2.3-1.el6

Complete!

[root@paradise bin]# ls wine*
ls: cannot access wine*: No such file or directory
[root@paradise bin]#

[root@paradise bin]# pwd
/usr/bin
 
Old 08-05-2012, 07:42 PM   #7
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,308

Rep: Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744
Odd; did you do a 'yum clean all' each time as well?
Basically you have to remove the SW AND remove the entries in the rpm DB (which underlies yum).
you can also try
Code:
rpm -qa|grep -i wine

#then
rpm -e <wine rpms mentioned above>
drastic but effective & do another 'yum clean all' afterwards before re-installing or 'updating'.
You could also do this immediately after the 'rpm -e ...'
Code:
rpm --rebuilddb
http://linux.die.net/man/8/rpm
 
Old 08-05-2012, 08:09 PM   #8
john@ackley.net
LQ Newbie
 
Registered: Mar 2005
Location: Virgin Islands
Distribution: Red Hat 9.0
Posts: 13

Original Poster
Rep: Reputation: 0
SOLVED!
this did it!
thanks!

rpm -qa|grep -i wine

#then
rpm -e <wine rpms mentioned above>


some minor problems with order of removal

finally an endless loop:

[root@paradise ~]# rpm -qa | grep -i wine
wine-core-1.2.3-1.el6.x86_64
wine-common-1.2.3-1.el6.noarch
[root@paradise ~]# rpm -e wine-core-1.2.3-1.el6.x86_64
error: Failed dependencies:
wine-core = 1.2.3-1.el6 is needed by (installed) wine-common-1.2.3-1.el6.noarch
[root@paradise ~]# rpm -e wine-common-1.2.3-1.el6.noarch
error: Failed dependencies:
wine-common = 1.2.3-1.el6 is needed by (installed) wine-core-1.2.3-1.el6.x86_64

each dependent on the other
none the less after "yum install wine"
wine seems to be working again
although now a short list of wine* in /usr/bin
???
 
Old 08-05-2012, 08:43 PM   #9
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,308

Rep: Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744Reputation: 2744
Glad to help.
Maybe a short list is all you need there, or some of it is installed elsewhere.
You can use
Code:
yum info wine\*
yum search wine\*
to get more detailed info.
See also the home site www.winehq.org
 
  


Reply

Tags
reinstalling, yum


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Cant install Virtual machine in CentOS 6 Cannot find package qemu-kvm in yum install linux_rhca Linux - Newbie 4 10-19-2011 05:37 AM
Unable to install package through yum troelskn Red Hat 5 04-27-2009 08:42 AM
yum package install lensem Linux - Server 5 11-14-2008 03:29 AM
[SOLVED] Use yum to install package. brave heart Red Hat 9 09-06-2007 02:51 AM
Using YUM to install a package bwallace Linux - Newbie 2 02-21-2006 09:43 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:18 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration