Home > database >  The mysql database problems
The mysql database problems

Time:09-27

I'm ali cloud has built the mysql database server, mainly for the JAVA collector stored data, production data storage table has four, usually have lots of inserts, the other for management table and the composition table, this several days suddenly acquisition program error an error is as follows:
Com.mysql.jdbc.exceptions.jdbc4.Com municationsException: Communications link failure
The last packet successfully received from The server was 239 milliseconds line. The last packet sent successfully to The server was 239 milliseconds line.
At sun. Reflect. NativeConstructorAccessorImpl. NewInstance0 (Native Method)
At sun. Reflect. NativeConstructorAccessorImpl. NewInstance (NativeConstructorAccessorImpl. Java: 62)
At sun. Reflect. DelegatingConstructorAccessorImpl. NewInstance (DelegatingConstructorAccessorImpl. Java: 45)
The at Java. Lang. Reflect. Constructor. NewInstance (422) Constructor. Java:
At com. Mysql. JDBC. Util. HandleNewInstance (Util. Java: 404)
At com. Mysql. JDBC. SQLError. CreateCommunicationsException (SQLError. Java: 981)
At com. Mysql. JDBC. MysqlIO. ReuseAndReadPacket (MysqlIO. Java: 3465)
At com. Mysql. JDBC. MysqlIO. ReuseAndReadPacket (MysqlIO. Java: 3365)
At com. Mysql. JDBC. MysqlIO. CheckErrorPacket (MysqlIO. Java: 3805)
At com. Mysql. JDBC. MysqlIO. SendCommand (MysqlIO. Java: 2478)
At com. Mysql. JDBC. MysqlIO. SqlQueryDirect (MysqlIO. Java: 2625)
At com. Mysql. JDBC. ConnectionImpl. ExecSQL (ConnectionImpl. Java: 2547)
At com. Mysql. JDBC. StatementImpl. ExecuteUpdateInternal (StatementImpl. Java: 1541)
At com. Mysql. JDBC. StatementImpl. ExecuteLargeUpdate (StatementImpl. Java: 2605)
At com. Mysql. JDBC. StatementImpl. ExecuteUpdate (StatementImpl. Java: 1469)
At com. Data. ZFCG. DataBaseHelper. Dedup_Add_table (DataBaseHelper. Java: 1902)
At com. Data. ZFCG. MyJob. Gettitle (myJob. Java: 300)
At com. Data. ZFCG. MyJob. Execute (myJob. Java: 122)
The at org. Quartz. Core. JobRunShell. Run (JobRunShell. Java: 202)
The at org. Quartz. Simpl. SimpleThreadPool $WorkerThread. Run (SimpleThreadPool. Java: 573)
Under Caused by: Java. IO. EOFException: Can not read the response from the server. The Expected 4 bytes to read, read zero bytes before the connection was unexpectedly lost.
At com. Mysql. JDBC. MysqlIO. ReadFully (MysqlIO. Java: 2957)
At com. Mysql. JDBC. MysqlIO. ReuseAndReadPacket (MysqlIO. Java: 3375)
. 13 more
Establish a connection error!
Establish a connection error!

With mysql login into the database, an Insert Insert 1 the data also show that:
ERROR 2006 (HY000) : MySQL server has gone away
No connection. Trying to reconnect...
The Connection id: 3
The Current database: jxsggzy3

ERROR 2013: (HY000) Lost connection to MySQL server during query

According to the online query, adjusted my. A number of configuration parameters of CNF:
mysql> Show global variables like '% timeout';
+ -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - + -- -- -- -- -- -- -- -- -- -- +
Value | | Variable_name |
+ -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - + -- -- -- -- -- -- -- -- -- -- +
10 | | connect_timeout |
300 | | delayed_insert_timeout |
| have_statement_timeout | YES |
| | innodb_flush_log_at_timeout | 1
50 | | innodb_lock_wait_timeout |
| innodb_rollback_on_timeout | OFF |
7200 | | interactive_timeout |
31536000 | | lock_wait_timeout |
30 | | net_read_timeout |
60 | | net_write_timeout |
31536000 | | rpl_stop_slave_timeout |
60 | | slave_net_timeout |
86400 | | wait_timeout |
+ -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - + -- -- -- -- -- -- -- -- -- -- +
13 rows in the set (0.00 SEC)

Do the following modification scheme is also invalid:
Wait_timeout=2880000
Interactive_timeout=2880000
Max_allowed_packet=1024 m

Daniel under pulse please, thank!
  • Related