Returning User With Filesystem/Memory Tuning Questions

Giorgos Keramidas keramida at ceid.upatras.gr
Wed Dec 3 19:12:22 PST 2008


On Wed, 3 Dec 2008 17:24:48 -0600 (CST), Kevin Monceaux <Kevin at RawFedDogs.net> wrote:
> On Wed, 3 Dec 2008, Roland Smith wrote:
>
>> Application crashed can also be due to bad hardware, especially
>> memory. Make sure that you rule out hardware troubles before diving
>> into the software.
>
> I don't think it was hardware related, but it's a possibility.
>
> Jogging my memory a bit more I think the first program I had memory
> allocation problems was tin.  Fetching headers from even a semi-large
> newsgroup would cause tin to crash.  I forget the exact error messages
> but they were something along the lines of not being able to allocate
> the needed amount of memory.  At the times of the failures there
> appeared to be available RAM with swap space completely untouched.  The
> errors occurred at about the same point in fetching the headers each
> time. After much Googling I tried adjusting the following:
>
> kern.maxdsiz
> kern.dfldsiz
> kern.maxssiz

Hi Kevin,

The `kern.maxdsiz' tunable is a boot-time option that limits the amount
of memory a _single_ process can allocate for its `data'.   The default
value is 512 MB (the value reported by sysctl is the number of bytes):

    $ sysctl kern.maxdsiz
    kern.maxdsiz: 536870912

If a single process running on i386 wants to allocate more than 512 MB
of memory, and it is not a large database server, then it's possible
that something is wrong with the way the process handles its memory :)

For what it's worth, I've been reading newsgroups with more than 5000
messages in Gnus, a newsreader that runs inside GNU Emacs, and its
memory usage has *never* reached 512 MB, so if you want help to switch
from the aging tin reader to something that is still maintained &
developed actively, I will be glad to help.  Gnus can run in text-only
mode too, much like tin; it supports threading, scoring of messages by
author, subject, by custom header filters, etc.; it can read messages
from multiple news servers; it can work in `offline' mode and post all
your outgoing messages later, when you get back online; it can prefetch
all the messages of your favorite groups, and that's just a short list
of the features I can remember off-hand.

> which greatly improved things.  But, I adjusted them using examples of
> values I found on the net without really understanding what I was
> doing. This time around I want to learn how to tweak whatever settings
> need to be tweaked to best use my available memory.

Well, you can just ask here, on the freebsd-questions list.  There are
_many_ knowledgeable subscribers who can describe what each FreeBSD
option means, how to tune it for your own needs, and so on :-)



More information about the freebsd-questions mailing list