Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject: graphing
PostPosted: Thu Sep 08, 2011 6:55 pm 
Offline
Junior Member

Joined: Fri Jul 08, 2011 7:46 pm
Posts: 44
Website: http://ericsonwilkinson.me
Location: United States
mattm wrote:
Here you can see my graphs before the system seized up for running out of memory.

https://skitch.com/mattmm/fsi1f/linode- ... node124975


Sorry to be off topic, but I'm looking to start monitoring my box too, what are you using to generate these graphs, and does it use a web interface?

Thanks!


Top
   
 Post subject:
PostPosted: Thu Sep 08, 2011 7:44 pm 
Offline
Senior Member
User avatar

Joined: Sat Aug 30, 2008 1:55 pm
Posts: 1739
Location: Rochester, New York
Those look like the "plain ol'" Linode graphs, generated using RRDTool based on telemetry from Linode's SCADA [1]. RRDTool is probably the de facto standard in the *nix world for collecting, managing, and graphing time series data sampled on regular intervals using a round-robin database. Munin and Cacti are two great systems that use RRDTool under the hood.

Image

There's also the Graphite system, which uses its own round-robin database system, Whisper. This is an entirely different bowl of cherries, built for scale and speed, and serves as the foundation of some religions, e.g. Etsy's Church of Graphs.

Image

... but if you just want the graphs from the original poster, log into the Linode Manager and click on your Linode, then scroll down.

[1] I think SCADA is an appropriate term to describe "the things between {api,manager}.linode.com and the hypervisor". Just because it controls the flow of clouds instead of molasses doesn't mean it's not industrial.

_________________
Code:
/* TODO: need to add signature to posts */


Top
   
 Post subject: doh
PostPosted: Thu Sep 08, 2011 7:52 pm 
Offline
Junior Member

Joined: Fri Jul 08, 2011 7:46 pm
Posts: 44
Website: http://ericsonwilkinson.me
Location: United States
lol I realized after I posted that it was the same graph from the linode manager.

I'm thinking about using awstats, wow I haven't heard of any of those. Thanks for the suggestions


Top
   
 Post subject:
PostPosted: Thu Sep 08, 2011 11:39 pm 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
Guspaz - great insight as always.

I was thinking smush.it as well - just worried about load on the server as I SMUSH them.

mod_deflate might make some sense as well. I'll give it a go with your suggestions of Max Clients.

I'm assuming if I max it all out I could hit a threshold of clients not loading the site at all because all of Apache is busy. No way to track that I'm assuming since they won't actually hit the apache server?


Top
   
 Post subject:
PostPosted: Thu Sep 08, 2011 11:46 pm 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
to that last point, at this off peak hour, my report from apache:


72 requests currently being processed, 4 idle workers


Top
   
 Post subject:
PostPosted: Thu Sep 08, 2011 11:48 pm 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
thinking past apache, I could jump on the LEMP bandwagon...


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 12:02 am 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
Thoughts on mod_cache and MPM Prefork?


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 7:40 am 
Offline
Newbie

Joined: Mon Sep 05, 2011 8:00 am
Posts: 2
Website: http://linuxaria.com
If you are using WP, check w3 total cache + APC, it's a solution i'm using and it gives some benefit.

I use it on LEMP ;)


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 10:20 am 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
Yea I Was going to check out W3 when I put Cloudflare in front. Apparently they work together which is good.


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 11:50 am 
Offline
Senior Member

Joined: Wed Jul 21, 2010 8:04 pm
Posts: 119
mattm wrote:
I'm assuming if I max it all out I could hit a threshold of clients not loading the site at all because all of Apache is busy. No way to track that I'm assuming since they won't actually hit the apache server?


I run a cron job once a day to search the Apache error log for MaxClients.

Code:
sudo grep MaxClients /var/log/apache2/error.log


I hardly ever get anything, but occasionally I get 1 or 2 entries. So, not a big deal. If it were a lot entries though, I'd be worried.


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 12:34 pm 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
Code:
[Sun Sep 04 21:47:33 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Mon Sep 05 23:46:00 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Tue Sep 06 07:24:34 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Tue Sep 06 07:58:09 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Tue Sep 06 09:32:25 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Wed Sep 07 05:27:50 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Wed Sep 07 07:12:51 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Wed Sep 07 08:53:30 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Thu Sep 08 01:37:39 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Thu Sep 08 13:07:52 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Thu Sep 08 16:47:57 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Fri Sep 09 09:13:55 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Fri Sep 09 10:38:25 2011] [error] server reached MaxClients setting, consider raising the MaxClients setting


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 5:00 pm 
Offline
Senior Member
User avatar

Joined: Tue May 26, 2009 3:29 pm
Posts: 1691
Location: Montreal, QC
I believe you had earlier enabled keepalives, you're going to want to disable those, since they consume slots that don't otherwise need to be in use. Beyond that, you do have some room to play with, so you can increase your maxclients to where you feel comfortable. Take a look at how much RAM your larger apache processes are taking up, and increase it (leaving a good chunk of RAM free for disk caching in your calculations). For example, if your larger Apache processes are 80MB each, then on a 4096, maybe a maxclients of 40 would be acceptable.

One thing you can also consider doing is switching apache from mpm_prefork to mpm_worker, which is a lot more efficient, but more difficult to set up. It requires setting up PHP as a fastcgi (usually using FPM, I believe) since PHP doesn't like multithreading, and there are some other considerations to take into account, but it saves a ton of RAM because you pick the number of PHP processes, and you don't need a copy of PHP loaded into RAM just to handle a static request.

For much help in tweaking Apache beyond this, you'd really have to turn to the Apache wizards around here. I'm a lighttpd user, and many people around here use nginx, both of which are single-process single-threaded servers; you don't have to manage any of this stuff to the same extent because they're much simpler, but I'm a bit biased because I've been using lighttpd for a *very* long time.

In terms of load concerns regarding smush.it, I'm not sure I follow; it's not an active service that you integrate, it's just an image processing tool. You upload your images, it optimizes them, you download the result. Smaller images won't really help your server load, just your bandwidth bill, and probably not dramatically (but every bit helps, right? A bit from smush.it here, a bit from mod_deflate there, a bit from javascript minifiers there, it all adds up)


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 10:51 pm 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
awesome, thanks for this.

as for smush.it I meant the server load as it optimizes the images (cpu crunching images etc) but maybe if I'm reading correctly, Yahoo's servers do this.

I'm switching to Cloudflare + Wc3 cache tomorrow morning to see how it handles.

I'm also considering nginx as an alternative


Top
   
 Post subject:
PostPosted: Fri Sep 09, 2011 11:00 pm 
Offline
Junior Member

Joined: Sun Mar 21, 2010 11:19 pm
Posts: 45
Also to the MaxClients note - I don't think 40 would work because of the amount of traffic the site gets.

Currently, at an off peak time, the http count is:

Code:
root@li [~]# pidof httpd | wc -w
74


I'm at MaxClients = 100 right now.

I do have keep alive off as well.


Top
   
 Post subject:
PostPosted: Sat Sep 10, 2011 9:05 am 
Offline
Senior Member
User avatar

Joined: Tue Nov 24, 2009 1:59 pm
Posts: 362
Guspaz wrote:
It requires setting up PHP as a fastcgi (usually using FPM, I believe)

Just remember to use mod_fastcgi, not mod_fcgid. FPM is not necessary at all, tho it'd probably help. I'll tell you in a year or so after the next Debian upgrade, 6.0.x doesn't have FPM. ;)

_________________
rsk, providing useless advice on the Internet since 2005.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group