tech-embed archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Help with memory disk




Hi Gan,
First, I've submitted some mail on netbsd-help mailing list, and someone on it redirect me to tech-embedded.

Ok I've already red about mount_mfs() and it works as you described.

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.

Thanks for your answer,
Roberto

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

roberto%redix.it@localhost wrote:
I'd like to setup a ramdisk (on netbsd 1.6 GENERIC) for temporary files,
without any file image and real disk device (eg. swap partition, so I
prefer to not use mount_mfs).

As suggested I'm using md and mdconfig:

1) I've 2 device in /dev:
md0a b 17, 0
md0d b 17, 3

(a first question: what is the means of these device?)

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?


Thanks in advance,
Roberto

I did not see where anybody answered your question.
I just did 'man mount_mfs' and played around with
it. It seems to work pretty simply. I do like
below as root...

baal: {1} mkdir /foo
baal: {2} mount_mfs -s 32m swap /foo
baal: {3} cp /spare/jpg/x15.jpg /foo
baal: {4} ls /foo
x15.jpg
baal: {5} umount /foo
baal: {6} ls /foo
baal: {7}

...so it is not very complex, apparently.

Later,

Gan

--

  Mistera Sturno - Rarest Extinct Bird

  <(+)__       Gan Uesli Starling
   ((__/)=-    Kalamazoo, MI, USA
    `||`
     ++        http://starling.us




******* Internet Email Confidentiality Footer *************
Privileged/Confidential Information may be contained in
this message. If you are not the addressee indicated in this message (or
responsible for delivery of the message to such person), you may not copy
or deliver this message or any attachment to anyone. In such case, you
should destroy this message and any attachment and kindly notify the sender
by reply email. Opinions, conclusions and
other information in this message that do not relate to the official
business of ReDiX



Home | Main Index | Thread Index | Old Index