Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2009
    Posts
    1

    Unanswered: high load averages caused by mysql

    Here's some information:

    Code:
    Web Server with Apache 2.2.
    Mysql ver. 5.0.45 via socket on x86_64 centos 5.2, 1 CPU 4core with 4 Gb RAM, 3Tb SATA disk space
    Real memory 3.86 GB total, 1.38 GB used
    Virtual memory 4 GB total, 288 kB used
    Code:
    [root@server init.d]# top
    top - 14:59:07 up 1 day, 34 min,  1 user,  load average: 9.94, 10.91, 11.07
    Mem:   6231956k total,  4825868k used,  1406088k free,   410000k buffers
    Swap:  2040212k total,        0k used,  2040212k free,  3164740k cached
    
      PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
    24804 mysql     16   0 1451m 410m 4476 S 132.5  6.7   1468:33 mysqld
     4874 root      16   0  5400 2800 1308 S  0.0  0.0   0:19.15 hald
    These are the red marked rows on Runtime Information in phpMyAdmiin
    Code:
    Slow_queries  	14 k
    Innodb_buffer_pool_reads  	33
    Handler_read_rnd  	24 M
    Handler_read_rnd_next  	3,316.21 M
    Slow_launch_threads  	2
    Created_tmp_disk_tables  	3,624 
    Select_full_join  	621
    Select_range_check  	1 
    Opened_tables  	12 k
    Table_locks_waited  	17 k
    At the moment I'm setting up slow log to detect the slow queries.

    phpMyAdmin on high Handler_read_rnd_next:
    The number of requests to read the next row in the data file. This is high if you are doing a lot of table scans. Generally this suggests that your tables are not properly indexed or that your queries are not written to take advantage of the indexes you have.
    So I am going to check the indexing of tables.
    The biggest table has over 40,000 rows.

    I appreciate any suggestions and help.

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    i think the answers you've already received here are pretty decent...

    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •