Subject: Re: Can't boot any of my Macs
To: None <port-macppc@netbsd.org>
From: David Burgess <burgess@neonramp.com>
List: port-macppc
Date: 08/01/2001 12:46:09
"Henry B. Hotz" wrote:
> 
> At 4:33 PM -0500 7/28/01, Dave Burgess wrote:
> >In OF, the screen looks fine.  When I try to boot NetBSD off the .fs
> >floppy, it looks fine (for the few seconds the boot works).  In MacOS,
> >it's unreadable.
> 
> I'm really surprised there's a difference between OF and netbsd on
> this hardware.  They both drive the same fixed frequency output and I
> didn't think netbsd had the capability of changing the output
> frequencies, yet.
> 

Success!  On to the Good News:

Here are the steps I had to take:

1)  Get permission from Apple to put up a 'dd' version of the Disk 
Tools diskette.  Almost all of the problem I had early on were the lack 
of a PC/Unix tool friendly boot disk.  Without this step, all the 
rest of the stuff in the FAQ is (almost) useless.

2)  Get this MacOS bootable disk onto a floppy.

3)  Update the firmware and set up Open Firmware to stop.  Without
access to MacOS, this would be step 1, but the method changes to
"hook up a PC to the serial port and type the following:"

Note that the terminals I tried (a VT-102 and a VT-220) did not support
the 38400 terminal speed that the Mac uses.

4)  Put that disk away for a while.

5)  Get one of the old install disks (I grabbed from from 2000).

6)  Put that on a floppy and boot from that.

7)  Don't bother trying to install.

8)  Put in the 1.5.1 install floppy.

9)  Power cycle the machine.  The machine will now boot from the
floppy that I couldn't get working during the previous week.  I
happened to have a 'bootable' CD (from which I couldn't boot)
with all of the 1.5.1 distribution stuff on it, so I used that
for the installation.

10)  Install NetBSD.

11)  Hook up the network and off we go.


> >On that 'Boot' thing.  When I try to boot NetBSD off the .fs floppy,
> >I get the normal copyright, kind of stuff that I associate with the
> >beginning of a kernel load.  Then, I usually get some kind of error
> >(DEVICE NOT SUPPORTED, I think) and I get dumped to a "Boot:"
> >prompt.  Nothing I do at this point is worth talking about.  The only
> >thing I found that I could do from that point was "exit".  Trying
> >to boot off the floppy wasn't satisfying.  The CD seems to just sit
> >there.
> 
> Can you do the normal "boot fd:0" thing to get into the installer at least?
> 

Not until I got the old installer.  Once I did that, the rest of 
the stuff went exactly the way I'd hoped it would.

I have absolutely no idea why.  I know the old installer didn't support
the 'mesh' card; perhaps there's something about that that's important.

> > > >4)  It is not possible to 'start' NetBSD without at least one working
> > > >computer already available.  Apparently, this working computer will
> > > >need to be a Mac as well.
> > >
> > > Actually I think you can do what you need to do from the iso CD-ROM
> > > if you never want to run MacOS.  Of course you need a working monitor
> > > if you don't want to run headless in netbsd.
> >
> >Eventually, that's exactly what I want to do.  I'm interested in this
> >as a showcase piece for NetBSD on my local network, not really for me
> >to use.  I already have enough computing power to find my own
> >extraterrestrials - this is more of an exercise to see how the other
> >half lives....
> >

Point 4 above still holds true.  Without access to Mac, this entire 
process is challenging (as it stands right now).

The bridge is a real filesystem image of an acceptable boot image
that can be processed using PC or Unix tools.

I talked to Apple on the phone, and while they don't support putting
a boot image for 7.5 up on the Internet somewhere, they aren't 
opposed to people passing these around amongst ourselves.  They used
to have an image available on their web site, but have since pulled 
it down.  Even then, it assumed a MacOS system to build the floppy.

> > > c) Use nvedit to fix up nvramrc.  There are instructions off the FAQ
> > > somewhere.  It's a bit tedious, but not hard.  You'll want the wBoot
> > > patch and the video patch.  The other patches aren't needed on a
> > > [78]500 in my experience.  7600 should be the same.  Sometimes you
> > > get lucky and don't need the video patch for a particular machine,
> > > but don't count on it.
> >
> >How do I get 'nvedit' to the machine?  I can't see it on the
> >Disk Tools disk, and I don't have any way to put it onto a MacOS floppy
> >that I'm aware of.  This is the crux of the problems I've been having.
> >With no way to modify a MacOS floppy, I can't get the machine to a
> >state where I can boot-strap the files.
> 
> That's what's neat about Open Firmware.  nvedit is part of the
> standard; it's already in the ROM and you don't even need to have
> *any* OS running to use it.  I'm sure there is a pointer off the FAQ
> on this, but basically you:
> 
> 1) get into OF somehow.
> 2) type nvedit
>         Now you are in a one-line emacs editor operating on the Forth
> program stored in nvramrc.  You can ctl-n, ctl-p, etc. to modify that
> program as you see fit.  Type ctl-c to quit.  Your changes are not
> saved to the actual nvramrc until you type either nvsave or nvstore
> (I forget which).
>         Don't delete everything from nvramrc unless you also set
> use-nvramrc? to false.  I killed my machine that way once, and had to
> remove my G3 upgrade and the battery to get it back.
>         If you are using a serial port to another machine to run OF
> then you could cut/paste the patches from the web page.  They aren't
> too long to put in by hand though.
>

As I've said so often since this started:

"D'Oh"
 
> > > e) "boot scsi-int/sd@3:0,ofwboot.xcf netbsd.macppc" with the real
> > > genuine NetBSD iso CD-ROM in the drive.  Accept no substitutes!
> > > (Actually for this machine you can use a vanilla ISO 9660 CD-ROM, but
> > > I'd suggest you use the NetBSD image anyway.)
> >
> >I tried that.  There is at least one place that says all of the names
> >need to be in upper case, but several other sources don't.  Also, I
> >get an error that basically claims "no such beast" whenever I try this.
> 
> I myself have posted on both sides of this question.  My current
> belief is that you can use lower case in the boot command as above,
> but there may be circumstances when case does matter.  By all means
> use upper case if you can stand to type it.
> 

:-)

Now that I've gotten it to boot the first time, I've been able to
boot 'pretty much' at will.

> 
> > > f)  Allow sysinst to format your disk.  This will replace the Apple
> > > Partition Map with a dummy one that can boot the machine and put a
> > > native NetBSD disklabel on the disk.  If you don't have/want MacOS
> > > then sysinst is your friend.  (Otherwise it's kind of a pain because
> > > it won't partition the disk the way I want.)
> >
> >Cool.  This was good news.   This is where I eventually want to be.
> 
> What you probably really want to do is have two disks on a machine.
> The big one gets this treatment.  A little one gets set up as a
> bootable MacOS disk.
> 

This, by the way, is where I am right now.  I've loaded the disk with
the tgz files from the web site and have unloaded them all.


> Perhaps you should try to get an older version of the Disk Tools
> floppy?  Or, better if you have a small MacOS disk (as suggested
> above) then format it; drag the entire contents of the disk tools
> floppy to it;  and boot from it.  Then you don't need to eject your
> boot disk and everything may work OK.  Then you also don't need to
> worry about netbsd reformatting the other disk.
> 

I was having a real conceptual problem with this.  As it turns out, 
it's not required.  NetBSD is loaded and I can almost boot from the
hard drive.

THe problem I'm having now is that the 1.5.1 kernel is locking up
during load.  I can't say precisely why or where (I'm not at that
computer) but it does it on every kernel image I've tried for 1.5.1.
It would help if I knew what the boot-up memory map meant.

If stops at something like 

0000000+[000000+0000000

Where the last number is 10000, I think.  I've got more resources I
can apply to that problem, though, so I'll just keep at that one.


> >To run programs on a $25 laptop?  Seriously, the only reason I got the
> >laptop was because I couldn't retract my bid.  If it ends up holding up
> >one corner of another computer, I wouldn't be too upset.  Of course, I
> >had to buy at $85 battery for the $25 computer to even get it to the point
> >where I could test it.
> >
> >I'll save that for a time when I'm a little happier with Macintosh
> >hardware.
> 
> I'm still recovering from the boot disk size restrictions imposed by
> the PC bios standards.  Yuk!!  I'm a firm believer in not
> partitioning disks because it's the single most time-consuming thing
> a SA ever has to do.  You never know how your needs will change.
> Here you have to have this tiny boot partition that also has to be
> root?  All because of some 20-year-old software interface that you
> can't change because there isn't anyone that owns the standard?
> 

Yeah, that is a problem.  It, unfortunately, is a model that's both 
historical and well understood.  This model goes back to the roots
of MS-DOS and it's natural similarity to CP/M.  The current OSes 
(Windows 2000, for example) still uses the 'load the first sector
off the boot drive' model that was established by CP/M and other
systems before that.

> I got a PC to run netbsd on without having to reboot my wife's Mac,
> but I'll think real hard about it before doing that again.  In other
> words we both have our biases on hardware.  ;-)
>

That's not exactly the problem.  I"m not unhappy about the Mac
hardware.  I'm unhappy about the way the process to get the OS
loaded required the OS to be loaded.  Hopefully, I can fix some
of that later.

This goes back to the Sperry/Burroughs Phase IV contract.  Sperrys'
hardware was great, but their software stunk.  Burroughs software 
was rock solid, but the hardware was put together with string and
spit.  I'm feeling the same way about the 'bootstrap' aspects of
the Mac.  I've never had trouble bootstrapping a PC.  This Mac,
on the other hand, had me stonewalled for a solid week.

> Personally I've always been incredulous that X never got good enough
> for Unix to boot in graphics mode instead of text mode.  Likewise the
> PC, at least until recently.  All that character lookup table stuff
> is extra hardware and complexity that the Mac has never had to carry
> around.
> 
> Now I will admit that I oversimplified my description above.  There
> has always been some text stuff hidden in the Mac.  Even the oldest
> 68k Mac's I dealt with had an assembly debugger that came up in a
> text window (note: window, as in the hardware was doing graphics)
> when you pushed the NMI button.  It was never properly documented
> AFAIK, and if you really wanted an assembly debugger then you loaded
> Motorola's MacsBug which wired itself into the same interrupt and was
> documented.
> 
> This is all ROM or software like Open Firmware, though.  Let me
> repeat:  there is *NO* hardware support for text.  AFAIK even the
> newest Mac's that use PCI or AGP cards borrowed from PC's make no use
> of any text modes that they may have.
> 

I'm going to look at this as I get deeper into this process.  There
has got to be some way to unknot this problem.