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

Re: getting /bin files for debian unstable x86



"Karsten M. Self" wrote:
> > >> $400 USD cost more than my computer cost
> > >
> > >Completely irrelevant.
> > >
> >
> > I wish I could say that. I'm a student I don't have extra cash.
> 
> This and your other responses are largely irrelevant.  Bordering on
> tiresome.  System administration, like economics, is about the
> allocation of scarce resources (time, money, hardware, available
> storage, memory, processing power) to providing services you desire.

Many students are more concerned with having enough money to feed
themselves, after paying the rent and University fees. They are most
certainly not concerned with having adequate backup facilities.

Certainly our strangely-named friend was rather careless when he
accidently rm'd the files in /bin, but telling him to give up eating for
a month to allow him to buy a CD-R drive is not helping the current
situation.


> > Then I thought if unstable had a simple tgz file with
> > the base OS then maybe I could easily extract it in winzip and then
> > just copy over the files without fuss or muss.
> >
> > Unfortunately some wonderfully gifted person decided that unstable
> > didn't need a disk section or even a base install and so therefore I
> > don't have access to this easy medium.

As has already been mentioned in another post, unstable doesn't have a
disk or base section because it isn't even close to being released yet.
It wasn't a 'decision by some wonderfully gifted person', it is just the
order of things.


My procedure for recovery in your case would be:

1. Download toms root/boot (http://www.toms.net/rb/). It is possible to
install this onto a floppy from a Windows system, if that's all you have
access to at the moment.

2. Download the packages that were listed in one of Karsten's posts. If
you do this under windows, it will probably ruin the filenames (at
least, I remember it doing so to me once). It shouldn't be a problem.

3. Boot with the tomsrtbt disk you've made, mount your linux partition
and copy the downloaded deb packages to it somewhere (preferably a
temporary directory, ie not /bin or /usr/bin etc.).*

4. Extract the files from the debian packages. Debian packages are 'ar'
archives, which you can extract with 'ar x <filename>'. This will result
in a few files, including a data.tar.gz file which will contain the
binaries you're after.

5. Extract the binaries from the data.tar.gz file. This file contains
paths relative to the root directory, so a bin subdirectory should
appear which will contain the files you need. If you know a little shell
scripting you could automate the whole process of unpacking the packages
and expanding the data.tar.gz, which would leave you with a bin
directory containing everything you need, which you can just copy to the
real /bin.


* How to get the debian packages onto your machine is left as an
exercise to the reader. I don't know what resources you have available
to you.


When you've recovered your system, edit /root/.bashrc and add the line:

alias rm="rm -i"

This should at least allow you to bail out if you accidently do an rm
somewhere you shouldn't. I'd also make sure that this alias always gets
defined by adding this to your .profile:

if [ -f .bashrc ]; then
	. .bashrc
fi

On my potato system, these lines were already in those files, but were
commented out.


Matthew



Reply to: