10bet网址
MySQL 8.0 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr)- 41.6Mb
PDF (A4)- 41.7Mb
Man Pages (TGZ)- 262.2Kb
Man Pages (Zip)- 372.3Kb
Info (Gzip)- 4.0Mb
Info (Zip)- 4.0Mb
Excerpts from this Manual

5.9.2 Debugging a MySQL Client

To be able to debug a MySQL client with the integrated debug package, you should configure MySQL with-DWITH_DEBUG=1. SeeSection 2.9.7, “MySQL Source-Configuration Options”.

Before running a client, you should set theMYSQL_DEBUGenvironment variable:

shell> MYSQL_DEBUG=d:t:O,/tmp/client.trace shell> export MYSQL_DEBUG

This causes clients to generate a trace file in/tmp/client.trace.

If you have problems with your own client code, you should attempt to connect to the server and run your query using a client that is known to work. Do this by runningmysqlin debugging mode (assuming that you have compiled MySQL with debugging on):

shell> mysql --debug=d:t:O,/tmp/client.trace

This provides useful information in case you mail a bug report. SeeSection 1.6, “How to Report Bugs or Problems”.

If your client crashes at some 'legal' looking code, you should check that yourmysql.hinclude file matches your MySQL library file. A very common mistake is to use an oldmysql.hfile from an old MySQL installation with new MySQL library.