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.

Odd MySQL Usage

Discussion in 'General Discussion' started by billy79, May 25, 2007.

  1. billy79

    billy79 Active Member

    Joined:
    Dec 15, 2004
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    I have a customer on a Dual Dempsey 3.0GHZ (4 cores total) machine with 8GB of RAM.

    He runs a forum and some other software on his site, and almost all of it uses MySQL. His machine runs pretty good however at times it does seem to bottelneck a little, and I think it probably bottlenecks a little more then it should considering he is only pushing about 2.5mbps with the box.

    What happens is that his machine will be runnign just fine with a low load, 0.05 to .50 and then all of a sudden it will spike to about 2.5 or 3.5 I personally can't tell the difference in any sites load speed as long as the box has a load under 5.0 but the customer does notice a difference.

    Now when the load spikes like that the only thing in top that is really consuming CPU usage is MySQL, when the load spikes it will be consuming 120% to 500% of cpu.

    Now here is the really wierd part...if I do a mysqladmin processlist.....almost all of the connections are sleeping. I have personally verified that all of the scripts on the server are NOT using persistant connections.

    Furthermore in my my.cnf I have a connect_timeout set to 10.

    So what I am looking for is any ideas of things within my MySQL configuration that could both contribute to the way MySQL is handles on this box and also any things I should look for as to why the connections are not being killed.

    I do have hyperthreading disabled in the bios by the way and here is my my.cnf

    [mysqld]
    thread_concurrency=8
    max_connections=800
    myisam_sort_buffer_size=32M
    table_cache=768
    wait_timeout=8
    thread_cache_size=80
    tmp_table_size=256M
    connect_timeout=10
    max_allowed_packet=128M
    max_connect_errors=10
    query_cache_limit=2M
    query_cache_size=64M
    query_cache_type=1
    flush_time=3600
    set-variable=local-infile=1

    [mysql.server]
    user=mysql

    [mysqld_safe]
    open_files_limit=8192

    [mysqldump]
    quick
    max_allowed_packet=16M

    [myisamchk]
    key_buffer=64M
    sort_buffer=64M
    read_buffer=16M
    write_buffer=16M

    [mysqlhotcopy]
    interactive-timeout

    Thx in advance for your help and advice.

    -Billy
     
  2. SupaDucta

    SupaDucta Active Member

    Joined:
    Oct 6, 2004
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    6
    Noticed it on CentOS 4 after cPanel's update, mySQL stops respecting timeout values.

    Simple 'rpm -Uhv --force'-ing the same MySQL RPMs as those already installed settles the matter. Until next update (I'm not sure whether it's upcp, I think it is).

    Nasty thing, causing problems.
     
Loading...

Share This Page