Re: How to restore /bin?
On Tue, Mar 14, 2006 at 05:32:46PM +1100, Paul Dwerryhouse wrote:
> On Tue, Mar 14, 2006 at 03:02:17PM +1100, John O'Hagan wrote:
> > To my surprise, most things seem to be working; but I'm wondering if I
> > can expect problems, and if there's a way of restoring /bin to the
> > correct state for an up-to-date testing system?
>
> I wouldn't want to leave it in that state.
>
> Probably the most reliable way to fix it would be to apt-get --reinstall
> every package. Maybe like this:
>
> apt-get --reinstall install `dpkg --get-selections | awk '{print $1}'`
Don't run that...
> A less bandwidth-wasteful way of doing it would be to figure out which
> packages had files in /bin and only reinstall those. You can find this
> out by looking at the *.list files in /var/lib/dpkg/info/
Run this:
apt-get --reinstall install \
$(cd /var/lib/dpkg/info; grep -l '^/bin/' *.list|sed 's/.list$//')
Reply to: