Solved

Lost connection to MySQL server during query

Posted on 2009-06-30
5
655 Views
Last Modified: 2012-05-07
Creating an asp.net web app against mysql database (with webhost4life hosting).

Locally the data pages work great.  I can add, edit and delete data fine.

After I deploy it, using the production mysql db I keep getting this error when trying to add data:

Lost connection to MySQL server during query

It is a simple add record!  How can I fix this?  Is a timeout happening?  Again, a SIMPLE SQL INSERT!  (Using xsd dataset in VS 2008 with a business class accessing the xsd query.)
0
Comment
Question by:RobertNZana
  • 2
  • 2
5 Comments
 

Expert Comment

by:nrazon
ID: 24749952
Sometimes when a table or index corruption can give same results (lost connection to mysql query).

My suggestion is to optimize, repair or recreate table again.
(Backup if you have data in tables or create new copy of tables and change your application to use new tables to test)
0
 
LVL 33

Expert Comment

by:snoyes_jw
ID: 24751486
Before doing all that, check MySQL's error log and see if the server crashed and restarted right about then. It might be a known bug.
0
 
LVL 9

Author Comment

by:RobertNZana
ID: 24751665
I am using webhost4life hosting.  Do you know how I can check their logs?
0
 
LVL 33

Expert Comment

by:snoyes_jw
ID: 24754340
Usually you must email or open a trouble ticket and ask.
0
 
LVL 9

Accepted Solution

by:
RobertNZana earned 0 total points
ID: 24800636
I upgraded my connector to the latest at devart.com and it seems to have fixed it.  Plus I added a timeout in the web.config.
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

A quick way to get a menu to work on our website, is using the Menu control and assign it to a web.sitemap using SiteMapDataSource. Example of web.sitemap file: (CODE) Sample code to add to the page menu: (CODE) Running the application, we wi…
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now