-   Linux - Newbie (
-   -   memory question (

true_atlantis 10-30-2004 06:46 PM

memory question
how is memory allocated to a specific user? i was looking at the kde system guard, and it seemed that the user doesnt have as much to work with as the system... is there any way i can increase a users memory avalible to them? some process will be using like 90% of users memory, but will only be 1% of the systems... that doesnt make sence to me

btmiller 10-30-2004 07:34 PM

Linux memory management is a lot different than that of other systems. Linux tries to grab as much free memory as it can for uses as internal buffers and cache. This memory can easily be reallocated to applications that need it. The only time you really have a problem is when there's not enough RAM and the OS has to swap pages to and from disk. A little swapping is OK, but heavy swapping causes a condition known as thrashing, which dramatically lowers performance.

Memory is allocated to a specific process based on how much memory the kernel thinks it will need, based on information in the executable file. Programs can also dynamically request more memory when they execute, in which case the kernel will try to honor the request, unless you have set the ulimit to limit memory usage. Note that the kernel can "overcommit" system resources and this will cause problems if every process tries to use all the resources it requests. If you're really interested in how this actually works, check the code in the mm directory of your kernel source.

foo_bar_foo 10-31-2004 12:09 AM

when you look at kde system guard
user% and system%

refer to cpu usage not memory
user = userspace cpu usage system = kernel space cpu usage

so all you are saying is that the thing i am running is the thing using the cpu

All times are GMT -5. The time now is 05:59 PM.