dpkg hangs with no information on corrpted /var/lib/dpkg/info/*.list file

Bug #369898 reported by Mark A. Hershberger on 2009-04-30
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
dpkg (Ubuntu)
Low
Unassigned

Bug Description

Binary package hint: dpkg

I'm struggling with a filesystem that was corrupted by a kernel problem (reported seperately). Some files did not survive an fsck correctly:

  $ sudo ls -ld /var/lib/dpkg/info/libical0.*
  p----w---- 1 proxy 4122 0 1970-01-10 16:48 /var/lib/dpkg/info/libical0.list

I don't expect dpkg to be able to do anything with this, but I would like to get some debugging information when trying to track this down. As it was, it was hanging on "(Reading database ..." with no other information available, no matter what level I set the debugging to.

It would be nice if dpkg could verify that a file was un-readable or not actually a file, etc before reading it.

Alternatively, a debugging level could be added so that every file under /var/lib/dpkg/info is printed as it is accessed. In this way, it would be easier to track down the problem since output would stall out on the bad file.

Raphaël Hertzog (hertzog) wrote :

I have prepared a small fix for this and queued it for later merge in upstream dpkg.

Changed in dpkg (Ubuntu):
importance: Undecided → Low
status: New → In Progress
Raphaël Hertzog (hertzog) wrote :

The fix has been committed upstream in commit c07f7fea4206bc002578b2032871c9f63457bde8.

Changed in dpkg (Ubuntu):
status: In Progress → Fix Committed
Launchpad Janitor (janitor) wrote :
Download full text (13.2 KiB)

This bug was fixed in the package dpkg - 1.16.3ubuntu1

---------------
dpkg (1.16.3ubuntu1) quantal; urgency=low

  * Merge with 1.16.3 from unstable:
    - Change the multiarch downgrade version checks in prerm/postrm
      from 1.16.2 to 1.16.0~ to reflect when multiarch landed in Ubuntu.
    - Migrate dpkg multiarch conffile (and other multi-arch-related
      conf settings) to the new DB with dpkg --add-architecture, but
      keep a copy of the old conffile if it was modified.
    - Out of paranoia, keep an option handler for foreign-architecture
      that informs people that they need to scrub their config files
      and upgrade, on the off chance that the above migration fails
      for some reason (this mitigates the chances of leaving users with
      a dpkg that fails to run due to a broken config).
  * Changes remaining from previous Ubuntu versions:
    - Add DPKG_UNTRANSLATED_MESSAGES environment check so that higher-level
      tools can get untranslated dpkg terminal log messages while at the
      same time having translated debconf prompts. This is useful for tools
      that hide the dpkg terminal by default and use apport for bug
      reporting with the untranslated error message.
    - Build-depend on gettext:any for cross-building support.
    - Apply patch from Steve McIntyre to special-case armhf/armel ELF
      objects in Shlibs/Objdump.pm, so we don't get incorrect deps.

dpkg (1.16.3) unstable; urgency=low

  [ Guillem Jover ]
  * Do not look for newline beyond the read buffer on dpkg-deb extract.
  * Check update-alternative name and link arguments for all commands.
    Closes: #665050
  * Check all dpkg-divert filename arguments to be absolute and to not
    contain newlines. Closes: #21722
  * Print errors while reading the file list files on a new line instead
    of just after the progress percentage. Closes: #552517
  * Document in dpkg-source(1) that patches for source format “3.0 (quilt)”
    are expected to apply without any fuzz. Closes: #666752
    Based on a patch by Luca Capello <email address hidden>.
  * Remove redundant -Wformat-security from default dpkg-buildflags, which
    is already implied by -Werror=format-security. Closes: #664964
    Suggested by Peter Eisentraut <email address hidden>.
  * Document in dpkg-query(1) that commands producing multiple paragraphs
    will preserve the order of the packages specified on the argument list.
  * Change start-stop-daemon --exec on GNU/Hurd, FreeBSD, NetBSD, OpenBSD
    and Solaris to check for executables matching device and inode numbers
    instead of filenames.
  * Change start-stop-daemon --name on GNU/Hurd to check the process' argv[1]
    in addition to argv[0], to handle both binaries and interpreted scripts.
    Reported by Mats Erik Andersson <email address hidden>.
  * Handle deb format versions as major.minor integers instead of strings or
    floats, the latter being susceptible to parsing errors depending on the
    current locale (although this was only affecting the old deb format).
  * Ignore the minor format version number for deb-split format, unifying
    the behaviour with the deb format.
  * Add support for an abitable containin...

Changed in dpkg (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers