Subject: Re: Help with memory disk
To: None <roberto@redix.it>
From: Frederick Bruckman <fredb@immanent.net>
List: tech-embed
Date: 05/29/2003 08:25:59
On Thu, 29 May 2003 roberto@redix.it wrote:

> But I cannot use mount_mfs() simply becouse I do not have any swap (or
> other writable) partition on disk. So I 'm try to use md.
>
> Actually I want to use flash memory as hard disk, and mount it as read only
> root disk; the memory disk, mounted read-write, will be used for /var,
> /dev/ and /tmp.

I think you'll need something in "/dev" before you mount anything at
all, but no doubt you can arrange for that, and still mount over it.

> --On Monday, May 26, 2003 00:27:32 -0400 Gan Uesli Starling
> <alias@starling.us> wrote:> >>

> > I did not see where anybody answered your question.

> >> 2) to create a 8 MB of ramdisk I run: "mdconfig /dev/md0a 9192 & "
> >>
> >> 3) before I can mount it I should create a file system with newfs; is it
> >> correct?

The answer given was to use "makefs" to build a skeletal file system
(as a file, which might then, say, be compressed with "gzip"), then to
use "dd" to get it into "md0". E.g:

	mkdir mdroot mdroot/var mdroot/tmp mdroot/dev
	makefs mdroot.fs mdroot
	gzip -9 mdroot.fs
	mdconfig /dev/md0d 8192 &
	gzcat mdroot.fs.gz | dd of=/dev/md0d
	mount /dev/md0a /mnt
	find /mnt

By they way, guys... it would be nice if you would put responses
*after* the text you're responding to. Given the established
conventions on this list, "top-posting" is simply going to reduce
the likelihood that you get a response.

Frederick