Invalid lock on rpmdb?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Folks

I have a problem with rpmdb.  "rpm -v --rebuilddb"  hangs with:
"warning: waiting for transaction lock on /var/lib/rpm/__db.000"

The file /var/lib/rpm/__db.000 is zero in size:
[morgan@morgansmachine ~]$ stat /var/lib/rpm/__db.000
  File: `/var/lib/rpm/__db.000'
  Size: 0               Blocks: 8          IO Block: 4096   regular
empty file
Device: fd00h/64768d    Inode: 1009003     Links: 1
Access: (0644/-rw-r--r--)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2007-01-02 10:45:00.000000000 +1300
Modify: 2006-12-30 23:07:08.000000000 +1300
Change: 2006-12-30 23:07:08.000000000 +1300
[morgan@morgansmachine ~]$

Can I replace "__db.000" with any of the other files (__db.001,
__db.001, ..., etc)?
Is there a lock file somewhere I can delete?

Yum update hangs with:
"rpmdb: lock_downgrade: Lock is no longer valid"

History:
- I used yumex to remove a package (yum-fedorakmod), and it hung with
python at 100% cpu (more or less).
- I couldn't kill python, so rebooted.
- I used yum to remove the package, it was already removed
- I ran "yum update", it hung (as above)
- I ran "yum clean all"; it failed with "TypeError: rpmdb open failed"
- I ran "rpm -v --rebuilddb"; it hung

Any help on how to fix would be very much appreciated.  I'm just leaving
everything running until I sort this as I figure things might be a
little unstable.  Below, is output of the rebuiilddb, update and clean
commands.

Thanks,
Morgan.

[root@morgansmachine ~]# rpm -v --rebuilddb
warning: waiting for transaction lock on /var/lib/rpm/__db.000
...
Ctrl-C
########################

...
Downloading Packages:
(1/137): caching-nameserv 100% |=========================|  53 kB    00:00
(2/137): wireshark-gnome- 100% |=========================| 544 kB    00:04
(3/137): multisync-0.91.0 100% |=========================|  28 kB    00:00
(4/137): pinentry-0.7.2-1 100% |=========================|  56 kB    00:00
(5/137): swig-1.3.31-0.fc 100% |=========================| 3.0 MB    00:25
(6/137): bash-3.1-9.fc5.1 100% |=========================| 1.8 MB    00:15
(7/137): initscripts-8.31 100% |=========================| 1.2 MB    00:10
(8/137): php-ldap-5.1.6-1 100% |=========================|  31 kB    00:00
(9/137): GConf2-2.14.0-2. 100% |=========================| 1.5 MB    00:12
(10/137): perl-String-CRC 100% |=========================|  13 kB    00:00
(11/137): libpcap-0.9.4-3 100% |=========================| 208 kB    00:01
(12/137): dbus-sharp-0.62 100% |=========================|  52 kB    00:00
(13/137): libopensync-plu 100% |=========================|  20 kB    00:00
(14/137): nss-devel-3.11. 100% |=========================| 218 kB    00:01
(15/137): xine-lib-1.1.2- 100% |=========================| 2.5 MB    00:21
(16/137): openssh-askpass 100% |=========================|  36 kB    00:00
(17/137): fontconfig-deve 100% |=========================| 164 kB    00:00
(18/137): jwhois-3.2.3-8. 100% |=========================|  95 kB    00:00
(19/137): gtk-gnutella-0. 100% |=========================| 2.1 MB    00:18
(20/137): cpuspeed-1.2.1- 100% |=========================|  22 kB    00:00
(21/137): xterm-213-2.fc5 100% |=========================| 404 kB    00:02
(22/137): audit-libs-pyth 100% |=========================|  46 kB    00:00
(23/137): fontconfig-2.3. 100% |=========================| 188 kB    00:01
(24/137): parted-1.8.1-1. 100% |=========================| 537 kB    00:04
(25/137): ImageMagick-6.2 100% |=========================| 3.1 MB    00:26
(26/137): id3lib-3.8.3-15 100% |=========================| 397 kB    00:03
(27/137): libvte-java-0.1 100% |=========================|  70 kB    00:00
(28/137): librsync-0.9.7- 100% |=========================|  45 kB    00:00
(29/137): avahi-glib-0.6. 100% |=========================|  13 kB    00:00
(30/137): wpa_supplicant- 100% |=========================| 204 kB    00:01
(31/137): rdiff-backup-1. 100% |=========================| 294 kB    00:02
(32/137): openssh-server- 100% |=========================| 251 kB    00:01
(33/137): systemtap-runti 100% |=========================|  14 kB    00:00
(34/137): libgconf-java-2 100% |=========================|  70 kB    00:00
(35/137): dvd+rw-tools-7. 100% |=========================| 116 kB    00:00
(36/137): tar-1.15.1-17.F 100% |=========================| 745 kB    00:05
(37/137): bind-libs-9.3.3 100% |=========================| 828 kB    00:06
(38/137): nspr-4.6.4-0.5. 100% |=========================| 117 kB    00:01
(39/137): bind-9.3.3-0.2. 100% |=========================| 952 kB    00:07
(40/137): libopensync-plu 100% |=========================|  25 kB    00:00
(41/137): libopensync-dev 100% |=========================|  19 kB    00:00
(42/137): dbus-x11-0.62-0 100% |=========================|  21 kB    00:00
(43/137): libopensync-plu 100% |=========================|  35 kB    00:00
(44/137): spamassassin-3. 100% |=========================| 911 kB    00:07
(45/137): traceroute-2.0. 100% |=========================|  40 kB    00:00
(46/137): systemtap-0.5.1 100% |=========================| 664 kB    00:04
(47/137): system-config-h 100% |=========================| 661 kB    00:05
(48/137): tzdata-2006p-1. 100% |=========================| 451 kB    00:03
(49/137): avahi-0.6.11-2. 100% |=========================| 226 kB    00:01
(50/137): boost-1.33.1-10 100% |=========================| 855 kB    00:06
(51/137): libmpd-0.12.0-3 100% |=========================|  41 kB    00:00
(52/137): php-5.1.6-1.2.i 100% |=========================| 3.6 MB    00:29
(53/137): audit-libs-1.3- 100% |=========================|  35 kB    00:00
(54/137): libopensync-plu 100% |=========================| 464 kB    00:03
(55/137): wpa_supplicant- 100% |=========================|  50 kB    00:00
(56/137): lame-libs-3.97- 100% |=========================| 329 kB    00:06
(57/137): gmpc-0.13.0-1.f 100% |=========================| 185 kB    00:01
(58/137): autofs-4.1.4-33 100% |=========================| 325 kB    00:02
(59/137): snort-2.6.1.1-4 100% |=========================| 1.3 MB    00:11
(60/137): libgtk-java-2.8 100% |=========================| 2.0 MB    00:17
(61/137): perl-DBD-MySQL- 100% |=========================| 148 kB    00:00
(62/137): libopensync-plu 100% |=========================| 3.6 kB    00:00
(63/137): system-config-u 100% |=========================| 333 kB    00:02
(64/137): gamin-python-0. 100% |=========================|  55 kB    00:00
(65/137): boost-devel-1.3 100% |=========================| 4.3 MB    00:36
(66/137): GConf2-devel-2. 100% |=========================| 191 kB    00:01
(67/137): mysql-server-5. 100% |=========================|  10 MB    01:26
(68/137): libEMF-1.0.3-3. 100% |=========================|  88 kB    00:01
(69/137): java-1.4.2-gcj- 100% |=========================| 2.4 MB    00:20
(70/137): nagios-2.6-1.fc 100% |=========================| 2.1 MB    00:18
(71/137): openal-0.0.9-0. 100% |=========================| 149 kB    00:01
(72/137): dbus-devel-0.62 100% |=========================|  36 kB    00:00
(73/137): ImageMagick-c++ 100% |=========================| 143 kB    00:01
(74/137): wine-core-0.9.2 100% |=========================| 8.7 MB    01:17
(75/137): thunderbird-1.5 100% |=========================|  21 MB    02:59
(76/137): nfs-utils-1.0.8 100% |=========================| 220 kB    00:02
(77/137): libsepol-1.15.1 100% |=========================| 148 kB    00:00
(78/137): mikmod-3.1.6-37 100% |=========================| 200 kB    00:01
(79/137): pyparted-1.8.1- 100% |=========================|  24 kB    00:00
(80/137): fontforge-20061 100% |=========================| 5.9 MB    00:52
(81/137): gdm-2.14.11-1.f 100% |=========================| 3.6 MB    00:29
(82/137): xmms-modplug-2. 100% |=========================|  54 kB    00:00
(83/137): dbus-glib-0.62- 100% |=========================| 110 kB    00:00
(84/137): system-config-d 100% |=========================| 1.2 MB    00:09
(85/137): libopensync-plu 100% |=========================| 3.2 kB    00:00
(86/137): python-devel-2. 100% |=========================| 3.0 MB    00:25
(87/137): bind-utils-9.3. 100% |=========================| 161 kB    00:01
(88/137): xine-0.99.4-8.l 100% |=========================| 1.6 MB    00:21
(89/137): elinks-0.11.0-2 100% |=========================| 1.0 MB    00:08
(90/137): audit-1.3-2.fc5 100% |=========================| 221 kB    00:01
(91/137): sendmail-8.13.8 100% |=========================| 630 kB    00:05
(92/137): libdvdread-0.9. 100% |=========================|  66 kB    00:00
(93/137): python-2.4.3-9. 100% |=========================| 5.9 MB    00:49
(94/137): desktop-printin 100% |=========================| 103 kB    00:00
(95/137): xine-lib-extras 100% |=========================| 619 kB    00:11
(96/137): qt-3.3.7-0.1.fc 100% |=========================| 3.5 MB    00:29
(97/137): dbus-0.62-0.2.f 100% |=========================| 631 kB    00:04
(98/137): texinfo-4.8-9.2 100% |=========================| 776 kB    00:06
(99/137): cvs-1.11.22-6.f 100% |=========================| 735 kB    00:05
(100/137): kdelibs-3.5.5- 100% |=========================|  18 MB    02:36
(101/137): lame-3.97-2.lv 100% |=========================| 328 kB    00:02
(102/137): nspr-devel-4.6 100% |=========================| 111 kB    00:00
(103/137): info-4.8-9.2.f 100% |=========================| 164 kB    00:00
(104/137): checkpolicy-1. 100% |=========================| 254 kB    00:01
(105/137): cups-1.2.5-1.f 100% |=========================| 2.8 MB    00:23
(106/137): pstoedit-3.44- 100% |=========================| 459 kB    00:04
(107/137): wireshark-0.99 100% |=========================| 7.8 MB    01:07
(108/137): kudzu-devel-1. 100% |=========================| 190 kB    00:01
(109/137): soundconverter 100% |=========================|  58 kB    00:00
(110/137): arts-1.5.5-0.1 100% |=========================| 1.1 MB    00:08
(111/137): cups-libs-1.2. 100% |=========================| 176 kB    00:01
(112/137): libgsf-1.13.3- 100% |=========================| 111 kB    00:00
(113/137): gamin-0.1.7-1. 100% |=========================| 117 kB    00:00
(114/137): frysk-0.0.1.20 100% |=========================| 6.8 MB    00:58
(115/137): imlib2-1.3.0-3 100% |=========================| 577 kB    00:05
(116/137): tcpdump-3.9.4- 100% |=========================| 444 kB    00:03
(117/137): gnupg2-1.9.22- 100% |=========================| 565 kB    00:03
(118/137): firefox-1.5.0. 100% |=========================|  17 MB    02:30
(119/137): gdesklets-0.35 100% |=========================| 768 kB    00:06
(120/137): openssh-4.3p2- 100% |=========================| 279 kB    00:01
(121/137): openssh-client 100% |=========================| 435 kB    00:03
(122/137): multisync-gui- 100% |=========================|  36 kB    00:00
(123/137): libopensync-pl 100% |=========================|  25 kB    00:00
(124/137): libopensync-0. 100% |=========================| 748 kB    00:06
(125/137): nautilus-cd-bu 100% |=========================| 414 kB    00:02
(126/137): xsane-gimp-0.9 100% |=========================| 243 kB    00:01
(127/137): nss-3.11.4-0.5 100% |=========================| 760 kB    00:06
(128/137): dbus-python-0. 100% |=========================| 133 kB    00:00
(129/137): at-3.1.8-82.fc 100% |=========================|  55 kB    00:00
(130/137): wv-1.2.4-1.fc5 100% |=========================| 265 kB    00:02
(131/137): tkinter-2.4.3- 100% |=========================| 278 kB    00:01
(132/137): xsane-0.991-4. 100% |=========================| 1.8 MB    00:14
(133/137): gnupg-1.4.6-1. 100% |=========================| 1.8 MB    00:15
(134/137): kudzu-1.2.34.5 100% |=========================| 402 kB    00:02
(135/137): mysql-5.0.27-1 100% |=========================| 3.3 MB    00:27
(136/137): evince-0.5.1-4 100% |=========================| 773 kB    00:05
(137/137): libgsf-devel-1 100% |=========================| 203 kB    00:01
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Updating  : bash                         ##################### [  1/269]
  Updating  : python                       ##################### [  2/269]
  Updating  : dbus                         ##################### [  3/269]
  Updating  : info                         ##################### [  4/269]
  Updating  : GConf2                       ##################### [  5/269]
  Updating  : libopensync                  ##################### [  6/269]
  Updating  : fontconfig                   ##################### [  7/269]
  Updating  : initscripts                  ##################### [  8/269]
  Updating  : audit-libs                   ##################### [  9/269]
  Updating  : dbus-glib                    ##################### [ 10/269]
  Updating  : nspr                         ##################### [ 11/269]
  Updating  : qt                           ##################### [ 12/269]
  Updating  : cups-libs                    ##################### [ 13/269]
  Updating  : ImageMagick                  ##################### [ 14/269]
  Updating  : nss                          ##################### [ 15/269]
  Updating  : libpcap                      ##################### [ 16/269]
  Updating  : arts                         ##################### [ 17/269]
  Updating  : mysql                        ##################### [ 18/269]
  Updating  : libgtk-java                  ##################### [ 19/269]
  Updating  : bind-libs                    ##################### [ 20/269]
  Updating  : xine-lib                     ##################### [ 21/269]
  Updating  : libopensync-devel            ##################### [ 22/269]
  Updating  : libgsf                       ##################### [ 23/269]
  Updating  : gamin                        ##################### [ 24/269]
  Updating  : perl-DBD-MySQL               ##################### [ 25/269]
  Updating  : wireshark                    ##################### [ 26/269]
  Updating  : openssh                      ##################### [ 27/269]
  Updating  : librsync                     ##################### [ 28/269]
  Updating  : libgconf-java                ##################### [ 29/269]
  Updating  : ImageMagick-c++              ##################### [ 30/269]
  Updating  : cups                                               [
31/269]warning: /etc/cups/mime.types created as /etc/cups/mime.types.rpmnew
  Updating  : cups                         ##################### [ 31/269]
  Updating  : nspr-devel                   ##################### [ 32/269]
  Updating  : dbus-python                  ##################### [ 33/269]
  Updating  : avahi                        ##################### [ 34/269]
  Updating  : pinentry                     ##################### [ 35/269]
  Updating  : dbus-x11                     ##################### [ 36/269]
  Updating  : boost                        ##################### [ 37/269]
  Updating  : libsepol                     ##################### [ 38/269]
  Updating  : parted                       ##################### [ 39/269]
  Updating  : kdelibs                      ##################### [ 40/269]
  Updating  : bind                         ##################### [ 41/269]
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: DB_LOCK->lock_put: Lock is no longer valid
error: db4 error(22) from dbcursor->c_close: Invalid argument
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: DB_LOCK->lock_put: Lock is no longer valid
error: db4 error(22) from dbcursor->c_close: Invalid argument
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: DB_LOCK->lock_put: Lock is no longer valid
error: db4 error(22) from dbcursor->c_close: Invalid argument
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
rpmdb: lock_downgrade: Lock is no longer valid
##########################

[morgan@morgansmachine ~]$ sudo yum clean all
rpmdb: lock_downgrade: Lock is no longer valid
error: cannot open Packages index using db3 - Invalid argument (22)
error: cannot open Packages database in /var/lib/rpm
Traceback (most recent call last):
  File "/usr/bin/yum", line 29, in ?
    yummain.main(sys.argv[1:])
  File "/usr/share/yum-cli/yummain.py", line 80, in main
    base.getOptionsConfig(args)
  File "/usr/share/yum-cli/cli.py", line 177, in getOptionsConfig
    self.doConfigSetup(fn=opts.conffile, root=root)
  File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 102, in
doConfigSetup
    self.conf = config.readMainConfig(fn, root)
  File "/usr/lib/python2.4/site-packages/yum/config.py", line 589, in
readMainConfig
    vars['releasever'] = _getsysver(earlyconf.installroot,
earlyconf.distroverpkg)
  File "/usr/lib/python2.4/site-packages/yum/config.py", line 689, in
_getsysver    idx = ts.dbMatch('provides', distroverpkg)
TypeError: rpmdb open failed
[morgan@morgansmachine ~]$

-- 
Morgan Read
NEW ZEALAND
<mailto:mstuffATreadDOTorgDOTnz>

fedora: Freedom Forever!
http://fedoraproject.org/wiki/Overview

"By choosing not to ship any proprietary or binary drivers, Fedora does
differ from other distributions. ..."
Quote: Max Spevik
       http://interviews.slashdot.org/article.pl?sid=06/08/17/177220


Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux