Re: another error with md malloc based fs



On Mar 22, 2007, at 4:17 PM, Michael Schuh wrote:
i can't understand how malloc can eat all available
memory, i have 2Gigs of it ;-)
so it seems to me i know what i doing, if
i have 1,6 Gigs free Memory, and i say ok get me 750Megs from
my 1,6 Gigs of free Memory, what was faulty on that????

The two choices involve a swap-based RAMdisk, which can use all of the available physical RAM it needs to, since this memory is swappable, or a kernel-memory-based RAMdisk, which uses wired-down memory from within the kernel.

You shouldn't or can't create huge kernel-based RAMdisks without expanding the amount of KVM available to the kernel...it's not reasonable to wire down hundreds of MB or RAM in almost all situations.

i hope it gave another way to use such ram-disk without using
swap or other harddisk based backend....otoh my ram is not fully useful
for me and i must, after twelve years of using freebsd, looking back to
linux, and that i never would, only for using ramdisks....

If you wanted to create a 10MB RAMdisk, using kernel-based memory would be fine.

For things which are much larger than that, the kernel's global VM management is using techniques like page-fault frequency heuristics and will do a better job of keeping active stuff cached in RAM (regardless of whether the stuff is part of a running process or part of your RAMdisk filesystem), if you let the kernel manage the situation than if you try to configure hundreds of MB which can only be used for a RAMdisk.

Anyway, if you want to use Linux instead, nobody here is going to try to persuade you to do otherwise. Have fun,

--
-Chuck

_______________________________________________
freebsd-stable@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: How to set up a Linux machine that occupies the minimum memory footprint ?
    ... Of course, if you use 8GB of RAM, or more precisely if you ... Are you saying that if I have a 4GB RAM memory, ... Linux will somehow "know" that it doesn't have ... You've said in another message that your app is ...
    (comp.os.linux.setup)
  • Re: How to set up a Linux machine that occupies the minimum memory footprint ?
    ... Of course, if you use 8GB of RAM, or more precisely if you ... Are you saying that if I have a 4GB RAM memory, ... Linux will somehow "know" that it doesn't have ... You've said in another message that your app is ...
    (comp.os.linux.misc)
  • Re: OT (slightly) swap limits
    ... influence your decision on how much swap was enough. ... processes due to lack of memory. ... I've run machines with 1Gig or more RAM with NO SWAP. ... Linux possible when before on Unix it wasn't? ...
    (Debian-User)
  • Re: Steve Jobs demos Macintosh in 1984
    ... Woody wrote: ... Stop annoying the fucking hell out of me, ... For sure not much computer memory had been made in 1948 - but it could ... For sure you got a bit more RAM to use in the Speccy - ...
    (uk.comp.sys.mac)
  • Re: oom-killer vs system not reachable
    ... Do you think that Linux might stop to respond or get stuck ... Another situation is that several processes are competing for memory, ... in ram at once. ... is to monitor or log what happens when the system dies like this, ...
    (Debian-User)