Re: Swap space
From: Floyd Davidson (floyd_at_barrow.com)
Date: 10/06/03
- Next message: Dave: "Re: Redhat Upgrade Abortion - Again"
- Previous message: John Reiser: "Re: How to extract all but one file from a tar archive?"
- In reply to: Marmagya: "Re: Swap space"
- Next in thread: Kirk Strauser: "Re: Swap space"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 06 Oct 2003 06:47:28 -0800
Marmagya <marmagya@eNOpatra_SPAM.com> wrote:
>Hi all,
> Thanks a lot for your insighful comments on this issue. I learnt
>a few things from your correspondence. I am using my linux system as a
>desktop and not as a server, and hence expected linux to keep in RAM the
>apps that I left opened the night before. Thanks for pointing out the
>rationale behind swapping it out. Yes, for a server, swapping out the
>unused apps will be a smart thing.
> I think it depends on how you are using your system and how you
>it to behave.
>
>Regards
>Marmagya
A process is probably faster to page it back in from swap than
it would be to restart it.
Also, I'm not sure how fast you can expect idle programs to be
swapped out, as it depends greatly on what the system is doing.
Hence your suggestion previously that a process should not be
swapped out if the RAM is not needed, is in fact exactly the way
the system does work. You did mention loading the system up for
the night with with active processes that were doing something.
The active ones are the reason that the inactive ones were
swapped. By moving them to swap, the available RAM was then
useful for disk caching, which significantly speeds up active
processes.
That probably didn't make a great deal of difference to whatever
your system was left doing all night, but if you are at the
keyboard interacting with those processes, you most certainly
*will* like the effect!
And the only downside is that when you leave a process idle
long enough, it is almost as slow to start as if you had just
killed it and restarted. So your system is slow as you blink
your eyes and slurp your first cup of coffee in the morning,
but that also makes it faster from that point until you are
done for the day...
I think that as you explore the ups and downs, you'll like it
just the way it is.
>Kirk Strauser wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> At 2003-10-06T11:25:17Z, Marmagya <marmagya@eNOpatra_SPAM.com> writes:
>>
>>
>>>If the system keeps those things in memory, basically the end user gets a
>>>better responseif he comes back to use the same apps that he left open the
>>>night before.
>>
>>
>> But what's an end user? On many of my systems, the biggest user (in terms
>> of resource consumption) is httpd (Apache), or maybe pgsql (PostgreSQL). If
>> those users haven't touched a page in several hours, they probably won't for
>> a long time. The system is better off for having those idle pages swapped
>> out because there's plenty of fast, juicy RAM for new processes that need to
>> spawn quickly.
>>
>>
>>>It is more likely that the same apps will be used again.
>>
>>
>> Sure, but when? How long is a task idle before it's likely to run again?
>>
>>
>>>My point is, if the system is able to manage while keeping all that in
>>>memory, then it should do so.
>>
>>
>> I disagree. On servers, particularly, that old way of thinking was a
>> performance killer.
>>
>>
>>>Swapping should happen only when system need that memory to do something
>>>else, and swapping out only makes response for end user slower.
>>
>>
>> Your system *did* need that memory for something else: preparing itself for
>> when a new task would inevitably come along that needed those resources.
>> - --
>> Kirk Strauser
>> The Strauser Group
>> Open. Solutions. Simple.
>> http://www.strausergroup.com/
>> -----BEGIN PGP SIGNATURE-----
>> Version: GnuPG v1.2.3 (GNU/Linux)
>>
>> iD8DBQE/gWT05sRg+Y0CpvERArPWAJ4u5CSuJdYinmGcvkmu3+87xgCHrACfSrc8
>> gIE058BBHTQ6AeF4NKsU64Q=
>> =WCAR
>> -----END PGP SIGNATURE-----
>
-- Floyd L. Davidson <http://web.newsguy.com/floyd_davidson> Ukpeagvik (Barrow, Alaska) floyd@barrow.com
- Next message: Dave: "Re: Redhat Upgrade Abortion - Again"
- Previous message: John Reiser: "Re: How to extract all but one file from a tar archive?"
- In reply to: Marmagya: "Re: Swap space"
- Next in thread: Kirk Strauser: "Re: Swap space"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|