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

Re: How to recover after unintentional 'dpkg --unpack' ? (was ... Re: Dpkg SNAFU was Re: Oops!)



Patrick Bartek wrote:
> > > have resulted in Gnome being install, too.  More or less.  So I
> > > just did as root in /root a 'dpkg --download,' and then an
> > > '--unpack' thinking that would uncompress the .deb file in /root
> > > from which I would get the single svg file I needed, and then just

The command you were looking for was 'dpkg-deb -x foo.deb foo-dir'.

> > > delete everything else.  Simple. Right?  Wrong. Now, I'm stuck with
> > > about 4.5 megs of Gnome data, icons,
> 
> Fortunately --unpack just "installed" files to their appropriate
> directories, but didn't "trigger" or configure anything.  Not all that
> up on dpkg. Have always used apt-get.

After a dpkg --unpack the package will be listed like this:

  Desired=Unknown/Install/Remove/Purge/Hold
  | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
  |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
  ||/ Name  Version  Architecture Description
  +++-=====-========-============-===========
  iU  foo  2.5-1  amd64  Foo description

That says installed but unpacked.  A long dpkg --status would show:

  Status: install ok unpacked

> If I don't hear anything bad to the contrary in the next day or so, I'm
> just going to use "--purge" to remove the package after creating
> a copy of the file I need in a safe directory, then copy the copy back
> after the purging.  Hopefully, it will work.

That is the correct thing to do.  The dpkg package manager knows the
state of the installation.  Simply tell it to purge the package.
Simple!  No need to look any further.

  dpkg --purge foo

Bob

Attachment: signature.asc
Description: Digital signature


Reply to: