WordPress.org

Ready to get started?Download WordPress

Forums

Super slow mysql queries (4 posts)

  1. beisbolct
    Member
    Posted 5 years ago #

    All of the sudden, I am getting some ridiculous long query times and am not sure why. it causes my site to be suspended briefly due to the cpu exceeded error.

    I've changed the database name here for safety

    I am not sure what's causing this to happen all of the sudden. any ideas???

    # Sun Aug 3 19:29:57 2008
    # Query_time: 191 Lock_time: 42 Rows_sent: 1 Rows_examined: 0
    use ianbethu_wrdp
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 1571 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:31:47 2008
    # Query_time: 210 Lock_time: 190 Rows_sent: 0 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 2486 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:31:48 2008
    # Query_time: 173 Lock_time: 0 Rows_sent: 0 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_comments.* FROM wp_comments LEFT JOIN wp_posts ON ( wp_comments.comment_post_ID = wp_posts.ID ) WHERE post_status = 'publish' AND comment_approved = '1' ORDER BY comment_date_gmt DESC LIMIT 20

    # Sun Aug 3 19:31:48 2008
    # Query_time: 173 Lock_time: 158 Rows_sent: 0 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 3133 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:31:53 2008
    # Query_time: 132 Lock_time: 114 Rows_sent: 0 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 1895 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:31:54 2008
    # Query_time: 124 Lock_time: 106 Rows_sent: 1 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 1895 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:31:54 2008
    # Query_time: 123 Lock_time: 106 Rows_sent: 1 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 1895 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:31:56 2008
    # Query_time: 109 Lock_time: 93 Rows_sent: 1 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 2898 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:32:01 2008
    # Query_time: 99 Lock_time: 78 Rows_sent: 1 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 1773 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

    # Sun Aug 3 19:32:04 2008
    # Query_time: 137 Lock_time: 135 Rows_sent: 1 Rows_examined: 0
    use ianbethu_wrdp;
    SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID = 3133 AND wp_posts.post_type = 'post' ORDER BY wp_posts.post_date DESC

  2. beisbolct
    Member
    Posted 5 years ago #

    And to add this, this is what I am getting when i look the taxonmony table, the options table,

    The following indexes appear to be equal and one of them should be removed: term_id, term_id_3
    The following indexes appear to be equal and one of them should be removed: taxonomy, taxonomy_6
    The following indexes appear to be equal and one of them should be removed: PRIMARY, term_taxonomy_id_3
    The following indexes appear to be equal and one of them should be removed: taxonomy, taxonomy_5
    The following indexes appear to be equal and one of them should be removed: term_id, term_id_2
    The following indexes appear to be equal and one of them should be removed: PRIMARY, term_taxonomy_id_2
    The following indexes appear to be equal and one of them should be removed: taxonomy, taxonomy_4
    The following indexes appear to be equal and one of them should be removed: taxonomy, taxonomy_3
    The following indexes appear to be equal and one of them should be removed: taxonomy, taxonomy_2
    The following indexes appear to be equal and one of them should be removed: PRIMARY, term_taxonomy_id

    The following indexes appear to be equal and one of them should be removed: option_id, option_id_3
    The following indexes appear to be equal and one of them should be removed: option_id, option_id_2
    The following indexes appear to be equal and one of them should be removed: option_name, option_name_4
    The following indexes appear to be equal and one of them should be removed: option_name, option_name_3
    The following indexes appear to be equal and one of them should be removed: option_name, option_name_2

  3. beisbolct
    Member
    Posted 5 years ago #

    Does anyone have any ideas? It's getting frustrating to get emails saying my site is down.

  4. beisbolct
    Member
    Posted 5 years ago #

    I'm really wondering if anyone out there can help at all. My site is suffering because of these errors.

    Thank you very much.

Topic Closed

This topic has been closed to new replies.

About this Topic