Subject: Booting from a Mac UFS partition
To: None <port-macppc@netbsd.org>
From: Rene Hexel <rh@netbsd.org>
List: port-macppc
Date: 07/12/2003 17:52:28
  I have been trying to set up my alubook to boot from a Mac UFS
partition, but so far only with limited success.  The kernel correctly
detects the partition and in single user mode, I get this as the root
partition (and can see and read the files on it).

  Whenever I try to fsck, mount (r/w), or read the disklabel, however,
the machine just hangs.  It seems like the kernel has some problem if
there is no dedicated NetBSD partition.

  Any ideas how to fix this?  I'd be happy to help debugging this, but
I'm also having problems entering DDB from the console. 
Command-Alt-Power fails to enter DDB.  It does seem to generate an NMI
-- at least from open firmware it seems to be working, but from within
NetBSD it doesn't have any effect.

  Here is the relevant (hand-typed) dmesg/console output:


...
wdc1 at pci2 dev 13 function 0: interrupting at irq 39
wd0 ad wdc1 channel 0 drive 0: <TOSHIBA MK6021GAS>
wd0: drive supporrts 16-sector PIO transfers, LBA addressing
wd0: 57231MB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 117210240 sectors
wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
wd0(wdc1:0:0): usiong PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100) (using DMA transfers)
...
boot device: wd0
root on wd0a dumps on wd0b
mountroot: trying msdos...
mountroot: trying cd9660...
mountroot: trying nfs...
mountroot: trying ffs...
WARNING: clock gained 2 days -- CHECK AND RESET THE DATE!
root file system type: ffs
init: copying out path `/sbin/init' 11
Sat Jul 12 07:07:12 UTC 2003
Fast boot: skipping disk checks.


  Then the system just hangs.  Hitting enter on the console gives me a
new line, though.  As I said, I can't enter DDB here ...

  If I remove /fastboot, I get

CANNOT READ: BLK 128
/dev/rwd0a: unxecpected inconsistency; RUN fsc_ffs MANUALLY.

  In single user mode, I can get to the shell prompt and list/read the
contents of the disk.  'fsck -p' gives me the same error as above, then
hangs.  'disklabel wd0' also only just hangs.   'mount' gives me:


root_device on / type ffs (read-only, local)


  Attempting a 'mount -u /' returns


/dev/wd0a on /: specified device does not match mounted device


  Ideas anyone?

     ,
  Rene