LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-12-2005, 04:15 AM   #1
Devyn
Member
 
Registered: Oct 2004
Posts: 98

Rep: Reputation: 15
Unhappy Fedora Memory Usage


Hello,

Fedora 2 memory usage is huge. I've installed, ThunderBird, FireFox and JDK 1.5 / Eclipse. The memory use for these three applications is huge. This is more then 4 times the memory usage for the same applications in Windows. Why is Fedora 2 taking this much memory to run these apps? What could I do about this to decrease memory usage or reduce it in other ways?

In contrast, when I boot to Windows 2000 partition, I have these three running and also Apache 2.0.X, Tomcat 5.X, MySQL, Norton, yadda yadda yadda and the memory usage when I'm booted into Windows is showing well below 300MB.

I searched for a way to resolve this but coldn't find a suitable answer.

Thanks,
Devyn

5392 2160 cupsd SELINUX_IN root
6548 3339 /usr/bin/konsole root
9560 3944 /usr/bin/kate SS root
26984 2840 /usr/X11R6/bin/X root
27128 10533 sort -n KDE_MULT root
80924 4645 /Installs/Thunde root
85672 3384 /Installs/FireFo root
208084 3327 /usr/java/jdk1.5 root
[root@fedora root]# free
total used free shared buffers cached
Mem: 513916 505584 8332 0 45344 182948
-/+ buffers/cache: 277292 236624
Swap: 4192956 5828 4187128
[root@fedora root]#
 
Old 06-12-2005, 04:48 AM   #2
piscikeeper
Member
 
Registered: Jul 2003
Location: Pennsylvania USA
Distribution: SuSE
Posts: 430

Rep: Reputation: 30
Swap: 4192956 5828 4187128
this is where the difference is coming from.linux has better memory management,if it's available it will use ram before swap.windows uses swap even if the ram is available.it used to cause me to wonder too until i checked the swap usage.
 
Old 06-12-2005, 07:55 AM   #3
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Linux buffers disk access, so frequently accessed data is retained in memory making it faster to access it. You are not really running out of memory, so everything is okay the way it is.
 
Old 06-12-2005, 11:12 AM   #4
PMorph
Member
 
Registered: Sep 2003
Distribution: Debian
Posts: 213

Rep: Reputation: 31
Yeah, look at it this way: resources not used are resources wasted, not the other way around. How they are used, is the key.
 
Old 06-13-2005, 03:11 PM   #5
Devyn
Member
 
Registered: Oct 2004
Posts: 98

Original Poster
Rep: Reputation: 15
Hello,

> Linux buffers disk access, so frequently accessed data is retained in memory making it faster to access it.

Yes I think that's a very good strategy too. Eccessive swap usage is a problem with Windows. Does Fedora really require that much memory? Even without KDE running, the system uses over 70% of total memory.

[root@lhs root]# cat memory-usage-in-run-level-1.txt
total used free shared buffers cached
Mem: 515704 355860 159844 0 33236 271676
-/+ buffers/cache: 50948 464756
Swap: 2530196 0 2530196
[root@lhs root]#

Is there a way to fine tune this 400MB+ 'cache'? Also, is there an accurate means of displaying memory the Kernel is using or has allocated? I would really like to fine tune this usage and performance of my installation if possible.

Thanks,
Dev
 
Old 06-13-2005, 06:33 PM   #6
piscikeeper
Member
 
Registered: Jul 2003
Location: Pennsylvania USA
Distribution: SuSE
Posts: 430

Rep: Reputation: 30
70% usage without an x server is high.on a more or less idle machine x takes <5% and the window manager even less.try running the "top" command to get a list of running tasks and pinpoint the culprit that way.
 
Old 06-13-2005, 08:32 PM   #7
Devyn
Member
 
Registered: Oct 2004
Posts: 98

Original Poster
Rep: Reputation: 15
Hello,

The usage this time was at around 50% (This is at run level 1). Here is a printout of system stats: (See at end of this post)

After entering run level 5, memory usage jumps to this:

[root@lhs root]# free
total used free shared buffers cached
Mem: 515704 450400 65304 0 75068 231712
-/+ buffers/cache: 143620 372084
Swap: 2530196 0 2530196
[root@lhs root]#

30 minutes later it's this:

[root@lhs root]# free
total used free shared buffers cached
Mem: 515704 498580 17124 0 76700 269616
-/+ buffers/cache: 152264 363440
Swap: 2530196 0 2530196
[root@lhs root]#


Thanks,
Dev



[ MEMORY USAGE AT RUN LEVEL 1 ]

Linux lhs 2.6.10-1.770_FC2 #1

0 2 [ksoftirqd/0] root
0 3 [events/0] root
0 4 [khelper] root
0 16 [kacpid] root
0 99 [kblockd/0] root
0 107 [khubd] root
0 161 [pdflush] root
0 162 [pdflush] root
0 163 [kswapd0] root
0 164 [aio/0] root
0 258 [kseriod] root
0 461 [kjournald] root
0 1450 [kjournald] root
0 1451 [kjournald] root
0 1452 [kjournald] root
0 1453 [kjournald] root
SZ PID USER
572 2365 rpc.idmapd SELIN root
620 1 init [S] root
620 10766 init [S] root
844 578 udevd SUBSYSTEM= root
1216 10779 /bin/sh root
2676 11007 ps axeo size,pid root
2952 10163 minilogd SELINUX root
27688 11008 sort -n CONSOLE= root



total used free shared buffers cached
Mem: 515704 252504 263200 0 71072 156604
-/+ buffers/cache: 24828 490876
Swap: 2530196 0 2530196



top - 00:28:24 up 5:48, 3 users, load average: 0.00, 0.03, 0.08
Tasks: 23 total, 1 running, 22 sleeping, 0 stopped, 0 zombie
Cpu(s): 2.4% us, 1.9% sy, 9.6% ni, 85.7% id, 0.3% wa, 0.2% hi, 0.0% si
Mem: 515704k total, 252568k used, 263136k free, 71084k buffers
Swap: 2530196k total, 0k used, 2530196k free, 156656k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ PPID RUSER UID GROUP TTY SWAP TIME COMMAND
11010 root 15 0 2756 864 704 R 2.0 0.2 0:00.01 10779 root 0 root tty1 1892 0:00 top
1 root 16 0 1940 544 460 S 0.0 0.1 0:01.23 0 root 0 root ? 1396 0:01 init
2 root 34 19 0 0 0 S 0.0 0.0 0:00.05 1 root 0 root ? 0 0:00 ksoftirqd/0
3 root 5 -10 0 0 0 S 0.0 0.0 0:00.84 1 root 0 root ? 0 0:00 events/0
4 root 6 -10 0 0 0 S 0.0 0.0 0:00.06 3 root 0 root ? 0 0:00 khelper
16 root 15 -10 0 0 0 S 0.0 0.0 0:00.00 3 root 0 root ? 0 0:00 kacpid
99 root 5 -10 0 0 0 S 0.0 0.0 0:00.13 3 root 0 root ? 0 0:00 kblockd/0
107 root 15 0 0 0 0 S 0.0 0.0 0:00.00 1 root 0 root ? 0 0:00 khubd
161 root 20 0 0 0 0 S 0.0 0.0 0:00.00 3 root 0 root ? 0 0:00 pdflush
162 root 15 0 0 0 0 S 0.0 0.0 0:00.12 3 root 0 root ? 0 0:00 pdflush
164 root 10 -10 0 0 0 S 0.0 0.0 0:00.00 3 root 0 root ? 0 0:00 aio/0
163 root 15 0 0 0 0 S 0.0 0.0 0:00.28 1 root 0 root ? 0 0:00 kswapd0
258 root 25 0 0 0 0 S 0.0 0.0 0:00.00 1 root 0 root ? 0 0:00 kseriod
461 root 15 0 0 0 0 S 0.0 0.0 0:00.31 1 root 0 root ? 0 0:00 kjournald
578 root 6 -10 2076 376 292 S 0.0 0.1 0:00.23 1 root 0 root ? 1700 0:00 udevd
1450 root 15 0 0 0 0 S 0.0 0.0 0:00.00 1 root 0 root ? 0 0:00 kjournald
1451 root 20 0 0 0 0 S 0.0 0.0 0:00.00 1 root 0 root ? 0 0:00 kjournald
1452 root 15 0 0 0 0 S 0.0 0.0 0:00.05 1 root 0 root ? 0 0:00 kjournald
1453 root 15 0 0 0 0 S 0.0 0.0 0:00.17 1 root 0 root ? 0 0:00 kjournald
2365 root 16 0 1872 568 484 S 0.0 0.1 0:00.00 1 root 0 root ? 1304 0:00 rpc.idmapd
10163 root 15 0 4184 1208 272 S 0.0 0.2 0:00.00 1 root 0 root ? 2976 0:00 minilogd
10766 root 17 0 1940 544 460 S 0.0 0.1 0:00.00 1 root 0 root tty1 1396 0:00 init
10779 root 15 0 3092 1184 968 S 0.0 0.2 0:00.06 10766 root 0 root tty1 1908 0:00 sh





COMMAND PID USER FD TYPE DEVICE SIZE NODE NAME
init 1 root cwd DIR 3,66 4096 2 /
init 1 root rtd DIR 3,66 4096 2 /
init 1 root txt REG 3,66 35344 2779952 /sbin/init
init 1 root mem REG 3,66 59400 787119 /lib/libselinux.so.1
init 1 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
init 1 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
init 1 root 10u FIFO 3,66 2170400 /dev/initctl
ksoftirqd 2 root cwd DIR 3,66 4096 2 /
ksoftirqd 2 root rtd DIR 3,66 4096 2 /
events/0 3 root cwd DIR 3,66 4096 2 /
events/0 3 root rtd DIR 3,66 4096 2 /
khelper 4 root cwd DIR 3,66 4096 2 /
khelper 4 root rtd DIR 3,66 4096 2 /
kacpid 16 root cwd DIR 3,66 4096 2 /
kacpid 16 root rtd DIR 3,66 4096 2 /
kblockd/0 99 root cwd DIR 3,66 4096 2 /
kblockd/0 99 root rtd DIR 3,66 4096 2 /
khubd 107 root cwd DIR 3,66 4096 2 /
khubd 107 root rtd DIR 3,66 4096 2 /
pdflush 161 root cwd DIR 3,66 4096 2 /
pdflush 161 root rtd DIR 3,66 4096 2 /
pdflush 162 root cwd DIR 3,66 4096 2 /
pdflush 162 root rtd DIR 3,66 4096 2 /
kswapd0 163 root cwd DIR 3,66 4096 2 /
kswapd0 163 root rtd DIR 3,66 4096 2 /
aio/0 164 root cwd DIR 3,66 4096 2 /
aio/0 164 root rtd DIR 3,66 4096 2 /
kseriod 258 root cwd DIR 3,66 4096 2 /
kseriod 258 root rtd DIR 3,66 4096 2 /
kjournald 461 root cwd DIR 3,66 4096 2 /
kjournald 461 root rtd DIR 3,66 4096 2 /
udevd 578 root cwd DIR 3,66 4096 2 /
udevd 578 root rtd DIR 3,66 4096 2 /
udevd 578 root txt REG 3,66 7912 2780130 /sbin/udevd
udevd 578 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
udevd 578 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
udevd 578 root 0u unix 0xdf7e1800 653 socket
udevd 578 root 1r FIFO 0,5 654 pipe
udevd 578 root 2w FIFO 0,5 654 pipe
udevd 578 root 3u unix 0xdf7e1580 655 socket
kjournald 1450 root cwd DIR 3,66 4096 2 /
kjournald 1450 root rtd DIR 3,66 4096 2 /
kjournald 1451 root cwd DIR 3,66 4096 2 /
kjournald 1451 root rtd DIR 3,66 4096 2 /
kjournald 1452 root cwd DIR 3,66 4096 2 /
kjournald 1452 root rtd DIR 3,66 4096 2 /
kjournald 1453 root cwd DIR 3,66 4096 2 /
kjournald 1453 root rtd DIR 3,66 4096 2 /
rpc.idmap 2365 root cwd DIR 3,66 4096 2 /
rpc.idmap 2365 root rtd DIR 3,66 4096 2 /
rpc.idmap 2365 root txt REG 3,67 30408 3915872 /usr/sbin/rpc.idmapd
rpc.idmap 2365 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
rpc.idmap 2365 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
rpc.idmap 2365 root mem REG 3,66 50944 784945 /lib/libnss_files-2.3.3.so
rpc.idmap 2365 root 0u CHR 1,3 2164417 /dev/null
rpc.idmap 2365 root 1u CHR 1,3 2164417 /dev/null
rpc.idmap 2365 root 2u CHR 1,3 2164417 /dev/null
rpc.idmap 2365 root 3r DIR 0,17 0 4 /var/lib/nfs/rpc_pipefs/nfs
minilogd 10163 root cwd DIR 3,66 4096 2 /
minilogd 10163 root rtd DIR 3,66 4096 2 /
minilogd 10163 root txt REG 3,66 5948 2780007 /sbin/minilogd
minilogd 10163 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
minilogd 10163 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
minilogd 10163 root 0u CHR 1,3 2164417 /dev/null
minilogd 10163 root 1u CHR 1,3 2164417 /dev/null
minilogd 10163 root 2u CHR 1,3 2164417 /dev/null
minilogd 10163 root 3u unix 0xdf314300 19083 /dev/log
init 10766 root cwd DIR 3,66 4096 2 /
init 10766 root rtd DIR 3,66 4096 2 /
init 10766 root txt REG 3,66 35344 2779952 /sbin/init
init 10766 root mem REG 3,66 59400 787119 /lib/libselinux.so.1
init 10766 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
init 10766 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
init 10766 root 0u CHR 5,1 2160859 /dev/console
init 10766 root 1u CHR 5,1 2160859 /dev/console
init 10766 root 2u CHR 5,1 2160859 /dev/console
sh 10779 root cwd DIR 3,66 4096 2649025 /root
sh 10779 root rtd DIR 3,66 4096 2 /
sh 10779 root txt REG 3,66 587620 3303172 /bin/bash
sh 10779 root mem REG 3,66 15008 787128 /lib/libdl-2.3.3.so
sh 10779 root mem REG 3,66 50944 784945 /lib/libnss_files-2.3.3.so
sh 10779 root mem REG 3,66 11256 787147 /lib/libtermcap.so.2.0.8
sh 10779 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
sh 10779 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
sh 10779 root 0u CHR 5,1 2160859 /dev/console
sh 10779 root 1u CHR 5,1 2160859 /dev/console
sh 10779 root 2u CHR 5,1 2160859 /dev/console
sh 10779 root 255u CHR 5,1 2160859 /dev/console
lsof 11015 root cwd DIR 3,66 4096 2649025 /root
lsof 11015 root rtd DIR 3,66 4096 2 /
lsof 11015 root txt REG 3,67 95624 3916148 /usr/sbin/lsof
lsof 11015 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
lsof 11015 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
lsof 11015 root 0u CHR 5,1 2160859 /dev/console
lsof 11015 root 1w REG 3,66 4456 2649518 /root/memory-usage-init-1.txt
lsof 11015 root 2u CHR 5,1 2160859 /dev/console
lsof 11015 root 3r DIR 0,3 0 1 /proc
lsof 11015 root 4r DIR 0,3 0 721879049 /proc/11015/fd
lsof 11015 root 5w FIFO 0,5 20692 pipe
lsof 11015 root 6r FIFO 0,5 20693 pipe
lsof 11016 root cwd DIR 3,66 4096 2649025 /root
lsof 11016 root rtd DIR 3,66 4096 2 /
lsof 11016 root txt REG 3,67 95624 3916148 /usr/sbin/lsof
lsof 11016 root mem REG 3,66 105732 787157 /lib/ld-2.3.3.so
lsof 11016 root mem REG 3,66 1456128 787179 /lib/tls/libc-2.3.3.so
lsof 11016 root 4r FIFO 0,5 20692 pipe
lsof 11016 root 7w FIFO 0,5 20693 pipe
 
Old 06-13-2005, 08:37 PM   #8
Jimbo99
Member
 
Registered: Nov 2003
Distribution: Ubuntu 7.04
Posts: 241

Rep: Reputation: 31
All modern operating systems buffer disk access. They have for years and year. Going back to even DOS they buffered it. It has been available in protected mode Windows for as long as it has been out.

I do like how Linux uses ram instead of swapping to disk. Even though linux does appear to be comsuming gobs of ram I have not run out nor have I noticed my 1gig ram ever having run out even though Linux has reported massive amounts of it being used.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Toshiba Laptop/Fedora/KDE = 90% memory usage awing_pilot Linux - Laptop and Netbook 5 03-10-2005 05:51 PM
getting realtime info on memory usage-cpu and harddrive usage steering Linux - Newbie 5 03-03-2005 08:43 PM
how to determine cpu usage, memory usage, I/O usage by a particular user logged on li rags2k Programming 4 08-21-2004 04:45 AM
Memory Usage in X (Fedora Core 2) Chebyshev Linux - Software 4 07-31-2004 01:11 PM
Controlling CPU usage & memory usage Saravana babu Linux - Software 0 02-18-2004 05:55 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration