Subject: some notes about sysinst upgrades.... (-current 2001/03/24)
To: NetBSD-current Discussion List <current-users@NetBSD.ORG>
From: Greg A. Woods <woods@weird.com>
List: current-users
Date: 04/06/2001 18:56:42
I finally got around to trying sysinst to upgrade my test SS-1 that had
been running NetBSD/sparc-1.4.2.
My initial attempt to use sysinst resulted in an attempted core dump
right after I had approved its use of sd0 as the disk to upgrade.
Finally after getting around to mounting the DESTDIR partition from the
build machine, creating symlinks for /usr/libexec/ld.so*, and setting
LD_LIBRARY_PATH I tried running a non-stripped copy with gdb (also from
NFS) in hopes I could narrow the failure down to at least the right
function name.
Surprisingly it didn't fail again. (watched pots never boil over!)
Sysinst's full-screen output on a 9600bps serial console really sucks.
I'm not sure why it's so bad (it clears and repaints the whole screen
far too often, for example), but it can be rather painful even at
9600bps at times.
I'd forgotten to put kern.tgz in my binary/sets directory, but
thankfully sysinst allowed me to go on without caring. I thought I had
told it not to display filenames during the extract, but it did anyway....
In fact the rest of the upgrade went very smoothly, though it left /etc
in a bit more of a mess (well less "configured") than I expected. I can
live with the fact that sysinst just isn't smart enough to intuit how to
build a new /etc/rc.conf from the old mess, but there are a couple of
things that would have been very easy to do and would have
- there was no /etc/fstab (why didn't it just copy the original
from /etc.old?)
- /etc/hosts was missing all local entries. Merging /etc/hosts
should be a trivial job -- just get all the non-comment lines
from the old one and insert them in the new one unless there
is one of the same hostname already there.
- there was no configuration for the network interface (probalby
because I had manually configured the network before running
sysinst), but why didn't it just copy /etc.old/ifconfig.le0 to
/etc? (/etc/resolv.conf was updated, though it may have been
updated from the miniroot copy and not from /etc.old -- the
latter would have been correct!)
- Adding previously existing local users and groups should
really be done by sysinst too -- perhaps in the same way as
/etc/hosts should be done by just adding every name that
doesn't exist and warning about duplicate ID#s....
Hmmm.... I wonder how hard would it be to keep a copy of the old
/etc/rc.conf default settings for 1.3.x and 1.4.x inside tables in
sysinst and write any new non-default entries to a new /etc/rc.conf?
It would also be nice if a full log of activities by sysinst was left on
the system drive (eg. in /root), and perhaps a wee README could be left
somewhere obvious too so that a naive user would know where to start to
finish re-integrating /etc.old changes and get the system back up and
running again.
Now if only I could figure out how I FUBAR'ed vipw....
--
Greg A. Woods
+1 416 218-0098 VE3TCP <gwoods@acm.org> <woods@robohack.ca>
Planix, Inc. <woods@planix.com>; Secrets of the Weird <woods@weird.com>