The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Help my MySQL usage going to 113% CPU usage

Discussion in 'General Discussion' started by mm1250, Mar 18, 2008.

  1. mm1250

    mm1250 Well-Known Member

    Joined:
    Nov 10, 2006
    Messages:
    108
    Likes Received:
    0
    Trophy Points:
    16
    Hello,

    I have the oddest problem with my server. It seems ever since I upgraded to MySQL 5 things have been a litle odd with it. I was watching top today on my server and noticed on 2-3 times that mysql would jump to 113% CPU. I'm not sure how this is possible to be honest but at any rate thats not normal. I also get MySQL taking up 20-30% most of the time. I'm trying to figure out who in the world is eating my MysQL.

    So I logged into WHM to view MySQL processes, thinking there must be like 100 sessions but I was surprised to see only this:

    Id User Host db Command Time State Info
    1 eximstats localhost eximstats Sleep 133 NULL
    539588 leechprotect localhost leechprotect Sleep 25579 NULL
    572954 eximstats localhost eximstats Sleep 1472 NULL
    574481 cphulkd localhost cphulkd Sleep 5 NULL
    574488 root localhost NULL Query 0 NULL SHOW PROCESSLIS

    So my question is, what in the world is causing my MySQL to eat my CPU like there is no tomorrow?
     
  2. mctDarren

    mctDarren Well-Known Member

    Joined:
    Jan 6, 2004
    Messages:
    664
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    New Jersey
    cPanel Access Level:
    Root Administrator
    You could turn on mysql query logging to find out.
     
  3. yamaharr1

    yamaharr1 Well-Known Member

    Joined:
    Jun 22, 2007
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    Mine did the same thing it lasted for about 6 hours until everything updated by the next day all was back to the way it was before the update.
     
  4. mm1250

    mm1250 Well-Known Member

    Joined:
    Nov 10, 2006
    Messages:
    108
    Likes Received:
    0
    Trophy Points:
    16
    No, I don't think it is still upgrading as I did the upgrade about 3 weeks ago.
     
  5. Kent Brockman

    Kent Brockman Well-Known Member

    Joined:
    Jan 20, 2008
    Messages:
    1,130
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Buenos Aires, Argentina
    cPanel Access Level:
    Root Administrator
    Twitter:
    did you tried restarting mysql?
    what values are in your server load?

    In the unix shell run mysqladmin proc stat and post here the result.

    You also should check if some domain is having too many queries and you have just not enough memory to work fluidly.

    In the worst scenario, it may be a DDoS atack via sql.
     
Loading...

Share This Page