[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: why does the kernel suck up memory?



Jay Barbee writes:
 > > I've noticed that when I added more memory, the extra memory went into
 > > "buffers". Why? I don't have a heavily loaded system which would require
 > > massive buffers. How can I change the kernel to stop with this unnecessary
 > > behavior?
 > > I'm trying to keep from using swap space. Once a swap partition is accessed,
 > > it is never dropped and I need to _not_ access swap space for performance
 > > reasons (IO bandwidth).
 > 
 > Why would you add memory and not expect your operating system to use 
 > it.  That would be a waste.  The Linux kernel takes your memory and 
 > allows various parts of your system (such as disk IO) to speed up.  
 > 
 > DOS doesn't do that kind of memory monitoring, and in the case of 
 > Microsoft (not NT), free memory is useable memory.  Because you 
 > memory is in cache and buffers does not mean that it will not get 
 > used if it is needed.
 > 
 > --Jay

I have trouble with the idea that a swap partition is "never dropped"
once it is accessed, especially in light of the following:

osiris# cat /proc/meminfo
        total:    used:    free:  shared: buffers:  cached:
Mem:  48283648 42934272  5349376 28479488  1650688 16846848
Swap: 94957568        0 94957568
MemTotal:     47152 kB
MemFree:       5224 kB
MemShared:    27812 kB
Buffers:       1612 kB
Cached:       16452 kB
SwapTotal:    92732 kB
SwapFree:     92732 kB
osiris# swapoff /dev/hda2
osiris# cat /proc/meminfo
        total:    used:    free:  shared: buffers:  cached:
Mem:  48283648 42909696  5373952 28483584  1650688 16846848
Swap:        0        0        0
MemTotal:     47152 kB
MemFree:       5248 kB
MemShared:    27816 kB
Buffers:       1612 kB
Cached:       16452 kB
SwapTotal:        0 kB
SwapFree:         0 kB

If one really wants to avoid swap, why wouldn't one simply
not have any swap partitions?


 > 
 >  
 > 
 > 
 > --
 > To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
 > with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


--
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


Reply to: