Subject: Re: Cannot mount root / no file system for md0
To: Manuel Bouyer <bouyer@antioche.lip6.fr>
From: Daniel Eggert <danieleggert@mac.com>
List: netbsd-help
Date: 08/26/2002 07:45:11
On fredag, aug 23, 2002, at 17:02 Europe/Copenhagen, Manuel Bouyer 
wrote:

> On Fri, Aug 23, 2002 at 04:59:58AM -0700, Daniel Eggert wrote:
>> I've vreated my own boot CD for 1.5.3 (macppc) since I wan't to 
>> install onto my RAID card (The installer kernel needs the mlx(4) 
>> driver to see the RAID card and any attached disk).
>>
>> When I boot it sees the RAID card and the attached disks, but then I 
>> get the following:
>>
>>   cd0 at scsibus0 target 1 lun 0: <MATSHITA, CD-ROM CR-8005A, 4.0i> 
>> SCSI2 5/cdrom r
>>   emovable
>>   md0: internal 2048K image area
>>   boot device: cd0
>>   root on md0a dumps on md0b
>>   no file system for md0 (dev 0x900)
>>   cannot mount root, error = 79
>>
>> Any ideas, what I should do? Should I set the MINIROOTSIZE to 
>> something higher? How does the kernel know, what to put into the 
>> memery disk?
>
> Your kernel doesn't have a miniroot inclued. See mdsetimage(8), and
> the makefiles in src/distrib/i386/floppies to see how to generate and
> load a miniroot.

With the help of Manuel Bouyer I finally solved this one:

First I configure and compile the INSTALL kernel with the drivers I 
need and without those that give me troubles.

Next thing to do is to get a memory disk image: I go into 
/usr/src/distrib/<my-port>/floppies/ and do a 'make clean; make'. For 
some reason there is some error, which I ingore: I do one more 'make'. 
After some shuffling on the harddisk, make stops again with some error, 
but now, inside /usr/src/distrib/<my-port>/floppies/ramdisk there is a 
file caled ramdisk.fs, which contains my md-image.

Now I use mdsetimage(8) to put that image into the INSTALL kernel. Then 
I gzip the kernel and put the resulting netbsd.gz in the root of my 
custom CD.

At last I chose to build my own kernel for the system to use after 
installing. I cheated a bit and put this in the place sysinst expects 
the GENERIC kernel to be. This will make sysinst install my kernel 
instead of the GENERIC.

That's it. Good luck to anybody else who'll try this, and a big bunch 
of thanks to those who have helped me.

Daniel