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

Re: Recovering dpkg database



On Sat, Apr 21, 2001 at 10:49:20PM -0700, Joseph Carter wrote:
> From then on (sorry, I know of no other way) you will simply have to get a
> list of installed packages (dpkg --get-selections, you can use cut or sed
> and grep or something to cut the list down to just the ones you want) and
> feed the result to apt-get install..  If you do it cleverly, you can do it
> on one cmdline.

Actually, dpkg is likely not to want to install them. Answer:

apt-get clean
apt-get -d install `dpkg --get-selections | awk '$2 == "install" { print
$1 }'`
dpkg -i /var/cache/apt/archives/*.deb

This will force a reinstall. You just have to hope that upgraded
packages don't break on you.

-- 
Taral <taral@taral.net>
Please use PGP/GPG encryption to send me mail.
"Any technology, no matter how primitive, is magic to those who don't
understand it." -- Florence Ambrose

Attachment: pgpYw3bZoxzvA.pgp
Description: PGP signature


Reply to: