Web Hosting Talk







View Full Version : Do I need more memory


tariehk
01-16-2002, 04:36 PM
Hi,

Here is what I get when I do top:
3:26pm up 22 days, 15:17, 1 user, load average: 0.41, 0.16, 0.10
133 processes: 114 sleeping, 2 running, 0 zombie, 17 stopped
CPU states: 0.7% user, 3.5% system, 0.0% nice, 95.6% idle
Mem: 255048K av, 239172K used, 15876K free, 52K shrd, 7588K buff
Swap: 1052216K av, 89024K used, 963192K free
Do I need more memory? If so, please explain how you determined this.

Thanks.

zupanm
01-16-2002, 06:00 PM
no not at all. Linux will use most of your RAM anyway. So you don't have to worry about seeing it all being used. You'll need more memory when you see your load balances going up above 1 for a long period of time.

tariehk
01-16-2002, 06:27 PM
Thanks for the info. However, why does it show that I am using 84 MB of swap memory. I thought that should always be 0 and if I was using any memory from swap that is not good. Is that true?

MattF
01-16-2002, 07:41 PM
Using swap memory is bad. Generally linux will use anything upto 100% of your physical memory, linux make great use of available memory. However, when you're using more than 100%, i.e. going into swap, for an extended period of time, you should upgrade.

I recommend upgrading to 512mb.

myASPhosting
01-16-2002, 09:52 PM
Here is what ours currently says, and we have had no problems what so ever.

We reboot the server approximately every 30 days just for the heck of it to clean everything all up. NOTE: Only do this when you know you have no visitors on any clients site, especially shopping carts, etc.


7:52pm up 14 days, 20:54, 2 users, load average: 0.05, 0.01, 0.00
39 processes: 38 sleeping, 1 running, 0 zombie, 0 stopped
CPU states: 0.0% user, 0.3% system, 0.0% nice, 99.6% idle
Mem: 386144K av, 375864K used, 10280K free, 90396K shrd, 30412K buff
Swap: 265032K av, 1824K used, 263208K free 310248K cached

tariehk
01-17-2002, 12:03 AM
Thanks. So do you recommend that I upgrade from what top saids?

astanley
01-17-2002, 12:11 AM
Based on the information you gave, I would recommend an upgrade - using 84 megs of swap is a decent amount of swap space. However, before upgrading I would recommend running the vmstat command - this will show Disk writes/reads, swap writes/reads, as well as memory usage for a given interval (ie: vmstat 5 shows 5 second updates). What you are going to look for from this command is alot of changing in the si / so numbers - this represents the swap in / out (reads / writes)...if this is constant above 0, I would definitely recommend an upgrade. The theory is to keep disk reads/writes down as much as possible in order to increase performance - unless you are using a SCSI drive, or an entirely seperate drive for swap, and then you have a little bit of room to play with, however, using an IDE bus if you have frequent swap data, your webserving speed will suffer.

-Adam

zupanm
01-17-2002, 11:55 AM
no need to upgrade. linux uses all the memory and will go into swap if you run a webserver for caching and better io. ONLY upgrade if your load goes up