How find out information on memory usage

wordpress

#1

The admin panel for my wordpress blogs is loading very slowly. I received this message from support:

[/quote]

I’ve been advised to turn plugins on and off (which I am doing) and to look at detailed site statistics.

However, despite several email exchanges back and forth, I cannot seem to be able to understand how I might be able to access detailed site statistics so I can figure out what process or script is using memory.

I am lost at Step 1: Connect to somewhere using something.

Needless to say, I have unable to proceed to step 2. My question really is: Where are “somewhere” (as in some sort of address) and what “something” (browser? ftp device? etc.) do I use to connect to this place.

If there are options that involve a browser, and give me a graphical user interface, I’d prefer those. Thanks to anyone who can help!
Lucia (Feeling clueless.)


#2

I’m unaware of any web-based tool or log that would help with memory usage. The CPU Resources FAQ will help you debug CPU utilization problems.

The only think I can think of that would help is to log in to the shell using PuTTY, run top and hit a few of your pages while observing your processes run. Do this while turning each plugin turned on in turn to see how much extra memory it uses. Keep a notepad handy to record the results.

Sound like lab in school? Oh yes! Hopefully you won’t be like me and find that acceleration due to gravity at sea level is 98 meters per second per second. (I never figured out what I did wrong other than obviously figuring out that I moved a decimal point somewhere). Apologies if this is too heavy for you. :slight_smile:

The other thing you could do list list your plugins and I’m sure someone will be able to point out the ones that are potential problems.

Free unique IP and $67 off with promo code [color=#CC0000]FLENSFREEIP67[/color] or use [color=#CC0000]FLENS97[/color] for $97 off. Click here for more options


#3

Mike S told me my problem was very specifically not cpu but memory.

That said, I found the problem. It’s “aLinks”. A great plugin-- but evidently, it’s hogging something when I’m in the administration panel of Wordpress. Worse, I susect it is doing something useless, or at least doing something important but much, much more often than it should.

I’ll contact the developer and look at the plugin also.


#4

Good deal. I’m glad everything worked out.

I figured the CPU resources FAQ wouldn’t be directly applicable to your problem but I was sure if there was anything in there that would as a side-effect give you any information about memory utilization as well, since these two things are often measured at the same time by the same diagnostic tools.

Again, glad that you found and fixed the problem. I don’t run that particular plugin so I can’t really be of much help with it specifically.

Free unique IP and $67 off with promo code [color=#CC0000]FLENSFREEIP67[/color] or use [color=#CC0000]FLENS97[/color] for $97 off. Click here for more options


#5

I’m also having a memory problem my PS server. I get spikes im memory use that I don’t think are related to traffic surges. And I’m also kind of lost.

Does anyone have a clue of how to have some kind of log of the memory use? The graphics in the DH Panel don’t help much since they are not very detailed and seem to be slow to update.

I thought of something like the free command logged in a cronjob.

Decio.


Use promo code US97OFF to get maximum discounts!
Use o código de promoção US97OFF para descontos de até US97!


#6

If it’s not traffic surges it’s probably some particular process or script that runs that is a hog. Have you found a particular page that gets hit only around the time of a spike?

Does the spike happen at a particular time of day?

Does the spike correspond to your database backup or some other backup that you yourself run?

Extra lifetime domain and $82 off with code [color=#CC0000]1DOM82[/color] or use [color=#CC0000]LM97[/color] for $97 off. Other Dreamhost coupon codes


#7

You’re right, if it’s not traffic, it should be some process, but I have nothing running during the spikes and as far as DH could tell me, it has to do with apache.

From support:

[quote]
Most of your memory usage is from apache though. Apache is configured for
things like: MinSpareServers 5, MaxSpareServers 30, StartServers
5,MaxClients 100.

looking over your usage it seems apache keeping about 10 servers running
at a steady state. And each server is using 10Mb of memory. The spike in
memory might be due to lots of apache servers getting launched to deal
with requests. Moving back to shared is not a good idea, we should just
track down where the usage is coming from and adjust settings to deal
with it how you like. If it is bot or something we could block the bot.
Or if it is a comment spammer we could block them etc.

try running this command during a spike and let me see the output, we’ll
be looking for lots of extra apaches running:

ps aux | grep apache[/quote]

I actually didn’t have any spike since then. And DH thinks it might be bots or comment spammers.

I’m currently trying to understand this memory usage thing, trying to make sense of ps and top command. I really need to find a way to relate that to traffic at the very moment. Is it possible?

I have the feeling my traffic isn’t anywhere near how much memory apache is using. I haven’t added up yet, since my sites are located in different users, but isn’t much and not even anywhere near the guidelines described in http://www.dreamhostps.com/.

Something I’m curious about: Since my traffic is very related to time of day, why isn’t my memory usage the same?

Also, isn’t it normal for everybody to have traffic spikes during the day? Shouldn’t PS handle that better than shared ? I sites wouldn’t time out before as they do now during a spike.

Decio.


Use promo code US97OFF to get maximum discounts!
Use o código de promoção US97OFF para descontos de até US97!


#8

Are you hosting a static site or dynamic?

According to support, your memory usage is probably related to simultaneous apache handler threads that are spawned to handle traffic on your site.

I’m not sure what your question is. I think everyone has “traffic spikes” during the day but that PS handles it fine in most cases but just not yours for some reason that you’re currently investigating.

In my mind, PS is all about being able to reserve the exact amount of dedicated resources to handle your own site. Assuming you do that, your site will be rock solid and not affected by the other users who are sharing your physical server.

Unfortunately, if you reserve “less” memory than your sites need, it becomes very, very obvious and your site is limited/throttled (effectively) in order to protect the other users on your physical server.

The reason dreamhost suspects bots is because bots can cause steep traffic spikes. And by traffic spikes I mean that they can issue hundreds of requests virtually instantaneously. Obviously, even if each request is handled in less than a second but the bot issues 100 requests simultaneously to your site, your apache is going to spawn 100 handlers and try to suck up 1GB of memory. This memory request will fail.

Unkind bots are hell on your site.

Extra lifetime domain and $82 off with code [color=#CC0000]1DOM82[/color] or use [color=#CC0000]LM97[/color] for $97 off. Other Dreamhost coupon codes


#9

I’m hosting both dynamic and static sites, most of my traffic is static. I’ve tried crawling my dynamic ones and they seem to be really light on the server (as they should be).

What I mean about the differences, is that although my sites are much faster now, I have this unavailable events which didn’t happen in shared hosting. And if I have to reserve resources to be able to handle this spikes it would be too expensive (and my resources would be idle 90% of the time).

Very interesting your take on the bots, but I’m not sure what I would be able to do about that, since I need the search references. I read somewhere that Yahoo is the only one that has some slow down settings that can be configured in robots.txt.

I leaning towards purchasing a secondary shared account and transferring some sites less important sites over and see what it happens, but it would be a lot of work (unless DH does it for me) and I don’t really know if it would make much difference financially.

It just occurred to be that I should ask support if there’s some way I can shut down some sites and see what happens.

Decio.


Use promo code US97OFF to get maximum discounts!
Use o código de promoção US97OFF para descontos de até US97!


#10

I’m no expert on the subject, but here’s something I dug up with a little searching:

Extra lifetime domain and $82 off with code [color=#CC0000]1DOM82[/color] or use [color=#CC0000]LM97[/color] for $97 off. Other Dreamhost coupon codes