Thomas Carlson | 1 Dec 2007 16:21

Magic numbers do not match?

I have been following the progress of NetBSD 4.0 through the RC5 
version and find that my Powerbook 180 sporting a Cabletron EA414 
SCSI/ethernet adaptor can actually boot kern-GENERICSBC just fine 
(kern-GENERIC hangs at "waiting for device to settle")  Problem is, 
when I use: < /sbin/mount -u -w / > to mount the root file system 
read/write and modify /etc/rc.conf to read <rc_configured=YES> I get a 
message saying that the magic numbers do not match when I reboot.  
What's the problem here?  Any suggestions?

Tom

Hauke Fath | 2 Dec 2007 20:47
Picon

Re: Magic numbers do not match?

At 8:21 Uhr -0700 1.12.2007, Thomas Carlson wrote:
>I have been following the progress of NetBSD 4.0 through the RC5
>version and find that my Powerbook 180 sporting a Cabletron EA414
>SCSI/ethernet adaptor can actually boot kern-GENERICSBC just fine
>(kern-GENERIC hangs at "waiting for device to settle")  Problem is,
>when I use: < /sbin/mount -u -w / > to mount the root file system
>read/write and modify /etc/rc.conf to read <rc_configured=YES> I get a
>message saying that the magic numbers do not match when I reboot.
>What's the problem here?  Any suggestions?

Hmmm...

Can you access the root partition from single user mode?

What does a 'file /dev/rsd0a' say?

When and how (as in: What NetBSD version, from sysinst or the MacOS mkfs
tool) was the file-system created?

Can you mount the root filesystem after booting from an install kernel?

Can you mount the root filesystem from a NetBSD 3.x install kernel?

	hauke

--
"It's never straight up and down"     (DEVO)

Thomas Carlson | 3 Dec 2007 14:08

Re: Magic numbers do not match?

On Dec 2, 2007, at 12:47 PM, Hauke Fath wrote:

> At 8:21 Uhr -0700 1.12.2007, Thomas Carlson wrote:
>> I have been following the progress of NetBSD 4.0 through the RC5
>> version and find that my Powerbook 180 sporting a Cabletron EA414
>> SCSI/ethernet adaptor can actually boot kern-GENERICSBC just fine
>> (kern-GENERIC hangs at "waiting for device to settle")  Problem is,
>> when I use: < /sbin/mount -u -w / > to mount the root file system
>> read/write and modify /etc/rc.conf to read <rc_configured=YES> I get a
>> message saying that the magic numbers do not match when I reboot.
>> What's the problem here?  Any suggestions?
>
> Hmmm...
>
> Can you access the root partition from single user mode?

Initially I can, on the first boot it drops into single user mode.  
After mounting /, no.

>
> What does a 'file /dev/rsd0a' say?

On first boot...  /dev/rsd0a:  character special (13/0).  After 
mounting /, and booting with an install kernel, I get...  use one of:  
fd0[a-h] sd0[a-h] se0 ddb halt reboot

>
> When and how (as in: What NetBSD version, from sysinst or the MacOS 
> mkfs
> tool) was the file-system created?
(Continue reading)

Hauke Fath | 3 Dec 2007 22:04
Picon

Re: Magic numbers do not match?

At 6:08 Uhr -0700 3.12.2007, Thomas Carlson wrote:
>> When and how (as in: What NetBSD version, from sysinst or the MacOS
>> mkfs
>> tool) was the file-system created?
>
>NetBSD-4.0_RC5.  I used the MacOS mkfs utility.

Uh huh. This sounds fairly similar to a recently fixed issue with old
filesystems created by the MacOS mkfs tool.

Can you please send-pr the issue? There's a web form at
<http://www.netbsd.org/cgi-bin/sendpr.cgi?gndb=netbsd>.

If you can boot into an install kernel and drop to a shell prompt,
something like

fsck_ffs -c2 /dev/rsd0a

should be able to upgrade the filesystem to something that makes sense to
NetBSD 4. Otherwise... you'd need to set up the disk from scratch with
sysinst.

	hauke

--
"It's never straight up and down"     (DEVO)

Thomas Carlson | 5 Dec 2007 01:11

Re: Magic numbers do not match?

On Dec 3, 2007, at 2:04 PM, Hauke Fath wrote:

> At 6:08 Uhr -0700 3.12.2007, Thomas Carlson wrote:
>>> When and how (as in: What NetBSD version, from sysinst or the MacOS
>>> mkfs
>>> tool) was the file-system created?
>>
>> NetBSD-4.0_RC5.  I used the MacOS mkfs utility.
>
> Uh huh. This sounds fairly similar to a recently fixed issue with old
> filesystems created by the MacOS mkfs tool.
>
> Can you please send-pr the issue? There's a web form at
> <http://www.netbsd.org/cgi-bin/sendpr.cgi?gndb=netbsd>.
>
> If you can boot into an install kernel and drop to a shell prompt,
> something like
>
> fsck_ffs -c2 /dev/rsd0a

I reinstalled the everything and, after successfully booting into a 
fresh system, mounted /dev/sd0a and changing /etc/rc.conf 
appropriately.  I then ran fsck_ffs -c2 /dev/rsd0a.  Got the message... 
  BAD SUPER BLOCK:  CAN'T FIND SUPERBLOCK and a core dump.

>
> should be able to upgrade the filesystem to something that makes sense 
> to
> NetBSD 4. Otherwise... you'd need to set up the disk from scratch with
> sysinst.
(Continue reading)

Izumi Tsutsui | 5 Dec 2007 13:57
Picon
Gravatar

Re: Magic numbers do not match?

tcarlson <at> myback40.com wrote:

> >> when I use: < /sbin/mount -u -w / > to mount the root file system
> >> read/write and modify /etc/rc.conf to read <rc_configured=YES> I get a
> >> message saying that the magic numbers do not match when I reboot.

Could you post exact whole messages you saw?
I don't see any programs which could show
"magic numbers do not match" strings.
("BAD MAGIC NUMBER" of fsck_ffs?)

> None of the NetBSD3.x kernels have booted on my machine.  They all stop 
> at... panic:  no init.

Fix for "no init" problem was pulled up to netbsd-3 branch
after 3.1 release so you could try daily snapshot of netbsd-3 branch.
ftp://ftp.NetBSD.org/pub/NetBSD-daily/netbsd-3/
---
Izumi Tsutsui

Thomas Carlson | 6 Dec 2007 13:29

Re: Magic numbers do not match?

On Dec 5, 2007, at 5:57 AM, Izumi Tsutsui wrote:

> tcarlson <at> myback40.com wrote:
>
>>>> when I use: < /sbin/mount -u -w / > to mount the root file system
>>>> read/write and modify /etc/rc.conf to read <rc_configured=YES> I 
>>>> get a
>>>> message saying that the magic numbers do not match when I reboot.
>
> Could you post exact whole messages you saw?
> I don't see any programs which could show
> "magic numbers do not match" strings.
> ("BAD MAGIC NUMBER" of fsck_ffs?)

Booting...
Magic numbers do not match -- improper UFS partition
Could not open kernel "netbsd"

>
>> None of the NetBSD3.x kernels have booted on my machine.  They all 
>> stop
>> at... panic:  no init.
>
> Fix for "no init" problem was pulled up to netbsd-3 branch
> after 3.1 release so you could try daily snapshot of netbsd-3 branch.
> ftp://ftp.NetBSD.org/pub/NetBSD-daily/netbsd-3/

You are right.  I tried netbsd-GENERICSBC in that release and it works 
fine.  I'm going to go ahead and install the whole system and see if I 
have the same problem with magic numbers when I reboot after mounting 
(Continue reading)

Izumi Tsutsui | 6 Dec 2007 13:53
Picon
Gravatar

Re: Magic numbers do not match?

tcarlson <at> myback40.com wrote:

> Booting...
> Magic numbers do not match -- improper UFS partition
> Could not open kernel "netbsd"

Ah, okay, I see it's a message of the Booter on MacOS.

Could you try to boot netbsd-GENERICSBC kernel on MacOS partition
with a disk with the problematic UFS partition?

If it doesn't work, could you check what "disklabel sd0"
shows on the first boot after installation?

I tried to boot netbsd-GENERIC kernel from /dev/sd0a created
by MacOS Mkfs on my LC630 and there is no problem even after
"mount -u -w /".
---
Izumi Tsutsui

Thomas Carlson | 7 Dec 2007 03:11

Re: Magic numbers do not match?

On Dec 6, 2007, at 5:53 AM, Izumi Tsutsui wrote:

> tcarlson <at> myback40.com wrote:
>
>> Booting...
>> Magic numbers do not match -- improper UFS partition
>> Could not open kernel "netbsd"
>
> Ah, okay, I see it's a message of the Booter on MacOS.
>
> Could you try to boot netbsd-GENERICSBC kernel on MacOS partition
> with a disk with the problematic UFS partition?

It doesn't work.

>
> If it doesn't work, could you check what "disklabel sd0"
> shows on the first boot after installation?

# disklabel sd0
# /dev/rsd0c:
type:  SCSI
disk:  AXSITS2532A 011E
label:  fictitious
flags:
bytes/sector:  512
sectors/track:  32
tracks/cylinder:  64
sectors/cylinder:  2048
cylinders:  2116800
(Continue reading)

Izumi Tsutsui | 7 Dec 2007 11:53
Picon
Gravatar

Re: Magic numbers do not match?

tcarlson <at> myback40.com wrote:

> > Could you try to boot netbsd-GENERICSBC kernel on MacOS partition
> > with a disk with the problematic UFS partition?
> 
> It doesn't work.

How does it fail?
The Booter can't load a kernel from MacOS partition, or something else?
Which version of Booter and Mkfs do you use?

> 4 partitions:
> #		   size		offset	fstype  [fsize  bsize  cpg/sgs]
>    a:	    1540704   	      512096     4.2BSD         0         0         
>   0
>    b:             64000 	    2052800         swap
>    c:         2116800                         0     unused          0    
>       0
>    d:           512000	                96	   HFS

Ok, the partition table looks fine.
---
Izumi Tsutsui


Gmane