WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#5382 closed defect (bug) (invalid)

"MySQL server has gone away" error when trying to post anonymous comment

Reported by: meonkeys Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.3.1
Component: General Keywords: fastcgi
Focuses: Cc:

Description

Description

Can't post comments anonymously.

Steps to reproduce

  1. Install WordPress 2.3.1, MySQL 5.0.x, and enable FastCGI
  2. Try to post an anonymous comment

Expected result

  1. Comment is placed in queue for moderation (if this is enabled)
  2. User is redirected and can see their comment posted

Actual result

error message appears in browser window:

WordPress database error: [MySQL server has gone away]
SELECT * FROM wp_comments WHERE comment_ID = '11690' LIMIT 1

Warning: Cannot modify header information - headers already sent by (output started at .../wp-includes/wp-db.php:160) in .../wp-comments-post.php on line 67

Warning: Cannot modify header information - headers already sent by (output started at .../wp-includes/wp-db.php:160) in .../wp-comments-post.php on line 68

Warning: Cannot modify header information - headers already sent by (output started at .../wp-includes/wp-db.php:160) in .../wp-comments-post.php on line 69

Warning: Cannot modify header information - headers already sent by (output started at .../wp-includes/wp-db.php:160) in .../wp-includes/pluggable.php on line 392

(modified slightly: ellipses replace private path information on server)

Reproducability

Always.

Workaround

Disabling FastCGI appears to fix the issue.

Additional information

This bug was originally reproduced using a Bluehost-hosted blog at http://adammonsen.com. It is unclear if this is issue is specific to Bluehost.

software versions used in this repro

  • WordPress 2.3.1
  • MySQL 5.0.37
  • FastCGI (mod_fastcgi) 2.4.2
  • Apache 1.3.39

Related posts in support forum

Change History (2)

comment:1 santosj6 years ago

This does not appear to be an WordPress issue, but I'm not going to close it. FastCGI is not part of WordPress. This issue affects other web applications and does not have a trival fix.

You can use caching and see about setting the amount of database connections higher or seeing what load the database has.

comment:2 DD326 years ago

  • Milestone 2.6 deleted
  • Resolution set to invalid
  • Status changed from new to closed

Closing as Invalid; Not a WordPress issue(But infact, MySQL settings, or PHP Config relating to MySQL), See #5932 for an outdated fix.

Note: See TracTickets for help on using tickets.