Re: Defrag? Constant HD accessing?




Chris wrote:
news@xxxxxxxxxxxxxx wrote:
David L. Johnson wrote:
On Sat, 01 Apr 2006 13:08:30 +0000, Harold Stevens wrote:

[snip]

Thanks for all the replies, all!
According to TOP, I have 1.5GB of swap, and at this moment 1.2GB is
used.
Actually. here it is:
top - 09:16:54 up 31 days, 21:43, 6 users, load average: 1.95, 1.99,
2.08
Tasks: 146 total, 3 running, 139 sleeping, 0 stopped, 4 zombie
Cpu(s): 84.0% us, 13.7% sy, 0.0% ni, 2.0% id, 0.0% wa, 0.3% hi,
0.0% si
Mem: 774928k total, 765060k used, 9868k free, 5124k
buffers
Swap: 1540088k total, 1254012k used, 286076k free, 124224k cached

Is your swap usage always this high? If it is you need more RAM asap.

You know, I don't know. I think so.
But, see below for an update on that....


No, I generally don't use any big video or audio files. I mean, I use
XMMS to listen to MP3's, and that's about it. All I mainly do on this
machine is PHP/mySQL development.
Zend Studio uses Java, and when it loads it tends to "thrash" a bit,
but not much.

Well something is using up near on 2gig of memory most of which is
having to reside on your hard disk as 'virtual memory'. What does the
rest of top show about which apps are using the most memory? Also do a
'ps aux --sort vsz'.


Well, here's what it said for last several items:
apache 4787 0.0 0.1 26988 1544 ? S Mar02 0:00
/usr/sbin/httpd
apache 4788 0.0 0.1 26988 1544 ? S Mar02 0:00
/usr/sbin/httpd
liam 28996 0.0 0.8 27944 6228 ? S 10:16 0:00 kio_sftp
[kdeinit] sftp /tmp/ksocket-liam/klaunchertRdN3b.slave-socket
/tmp/ksocket-liam/konquerorQOGxjb.slave-socket
liam 7307 0.0 0.8 30600 6260 ? S Mar02 0:21
kio_uiserver [kdeinit]
liam 5792 0.0 0.8 33296 6224 ? S Mar02 3:35 kded
[kdeinit]
liam 7542 0.0 0.3 34816 2364 ? S Mar02 1:20 knotify
[kdeinit]
liam 7545 0.0 0.2 44928 1816 ? S Mar02 0:22
/usr/bin/artsd -F 16 -S 4096 -s 1 -m artsmessage -c drkonqi -l 3 -f
liam 25413 0.0 1.9 49812 15220 ? Sl Mar22 0:22 nautilus
file:///home/liam/Downloads/Pink%20Floyd%20-%20ALL
liam 1483 0.0 1.1 51000 8624 ? S Mar31 0:42 gaim
liam 12884 0.0 0.7 51656 5812 ? S Mar03 3:43
/usr/bin/kget
http://media22a.libsyn.com/podcasts/fireflytalk/fireflytalk_020_20060302.mp3
liam 20767 0.1 1.0 62636 8152 ? S Mar29 6:52
/usr/lib/opera/plugins/operamotifwrapper-1 27 30
/usr/lib/opera/plugins/libflashplayer.so
liam 5113 0.5 2.0 66408 15848 ? Sl Mar27 56:12 skype
liam 6778 0.0 3.1 68128 24504 ? Sl Mar02 4:41
gnome-terminal
liam 6666 0.2 4.6 70452 36092 ? S Mar02 92:18
akregator
liam 5782 0.0 5.1 83528 40188 ? S Mar02 9:32
konqueror
liam 6835 0.0 0.6 93236 4720 ? Sl Mar02 27:29 xmms -e
%F
root 3246 0.0 0.2 97932 2092 ? S Mar27 0:01 smbd -D
mysql 4602 0.0 0.1 105280 1404 ? Sl Mar02 3:39
/usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql
--pid-file=/var/lib/mysql/WEBDEV01.pid --skip-locking --socket=/vliam
20728 0.5 7.5 149100 58336 ? S Mar29 40:11
/usr/lib/opera/8.52-20060201.5/opera -style keramik
liam 31103 0.2 11.6 192600 90376 ? Sl Mar23 43:13
/usr/lib/thunderbird/thunderbird-bin
root 5392 12.8 11.7 216552 91164 ? S Mar02 5919:31
/usr/X11R6/bin/X :0 -audit 0 -auth /var/gdm/:0.Xauth -nolisten tcp vt7
liam 31379 0.0 6.2 219904 48160 ? Sl Mar23 11:30
/usr/lib/firefox/firefox-bin %u
liam 28257 0.3 0.2 283196 1596 ? Sl Mar30 17:00 java_vm
liam 6060 27.9 6.0 456844 46652 ? Rl Mar02 12861:27
/opt/openoffice.org2.0/program/soffice.bin -writer
liam 13205 0.1 8.7 498860 67972 ? Sl Mar09 46:01
/usr/local/Zend/ZendStudioClient-5.1.0/jre/bin/java -Xmx268435456
-Xms16777216 com.zerog.lax.LAX /usr/local/Zend/ZendStudioClient-5.liam
5778 0.4 2.4 627640 18840 ? S Mar02 193:37
/usr/bin/xfce4-panel

I could certainly shut down apache, as this is just a workstation and
doesn't need the Web server. But all the rest of that stuff is needed.
(Well, OK, XMMS isn't _needed_, but it sure makes work a little more
bearable. *grin*)

But when I come in in the morning each day, the PC will be slow slow
slow to the point of not being able to even use the GUI at all for
minutes while the HD thrashes like crazy.

I'm not surprised! Your machine seems to be constantly using a large
chunk of virtual memory for your running apps. This is not good for
performance.

You need to find out what is using all this memory (real and virtual)
and then work out whether this is a 'normal' amount of usage for you. If
it is then buy more RAM, if it isn't try and find out why it is using so
much memory (possible memory leak).

If you reboot and load all you usual apps how much memory is being used
then?

Well, I found another stick of 256MB. So now I have 1GB of RAM.
I restarted all the programs I had open before I rebooted, and not the
top of top looks like this:

top - 10:52:26 up 12 min, 6 users, load average: 0.90, 0.83, 0.56
Tasks: 124 total, 1 running, 123 sleeping, 0 stopped, 0 zombie
Cpu(s): 11.9% us, 0.3% sy, 0.0% ni, 87.9% id, 0.0% wa, 0.0% hi,
0.0% si
Mem: 1035020k total, 853748k used, 181272k free, 32196k
buffers
Swap: 1540088k total, 0k used, 1540088k free, 461840k cached

Much better!
I can already see some performance improvement.
The true test will be tomorrow morning when I come in and shake the
mouse to un-screensave and see how long it takes before I can actually
use the GUI.
I'm sure there may be a little thrashing, but more than several seconds
of constant HD use and no ability to use the GUI will likely mean
something is still out of whack.
But, I'm optimistic!

Thanks again, all! I really appreciate all the feedback and advice!
-Liam

.



Relevant Pages

  • Re: Memory
    ... my memory last night was up to 2GB - I expected a basic system to ... and swap space to the right. ... that are buffers and cache. ... As memory is consumed by applications, it pushes the buffers and cache to ...
    (Fedora)
  • Re: whats making executables so large?
    ... each shared library mapped to a separate memory page and memory page ... Swap space, VM, and shared memory usage a _complicated_ swamp. ... 'virtual memory' is more than the disk size of the executable ... The situation is 'sort of' like shared libraries. ...
    (comp.unix.bsd.freebsd.misc)
  • Re: Heaps and Foreigners
    ... >> can ask for the memory and get a pointer to it. ... cause unfathomable deaths when swap space gets low or is exhausted. ... It's probably because there is some reserve memory to print out errors ... of RAM and disk space) and virtual swap (which is just a number managed ...
    (comp.lang.lisp)
  • Re: [kde-linux] VM and Swap problems
    ... swap is half full the system starts removing swap until it is exactly ... Maybe one of your applications leak memory (I have a webpage ... to two times RAM. ... Unused memory will be used as disk buffers. ...
    (KDE)
  • Re: [PATCH] io-controller: Add io group reference handling for request
    ... Find the io group bio belongs to. ... anonymous pages (swap) you still need the page tracking functionality ... so fair to charge the current task for the whole activity. ... is some other memory hungry application which is forcing these swap outs. ...
    (Linux-Kernel)