On Sun, Feb 27, 2005 at 05:05:35PM -0600, Jason Clark wrote:
> I'll hammer it a bit harder and see if I can get it to release those last 
> few pages into swap. Thanks.

Well, if you're trying to prove that it will actually swap, then a
simple C program of the form:

int main(int argc, char** argv) {
        calloc(100,1024*1024);
        sleep(100);
        return 0;
}

Will attempt to allocate 100MB of RAM.

The second line of output from "free" will give you a much better
indication of how much RAM is available before it will start swapping.

Paul

> On Sun, 27 Feb 2005, Paul Warren wrote:
> 
> > On Fri, Feb 25, 2005 at 05:06:46PM -0600, Jason Clark wrote:
> >> I have recently seen an increase in traffic to one of my sites that is
> >> hosted using UML.  Previously, I had allocated 128Megs of RAM and 1 gig of
> >> swap to each UML, but I never got close to touching the swap file. It
> >> always remained at 0% usage.   With the traffic spike, I have noticed
> >> that I will drop all the way down to 200k of free RAM on a guest uml,
> >> but the swapfile is still never touched.
> >
> > When you say 200k of free RAM, which figure are you reading?  It is
> > normal for Linux to use up all available RAM under normal usage, as it
> > will retain a cache of disk pages.  It will throw these away if there is
> > a real need for the RAM.  For this reason, free will claim close to 100%
> > memory usage long before it actually hits swap.
> >
> > Paul
> >
> 
> 
> -------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT Products from real users.
> Discover which products truly live up to the hype. Start reading now.
> http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
> _______________________________________________
> User-mode-linux-user mailing list
> User-mode-linux-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
User-mode-linux-user mailing list
User-mode-linux-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user

Reply via email to