Results 1 to 18 of 18
Thread: Do I need RAM?
-
10-04-2006, 04:40 PM #1Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
Do I need RAM?
My website was working fine, top speed, less CPU usage etc. However, recently I have had an increase in my traffic and now my website appears to load slow and my CPU is high most of the time. What could the problem be that is causing the slow load? Would I need RAM? How would I check if I need RAM or not?
Thanks
-
10-04-2006, 04:52 PM #2Retired Moderator
- Join Date
- Apr 2005
- Posts
- 3,499
Run free -m. If you are swapping a lot you should probably add some more RAM. Thats as good a guess I can give you without knowing a little more, like your server specs, your OS, and how your website delivers content (static or via php/mysql)?
Alex
-
10-04-2006, 05:30 PM #3Disabled
- Join Date
- Oct 2005
- Posts
- 29
vmstat or top come to mind.
-
10-04-2006, 06:13 PM #4Newbie
- Join Date
- Aug 2006
- Posts
- 21
RAM is important for loading processes, especially if you're using server-side scripting like PHP, CGI, etc. Though if the CPU usage is high i would consider upgrading the processor too
-
10-04-2006, 06:17 PM #5Predatory Poster
- Join Date
- Jul 2003
- Location
- Goleta, CA
- Posts
- 5,566
If you need more RAM you might as well get a faster harddrive so the transition from disk to memory is faster.
-
10-04-2006, 11:22 PM #6Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
>> free -m
total used free shared buffers cached
Mem: 1010 463 546 0 5 88
-/+ buffers/cache: 369 640
Swap: 2000 556 1443
Processor Information
Processor #1 Vendor: GenuineIntel
Processor #1 Name: Intel(R) Xeon(TM) CPU 2.80GHz
Processor #1 speed: 2801.543 MHz
Processor #1 cache size: 2048 KB
Processor #2 Vendor: GenuineIntel
Processor #2 Name: Intel(R) Xeon(TM) CPU 2.80GHz
Processor #2 speed: 2801.543 MHz
Processor #2 cache size: 2048 KB
Processor #3 Vendor: GenuineIntel
Processor #3 Name: Intel(R) Xeon(TM) CPU 2.80GHz
Processor #3 speed: 2801.543 MHz
Processor #3 cache size: 2048 KB
Processor #4 Vendor: GenuineIntel
Processor #4 Name: Intel(R) Xeon(TM) CPU 2.80GHz
Processor #4 speed: 2801.543 MHz
Processor #4 cache size: 2048 KB
-
10-04-2006, 11:28 PM #7Retired Moderator
- Join Date
- Apr 2005
- Posts
- 3,499
Yeah, you need to add more RAM. You're using about 2GB of SWAP, so you need at least another 1GB stick of RAM. Is this just one website on this server? If so, you may want to think about setting up some basic load balancing, with apache, mail, dns1, etc on one server and mysql and dns2 on the second server.
Alex
-
10-04-2006, 11:35 PM #8Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
Hello adb22791, I am real thankful for your advice. There is only 1 website hosted on the server. The thing is, I am newbie at this server management thing. If you can point me to the right direction of doing what you said then i'd appreciate that.
-
10-05-2006, 05:31 AM #9Newbie
- Join Date
- Dec 2004
- Posts
- 8
You defently need more ram.
at least 1GB more
-
10-05-2006, 07:43 AM #10Junior Guru
- Join Date
- Apr 2006
- Location
- Leicestershire, UK
- Posts
- 234
How many users online at once are we talking here ?
That is a lot of swap being used but you still have 640MB free RAM.
Maybe a faulty RAM Module ?www.NT-Hosts.net
Shared Hosting - Reseller - Email Hosting - Forum Hosting - Linux server admins
Phone: 07092898178 - Fax: 07092898179 - Email:Sales@NT-Hosts.net
-
10-05-2006, 12:37 PM #11Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
Every 5 minute there are on average 80 different IPs on the server. Each user uses 10-30 queries per visit.
-
10-05-2006, 01:00 PM #12Junior Guru Wannabe
- Join Date
- May 2002
- Location
- Kansas City, USA
- Posts
- 75
Looks like a pretty good box. My question would be, if you are running Linux, what kernel are you running. If you aren't running the proper kernel you won't be taking advantage of all those CPU's
Midwest Dedicated
Content Management Solutions, Design, Managed Servers
http://www.midwestdedicated.com
Providing the highest quality IT services since 1999.
-
10-05-2006, 01:25 PM #13Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
How would I go about finding what kernel I am using?
Webmaster Tools at iWEBTOOL.com
-
10-05-2006, 02:35 PM #14Retired Moderator
- Join Date
- Apr 2005
- Posts
- 3,499
I'm going to guess it's a stock kernel. You can find the version by typing:
Code:uname -r
Alex
-
10-05-2006, 06:18 PM #15Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
>>uname -r
2.6.9-34.ELsmpWebmaster Tools at iWEBTOOL.com
-
10-05-2006, 11:43 PM #16Web Host
- Join Date
- Jun 2002
- Posts
- 1,798
Not that one. You should update. That kernel has a problem with memory management that looks just like what you posted above. If all the ram isn't being used, it shouldn't be digging into swap like it is. Your only using half the ram and another 500mb swap. Not good.
-
10-07-2006, 07:36 PM #17Junior Guru Wannabe
- Join Date
- Mar 2005
- Posts
- 56
How would I update?
-
10-07-2006, 08:02 PM #18Web Host
- Join Date
- Jun 2002
- Posts
- 1,798
Quickest way is ask the data center to do it. If they won't you could hire someone. Or try it yourself.
If it's centos 4, which it probably is judging by that stock kernel, and cpanel, go to /etc/yum.conf and remove "kernel" so the line look like this:
exclude=courier* mysql* spamassassin* httpd* perl mysql* squirrelmail* php* mod_ssl* exim* pure-ftpd* proftpd*
All the steps:
pico /etc/yum.conf
(remove "kernel")
ctrl+o
ctrl+x
then type:
yum update
answer "y" to any questions
when its finished reboot
shutdown -r now
Find religion and pray it comes back up. If it does, add kernel back to the config file so it doesn't update every time you use yum update.