[conspire] Researching used hardware (was: mounting of drive to see ...)

Rick Moen rick at linuxmafia.com
Wed Feb 13 19:10:23 PST 2019


Quoting a recent CABAL attendee:

> Regarding bootability, I want to know WHY is became NOT bootable.

Happy hunting, then.  (Start by looking at ye olde GRUB configuration.)

> IF I were to reinstall it, I would want to make sure this problem didnt
> recur.

Aside from hardware failure (not applicable) or a scramble filesystem
(ditto), unbootability happens because someone or some piece of software
messed with the boot configuration.  So, Don't Do That, Then.

Even more important than understanding how it happened and (attempting
to) prevent anything scrambling boot configuration is knowing how to
repair boot configuration, towards which end it's extremely helpful to
(1) have followed the KISS principle in setting up booting and (2) 
remembering or being able to figure out what you did.

Here's a background fact:  GRUB 0.9x (sometimes called 'GRUB1') and, even
worse, GRUB2, are ridiculously overcomplicated and overfeatured, with the
result that they are much, much more difficult to master than was their
predecessor, lilo.  They are now predominant in x86 Linux distributions
_because_ they are overfeatured, allowing the  distro to tick all
possible checkboxes, e.g., boots on RAID1, encrypted root fs, etc.
Better-designed, modestly scoped, but still modern, bootloaders exist
(such as syslinux/extlinux), but are never installed by default.

So, you get to figure out a Rube Goldberg-like bootloader.  Whee!

Personally, I'd just bag that.

> Regarding LVM, I dont remember if I installed this machine or if I was
> given this machine.
> When you run a standard Linux install, it tries to default to LVM.
> You have to jump in at the right moment to over ride it to ext3 (my
> preference).

Moreover, sometimes the distro's partitioning routine blows chunks to
such a degree that the smartest move is to hit the Back control to 
get out of the partitioning screen, then type Ctrl-Alt-F2 to switch to a
different virtual console, and just start good ol' /sbin/fdisk and use
_it_ to create all your partitions.  Then, flip back into the
installer's screen (Ctrl-Alt-F1 if it's a console installer, probably
Ctrl-Alt-F7 if it's a graphical one), then skip partitioning except to
specify mountpoints for the partitions you created using /sbin/fdisk.
And, of course, you would want to mkfs the partitions there.


The partitioning screens in Red Hat's 'anaconda' installer (thus in
CentOS, RHEL, and Fedora) has for many long years been one of the 'blows
chunks' examples, though it is hardly alone.    The basic problem is
that it's been coded to override the administrator's choices by
rewriting the map to be created.  E.g., suddenly you notice that  the
pending filesystems are in a different order from the one you specified,
even though you wanted them in a specific order to keep disk seeking to
a minimum.  Or you specified four primary partitions, but then you see
that Anadonda has decided only the first should be primary, and the
other three should be logical drives inside an extended partition.
Maybe your view is different, but as a sysadmin I want software tools
that do what I say, not tools that decide to do something different
because they think I shouldn't want what I said should be done.

And yes, the 'set up LVM even though the administrator didn't ask for
it' bit is indeed, IIRC, part of the Anaconda partitioner's pattern of
unacceptable aberrant behaviour.  Since it's unacceptable, my advice is:
Don't accept it.  Move sideway to /sbin/fdisk or other preferred tool.
One way to do this is to keep around a best-of-breed live distribution
whose partitioning tools you like.  I personally prefer the 'No X'
variant of the Siduction live distro.  Some people like Knoppix for
this.  Views Differ.[tm]

Siduction is an example of a distro with a cutting-edge kernel that's
released frequently (in theory, quarterly), which means it reliably
supports even very new hardware.  Using the No X variant, or starting
one of the other variants without allowing X11 startup, means you can
use it as a maintenance disk even if the system has low total RAM.

The only thing that sucks about Siduction is omission of non-free
firmware, such that occasionally you must stop and fetch it before
Siduction can use a hardware driver you care about.   So, you end up
needing one or more of these and needing to 'dpkg -i' it into the
running Siduction host, or some silly drill like that:
https://manual.siduction.org/nf-firm#non-free-firmware


Basically, _before_ installing a distribution, you boot your favourite
maintenance distro on the target hardware, and use it to get the
partition maps the way you want.  (You could also do mkfs, then.)
Upon being done with that, reboot into the desired distro installer from
its own installation media.  _Much_ more reliable and satisfying.


> Ive got a stack of machines I dont know anything about and I need to sort
> through the stack.

Promising.  So, start by picking a maintenance distro, and install it to
a USB flash stick.  (You could also burn a copy to CD/DVD, but only
truly ancient machines lack ability to boot from USB.  CD/DVD optical
drives are almost entirely obsolete, today, because we have USB flash
drives that are far better for most use-cases.)

Armed with a bootable copy of your favourite maintenance distro, you 
can then inventory each machine in that stack and tape a sheet of paper
to each, saying what each has.

> If its really not going to work, then Ill rebuild it as an Open DOS machine.
> There are a number of apps including lighting and radio programming apps
> that depend on DOS.

Er... the machine has a gig of RAM.

The Pentium III server that (still) runs linuxmafia.com has only 1/2 GB
of RAM.

What really wants 8GB or 16GB and a CPU and motherboard from the latter
half of the 2010s is some of that laundry list of modern 'cloud' stuff
you said you wanted to do on it.  Like VM setups, containers, and that
sort of stuff.




> You decided to take me to task for sinking money into this thing...

Incorrect.  That is not what I said.

I wanted to warn you against doing so in case you were tempted.  Your
cue at this point would be to say 'Thanks.  Fortunately, I wasn't
tempted to make that mistake, but I appreciate your making sure I knew
it would be a poor investment.'


> Until Im working, Im not going to be buying $100 machines off craigslist.

Well, friend, then I think you're a little bit screwed in the short term
for doing experiments with VM setups, containers, and that
sort of stuff.  Because RAM.

Maybe you can get a working 8-16 GB RAM machine for free, but I doubt
it.    Usually what you get for free are 10-to-20-year-old machines 
(low RAM limits, often also 32-bit) and vast numbers of sticks of
low-density RAM.  The Bay Area is full of people who will be ecstatic to 
empty their drawers of those dusty 256MB sticks of SDRAM, handing them
to you, smiling and feeling virtuous.   Those went into the drawer
because they were a mistaken purchase, set aside during the inevitable
RAM upgrade, because useless.

Your best bet for free computers able to support modern 'cloud' stuff
would be 'pull' machines, ones big companies have pulled from service
in, e.g., a data centre or colo rack.  Of course, assuming you can scarf
a few of those before they've sat in a 'to be diagnosed' pile for a
decade, the gotcha is that they were always pulled because someone
suspected a significant hardware defect, which could be RAM defects, 
dodgy mass storage, motherboard overheating problems, and so on.  You
might come by a pile of 1U or 2U 'pulls', hope they haven't all been
stripped of useful parts, and see if you can assemble three or four 
100% good and modern machines out of ten broken ones.  But you need to 
furnish the time and diagnostic skills to separate good from bad.
The big company doesn't have the time and money to do hardware
diagnosis,   The suspect unit gets RMA'ed if it's still in warranty, and
just pulled if not.  Your jackpots will be units barely out of warranty
that may have little or possibly nothing wrong.  (Perfectly OK machines
are sometimes pulled because somebody made a mistake or confused a
software problem with a hardware one.)


> Please dont chastise people for things they havent done and havent
> stated that they plan to do.

Please read more carefully, and don't say I chastised when I merely
wanted to warn you of an error many people make so you won't be bitten
by it.  Otherwise, it makes it less likely I'd want to try to help.


Meanwhile, your reaction so far to my having spent several hours
researching Craigslist offerings in order to teach how to research
hardware -- the reaction where you don't even say 'thank you' -- aptly
illustrates why I made a point of posting that to a public mailing list
and not just into private mail, such as we are doing here:   Maybe _you_
aren't grateful or find that useful, but there's a good chance that
somebody reading the public post will.

Which point I will restate as my final point:  Michael P. said this
discussion should have already moved to one of the LUG mailing lists.
He's right.  Neither of us volunteered to do large amounts of
free-of-charge technical consulting.  And when you find yourself chewing
up Linux community leaders' time asking them private questions and
getting private help, it would be appreciated for you to realise "Oh, 
I don't want to abuse personal access to these guys, and should move to
a public forum so I don't come across as wanting free-of-charge personal
tutoring.'

Suggest any replies go to Conspire, as this private thread has gone past
reasonable limits.


In fact, screw it.  I'm moving this to public, where it should have been
at least one or two exchanges ago.




More information about the conspire mailing list