Previously Al Dykes said:
Al Dykes said:
[...]
Al, I am moving stuff to a new server, so no legacy problems.
The perf tool on *nix (top) shows that cpu is running cool. Linux
grabs memory as much as it can, and I don’t think that is the problem.
The IO however maxes out with large queries. So that’s why looking
for a better disk IO solution.
As I said, most slow servers are disk-bound. I agree.
O.K., definitely a disk-bottleneck.
Measuring memory is tricky becuase, as you say, the server will grab
all it can, but there is a point of diminishing returns and your
system may have have reached it. It's nice to have "too much".
Finding and eliminating bottlenecks is an art.
Linux allways grabs all memory and uses it for the buffer-cache. The
real usage numbers are displayed by "free":
wagner@gate:~$free
total used free shared buffers cached
Mem: 507556 504588 2968 0 2332 431408
-/+ buffers/cache: 70848 436708
Swap: 0 0 0
The -/+ line tells the strory without what the buffer-cache uses.
The memory for the buffer-cache will be dynamically adjusted and
basically uses what is unused (althought sometimes that does not work
quite correctly).
Also in "top" you have VIRT, RES and SHR numbers for memory per
process. VIRT is the complete size, RES is the physical RAM in use
witout SHR. It gets more complicates, since SHR ist the RAM that is
being used together with other processes (Libraries, Code from
parents, etc) and does count only once. In addition VIRT shows all
allocated memory. Unused memory does not reside in RAM or on SWAP.
Example:
top - 13:47:53 up 239 days, 12:51, 1 user, load average: 1.12, 0.85, 0.54
Tasks: 60 total, 1 running, 59 sleeping, 0 stopped, 0 zombie
Cpu(s): 9.7% us, 7.6% sy, 21.9% ni, 58.9% id, 0.5% wa, 0.3% hi, 1.1% si
Mem: 507556k total, 504164k used, 3392k free, 3704k buffers
Swap: 0k total, 0k used, 0k free, 430188k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
8229 wagner 15 0 2056 940 1844 R 1.9 0.2 0:00.02 top
1 root 16 0 1500 460 1344 S 0.0 0.1 1:24.40 init
'top' is 2056kB big (process area), uses 940kB of RAM just for itself
and uses 1844 kB together with other processes. The SHR is not part
of the VIRT number, since the SHRed memory does not belong to a specific
process. Obviously top does only use its RESident memory, since
swap usage is zero.
Also you can add/remove fields in top with 'f'. While it is possible to
get a summary from 'top', using 'free' is a bit easier ;-)
I agree. It will be faster. How much is impossible to tell without
realistic benchmarks for your application. Also get the mamimum
amount of memory you can. You might also try a newer kernel. Quite
some things have happened to the buffer-cache. 2.6.11 is pretty
stable. I had ptoblems with 2.6.8 ... 2.6.10.
2.6.7 was also pretty o.k..
Arno