Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 05 Mar 2006 21:32:45 -0600
From:      Kevin Kinsey <kdk@daleco.biz>
To:        "Frank J. Laszlo" <laszlof@vonostingroup.com>
Cc:        Michael Tuchman <mftuchman@alum.mit.edu>, freebsd-questions@freebsd.org
Subject:   Re: Applications using hard disk too often
Message-ID:  <440BAD5D.6060208@daleco.biz>
In-Reply-To: <440B93EC.5010600@vonostingroup.com>
References:  <440B7224.4060404@alum.mit.edu> <440B93EC.5010600@vonostingroup.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Frank J. Laszlo wrote:

> Michael Tuchman wrote:
>
>> I am running freeBSD 5.4 stable on a P133 box with 128 Mb ram. 
>> Although I don't think I'm overloading the system, it seems that
>> my system is using virtual memory too often.   Admittedly, this
>> is a subjective question where 'too often' means only 'more often
>> than I remember with other *nix-like operating environments on
>> even weaker machines'.
>>

Without some clue as to what the system is doing, IMHO it's difficult
for anyone to speculate why you'd be "swapping" so much.  FreeBSD
uses all the memory it has because the designers know that "free
memory is wasted memory" ... I don't know where that statement
originated, but you'll hear it from FreeBSD programmers if you keep
your ears open.

One possibility is that you have actually configured **too much swap
space** (Joshua Coombs, http://www.bsdnews.org/03/tuning.pdf).

I'd also have to say that I'd consider this box to be a tad slow for
a workstation unless your graphical environment was rather lightweight.
I've tried GNOME2 on an AMD K6-2 475 with 128 MB and it just
crawled.  It's slightly better with XFCE, but to get much performance
from a box like that I'd recommend black/fluxbox or something equally
easy on the resources.  If this isn't a graphical environment, then
something *is* wrong, I'd think.

>> Can anybody offer advice on memory management, appropriate
>> places to read in the documentation, or other useful links?
>

Advice: with 128MB of RAM, don't open 127MB PDF files  </rimshot>

Reading:  Chapter 2 of McCusick's "Design & Implementation":

   http://www.freebsd.org/doc/en_US.ISO8859-1/books/design-44bsd/index.html

and tuning(7) are a couple of canonical resources.  Google is always
your friend, also.  I apologize if that seems like "RTFM, newb"; it's just
that IANAE and don't play one on the Internet, either.


>> I realize that the answer is 'it depends', so what I am asking is really
>> * How can I find out if I change this annoying behavior for the better?
>

Experiment?  Add RAM; take away RAM; add more swap; take away some
swap.

Of course, not all of those could be called exactly 'trivial' to the system.

>> * Would upgrading to 6.0 help?
>

Possibly, but without knowing the cause it's hard to say for sure;
IOW, no silver bullet there.


>> This is an experimental box only.  There is no critical data on it,
>> so data loss is not an issue when considering options.
>
>
> The 5.x series was a "transition" release, to ease the pain between
> 4.x and 6.x.


Hmm, I wonder.  4.X to 5.X wasn't completely "painless", (at least, you
had to take some pains to get it right), so I might contest this.  Any
further discussion or speculation on this would place this posting in
the political rather than technical realm, which I am loathe to do.  For
one reason or another, 6.X is out.  6.X is good.  AFAIAC, 5.X was also
good and 4.X was good too.

> I would recommend going up to 6.0 (or 6.1, But I have not
> yet tested it) Doing a fresh install would probably be in your best 
> interest.


The transition from 5.4 to 6.X is quite trivial; the only reason a
"fresh install" might benefit is if the OP has too much swap and
wants to configure less during slicing.

It's also possible that doing a fresh install of 6.0 would fix the
problem, but teach us nothing about the situation we'd hoped
to learn from??

> Also running a custom kernel will ease some of the overhead, if you 
> aren't
> already doing that. Remove anything from the kernel you do not use, etc..


Absolutely.  But, be careful and read the config files carefully, or
we'll be hearing from you that your kernel won't compile....

> There are numerous documents for doing this. The freebsd handbook is a
> excellent resource for both newbies and seasoned system admins.
> (http://www.freebsd.org/handbook) The output of `ps uxaww` will give
> us more of an idea of what you can get rid of as far as running daemons.
> Hope this helps.
>
> -Frank


Good advice.

Michael: tell us more about the system?


Kevin Kinsey

-- 
We don't care how they do it in New York.





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?440BAD5D.6060208>