Subject: Re: sysinst problems
To: Greywolf <greywolf@starwolf.com>
From: Greg A. Woods <woods@weird.com>
List: port-sparc
Date: 12/04/2004 02:22:53
[ On Friday, December 3, 2004 at 21:12:02 (-0800), Greywolf wrote: ]
> Subject: Re: sysinst problems
>
> "Make it an option."  I reserve the right to tell the system that "I
> know what the hell I'm doing".

But in this specific case (and no doubt in many others like it, but
we'll leave them out of this for now) there is no valid reason possible
to store random half-baked cryptic "notes" as overlapping partitions in
an in-use disklabel to _anyone_, not even yourself, but _especially_ not
to anyone who might try to figure out what you meant from the resulting
bizarre and "broken" configuration.

I.e. there is no sense, logic, or value to creating unnecessary and
confirmably dangerous overlapping partitions, and there's not even any
way to record arbitrary notes in the label as future hints as to why
this broken mess was created in the first place.

Meanshile you've likely got every information recording tool available
to man, from sticks drawing in the sand to other high-tech modern
computer disks, and everything in between, to store the information you
say you want to store without having to mess up an otherwise perfectly
elegant stand-alone disklabel.  I.e. You really do not need to try to
store your notes about alternate configurations in some hap-hazzard
incomplete way in the same disklabel you are trying to use!


> GAW: Well you're definitely not thinking outside the box on this one!  ;-)
> 
> Beg pardon?

You're thinking inside the little box disklabel has created for you.

Think outside the box.  Put pen to paper, even!!!!  Or printer.  I'd
suggest a piece of tape to secure that paper to the physical drive too,
just so it doesn't get lost!  You don't know when you might need it!  ;-)
Write it with a permanent marker right on the HBA cover if you don't
have pen and paper and tape handy!  And if you don't have a writing
instrument of any kind available, well then "Step Away From the
Computer, slowly now and keep your hands up in full view!"  :-)


> GAW: then that begs the question of how a
> GAW: tool designed and used primarily for the building of new boxes could
> GAW: possibly be preventing you from maintaining your old existing boxes with
> GAW: their existing disklabels.
> 
> Well, apparently, it does, from what der Mouse has reported.

I'm not convinced, though I didn't read his message that carefully and
I've since deleted it and I'm too lazy to find and read an archived copy
of it at this time of night (if indeed the mailing list archiver has
even caught up to it yet).

But from the source we can see that at the point where sysinst first
finds, checks, and mounts the target systems filesystems, upgrade.c
reads:

        if (find_disks() < 0)
                return;

        if (md_pre_update() < 0)
                return;

        /* if we need the user to mount root, ask them to. */
        if (must_mount_root()) {
                msg_display(MSG_pleasemountroot, diskdev, diskdev, diskdev);
                process_menu(MENU_ok);
                return;
        }

        if (!fsck_disks())
                return;

There's no checking of the disklabel as far as I can see -- the last
function call simply causes the specified root of the target device to
be mounted and then for it's etc/fstab file to be consulted and for the
filesystems mentioned within to be checked with fsck and finally for
them all to be mounted.

The "use existing" option to a full re-install from scratch will be
another thing entirely, but with it one can easily argue that one is
building a "new box" and so if one's using the hand-holding tools then
one must expect the sanity of one's figures to be checked!


> Or is it assumed that "True Experts" don't need to run the installer?

Indeed they probably do not __BUT__ I would go much further and argue
that "True Experts(tm)" have well and enough experience to not even try
to do anything that's inherently dangerous, even if the software doesn't
warn them.  That's certainly my philosophy of how to best use one's
experience.

Every time anyone argues to me that the software should have some flag
to allow some "expert" to override some built-in sanity and safety
checks then I really do have to question whether that person really does
have the experience to know what they're asking for and to use such a
feature without causing problems.

To put it very bluntly, yes I now there's no way to stop someone who's
truly dedicated to their course of action and who really does know how
to do what they wnat to do from straying from their desired course of
action, no matter what they're trying to do, but that's still no excuse
for tying the noose for them, so to speak -- if they're that dedicated
and that "expert" then they don't need anyone's handholding help to get
where they want to go.

> (Heck, I forget MAKEDEV sometimes on a by-hand install.  Anything you
> can forget, I have, at one point or other.)

Exactly my point.  (and me too!)

If you want to hand-craft a "broken" disklabel and trick the kernel into
storing it and using what you specify to control the behaviour of the
disk device nodes then that's your business and nobody's going to stop
you -- go nuts!

However please do not use that as a very poor excuse for saying that
tools intended for lesser experts to use should have options to allow
them to be used to do similarly invalid and incorrect and possibly even
dangerous things.  The tool is not ever going to have a psychic "I'm
being used by a True Expert" detector and so if your argument is so
compelling then it is in fact really only an argument to completely
remove the sanity checks (or at least turn them off by default) -- and
how sane is that?

This particular example of using overlapping partitions to remember
something that is much safer to "remember" in some other form is a
perfect "classic example" of where self-proclaimed experts who are
trying to override the rules really cannot be as "expert" as they claim
if indeed their reasons are simply to remember alternate configruations
and/or to save typing one simple command, especially not when they
advocate making their "break the rules" options generally available.

Sorry to put it so bluntly but I'm just trying to get y'all to wake up
and smell the coffee here!  There's never been any real and demonstrable
and logical true need to _ever_ use overlapping disk partitions (other
than those standard "whole disk" kinds of things of course).  On the
face of it they're nothing but confusing bits of junk information.
There are a gazillion billion trillion simpler and safer ways to record
the same information so it can be used when and where necessary and in a
non-conflicting manner.  As for that potential excuse of one command
being "saved", well it is not even on the horizon of justifying an
option to turn off the sanity checks.

With relation to this issue I can say that one thing I've learned from
my 20 years of almost daily sysadmin activities is that putting helpful
scraps of incomplete information in places where one hopes they might
eventually be of use is not wise.  Either do it right and record
everything in sufficient detail, and in a human-readable format in a
human accessible place, such that it can be deciphered accurately from
first principles, or don't leave any hints at all, especially when those
hints will cause mistakes if they're misinterpreted.  Unused
non-standard overlapping disk partitions can only ever mislead once
their original purpose is not fresh in mind, or has never been known.

If you've got systems in that state now then that's fine, but please
don't try to suggest that new software should be silent about the
confusion you've created for it.  Clean them up if you have time and
before you try to use new software with them, or just leave everything
well enough alone.

-- 
						Greg A. Woods

+1 416 218-0098                  VE3TCP            RoboHack <woods@robohack.ca>
Planix, Inc. <woods@planix.com>          Secrets of the Weird <woods@weird.com>