[SOLVED] Package manager hangs during RPM install

General support questions including new installations
evanb
Posts: 5
Joined: 2010/09/06 05:10:25
Location: Orange County, California, US

[SOLVED] Package manager hangs during RPM install

Post by evanb » 2010/09/06 05:54:28

I just installed 32-bit CentOS 5.5 in a Vmware virtual machine. I'm unable to install RPMs from either the graphical U/I (Pirut) or CLI (Yum). Pirut stops responding (no screen repainting) after displaying the "Updating software" dialog; Yum gets to the display of "Running Transaction" where it hangs. The initial installation (from the net-install ISO) obviously succeeded, and the after-install update of about 50 packages also worked fine.

yum.log contains nothing past the entries made during the initial install. Because I had a problem with corrupted files from a mirror during installation I tried using the baseurl setting in CentOS-Base.repo instead of mirrorlist, but that had no effect.

Any ideas?

-evan

User avatar
toracat
Forum Moderator
Posts: 7299
Joined: 2006/09/03 16:37:24
Location: California, US
Contact:

[SOLVED] Package manager hangs during RPM install

Post by toracat » 2010/09/06 07:02:39

Try running yum with a high debugging level using the -d flag. For example, [b]yum -d6 update[/b] .

evanb
Posts: 5
Joined: 2010/09/06 05:10:25
Location: Orange County, California, US

Re: Package manager hangs during RPM install

Post by evanb » 2010/09/06 07:26:39

[quote]
toracat wrote:
Try running yum with a high debugging level using the -d flag. For example, [b]yum -d6 update[/b] .[/quote]
Here's the whole comversation w/ -d6 set:
[code]Loading "fastestmirror" plugin
Config time: 0.041
Yum Version: 3.2.22
Setting up Package Sacks
Loading mirror speeds from cached hostfile
* addons: centos.mirror.facebook.net
* base: mirrors.versaweb.com
* extras: mirror.nwresd.org
* updates: dist1.800hosting.com
pkgsack time: 5.853
rpmdb time: 0.000
Setting up Install Process
Building updates object
up:Obs Init time: 0.175
up:simple updates time: 0.030
up:obs time: 0.002
up:condense time: 0.000
updates time: 0.726
Resolving Dependencies
There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them.
The program yum-complete-transaction is found in the yum-utils package.
--> Running transaction check
---> Package yum-utils.noarch 0:1.1.16-14.el5.centos.1 set to be updated
Checking deps for yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
looking for ('yum', 'GE', ('0', '3.2.19', '16')) as a requirement of yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
looking for ('python', 'GE', ('0', '2.4', None)) as a requirement of yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
looking for ('/usr/bin/python', None, (None, None, None)) as a requirement of yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
--> Finished Dependency Resolution
Dependency Process ending
Depsolve time: 1.254

Dependencies Resolved

================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
yum-utils noarch 1.1.16-14.el5.centos.1 base 69 k

Transaction Summary
================================================================================
Install 1 Package(s)
Upgrade 0 Package(s)

Total download size: 69 k
Is this ok [y/N]: y
Downloading Packages:
yum-utils-1.1.16-14.el5.centos.1.noarch.rpm | 69 kB 00:00
Running rpm_check_debug
Member: yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
Adding Package yum-utils-1.1.16-14.el5.centos.1.noarch in mode u
rpm_check_debug time: 0.017
Running Transaction Test
Member: yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
Adding Package yum-utils-1.1.16-14.el5.centos.1.noarch in mode u
Finished Transaction Test
Transaction Test Succeeded
Transaction Test time: 0.196
Member: yum-utils.noarch 0-1.1.16-14.el5.centos.1 - u
Adding Package yum-utils-1.1.16-14.el5.centos.1.noarch in mode u
Running Transaction
[/code] (Yes, ironically enough I'm trying to install yum-complete-transaction to finish up the install pirut left behind.)

As an additional data point: I rebooted the VM, then immediately ran pirut to install Firefox. That install, which had failed any number of times before the reboot, worked. Thinking my problem was solved I tried the development tool install that was my original goal. That hung as before, though, so the problem remains.

-evan

evanb
Posts: 5
Joined: 2010/09/06 05:10:25
Location: Orange County, California, US

Re: Package manager hangs during RPM install

Post by evanb » 2010/09/06 07:53:24

Now that I have Firefox installed I am able to download getinfo.sh, so here's the output of getinfo.sh package:

http://pastebin.centos.org/34748

-evan

User avatar
toracat
Forum Moderator
Posts: 7299
Joined: 2006/09/03 16:37:24
Location: California, US
Contact:

Re: Package manager hangs during RPM install

Post by toracat » 2010/09/06 07:59:19

It looks like you do indeed need to run yum-complete-transaction. You can download yum-utils manually and then install it using rpm like so:

[code]
wget http://mirror.centos.org/centos/5/os/i386/CentOS/yum-utils-1.1.16-14.el5.centos.1.noarch.rpm
rpm -Uvh yum-utils-1.1.16-14.el5.centos.1.noarch.rpm
[/code]

evanb
Posts: 5
Joined: 2010/09/06 05:10:25
Location: Orange County, California, US

Re: Package manager hangs during RPM install

Post by evanb » 2010/09/06 09:01:35

[quote]It looks like you do indeed need to run yum-complete-transaction.[/quote]More data: I did the manual download, and when I first ran rpm it hung after printing a warning that it was waiting for a lock on /var/lib/rpm/__db.000. I killed it, deleted the __db.000 file and reran the rpm command line, which then successfully completed the install of yum-utils. Now I can run yum-complete-transaction, and it gets as far as "Running Transaction Test" before it hangs.

I noticed that, each time I ran yum-complete-transaction, the time stamps on the __db.001, __db.002 and __db.003 files in /var/lib/rpm would change, but that of __db.000 would not. I deleted all four files, and 001 through 003 were recreated as soon as I ran y-c-t. 000 was not, and y-c-t hung at "Running Transaction Test" again. So far, nothing has recreated __db.000.

I tried running y-c-t both with yum-updatesd started and with it stopped. yum-updatesd running or not made no difference.

-evan

h_fat
Posts: 48
Joined: 2007/04/13 17:23:48

Re: Package manager hangs during RPM install

Post by h_fat » 2010/09/06 10:17:20

I'm not saying this has got anything to do with your problem but aren't we supposed to rebuild the files you deleted with rpm --rebuilddb or rpm --initdb?

User avatar
TrevorH
Forum Moderator
Posts: 23669
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Package manager hangs during RPM install

Post by TrevorH » 2010/09/06 13:26:25

On the original problem, rpm (and probably yum too) will hang if there is an inaccessible mounted filesystem - e.g. an NFS mount that is stuck.

evanb
Posts: 5
Joined: 2010/09/06 05:10:25
Location: Orange County, California, US

Re: Package manager hangs during RPM install

Post by evanb » 2010/09/09 03:16:05

[quote]
h_fat wrote:
I'm not saying this has got anything to do with your problem but aren't we supposed to rebuild the files you deleted with rpm --rebuilddb or rpm --initdb?[/quote]I think this is what fixed it. Running pirut/yum after deleting the files recreated __db.001-003, but only after --rebuilddb did anything actually work. I suspect that I was bitten by some bad RPMs from some of the mirrors. I did the install over 3-4 times before getting through without an error, and the errors were usually a file being corrupt or inaccessible.

Thanks for the help. Now on to the next problem :)

pschaff
Retired Moderator
Posts: 18276
Joined: 2006/12/13 20:15:34
Location: Tidewater, Virginia, North America
Contact:

Re: [SOLVED] Package manager hangs during RPM install

Post by pschaff » 2010/09/09 13:03:01

Thanks for reporting back. Marking this thread [SOLVED] for posterity.

Post Reply