using mfs of size > 64Mb and system stability
Scott Long
scottl at freebsd.org
Sat Jan 8 09:33:28 PST 2005
Using the swap option really is the preferred method. The available
kernel malloc pool is limited and is scaled on the amount of system
RAM that you have; on my 256MB laptop, it's reporting only 85MB
available for kernel malloc. So this would explain why trying to
malloc 128MB for md could fail =-).
With the swap option, pages are allocated from the buffer/cache and
held there. They are only swapped to disk when the system is under
memory pressure, otherwise they stay in RAM.
Scott
Barath S wrote:
> Thank you Arne.
> I didn't try with 'swap' option as my requirement is
> to have the files in memory. I will test with 5.3 and
> see it that works.
> regards
> --- Arne Wörner <arne_woerner at yahoo.com> wrote:
>
>>--- Barath S <barath_yes at yahoo.com.sg> wrote:
>>
>>>My intention is create a file system in memory of
>>
>>size
>>
>>>>128Mb and use that for my application. But, I
>>>
>>>couldn't do that as my system hangs whenever I
>>
>>create
>>
>>>a mfs of size > 64Mb. I did the following...
>>>
>>>a) Configured memory file system of size 128Mb
>>
>>using
>>
>>>'mdmfs' command with 'malloc' option. When I tried
>>
>>to
>>
>>>copy files to this mfs, m/c hanged after copying
>>
>>some
>>
>>>files.
>>>b) Then I rebooted by m/c and configured memory
>>
>>file
>>
>>>system of size 64Mb and this time the copying
>>>operation was successful
>>>c) I observed that the system hanged whenever I
>>>configure a mfs of size > 64Mb and used that mfs
>>>
>>>a) Can someone provide me hints on what could be
>>
>>the
>>
>>>problem ?
>>>
>>
>>I use R5.3. According to the man page mdconfig(8) a
>>md of type
>>malloc should use "-o reserve", if it is large and
>>to be "filled"
>>(I think the man page means "filled quickly"):
>> "If the -o reserve option is not set, creating and
>>filling
>> a large malloc-backed memory disk is a very easy
>>way to
>> panic a system."
>>
>>Maybe that helps?
>>
>>Did you try type "swap"?
>>
>>-Arne
>>
>>
>>
>>
>>__________________________________
>>Do you Yahoo!?
>>The all-new My Yahoo! - Get yours free!
>>http://my.yahoo.com
>>
>>
>>
>
>
> __________________________________________________
> Do You Yahoo!?
> Download the latest ringtones, games, and more!
> http://sg.mobile.yahoo.com
> _______________________________________________
> freebsd-fs at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-fs
> To unsubscribe, send any mail to "freebsd-fs-unsubscribe at freebsd.org"
More information about the freebsd-fs
mailing list