2006 - MySQL server has gone away
1262 ワード
コマンド:show global variables like'%timeout';以下のtimeoutを28800に設定すると、動的に設定できます.wait_timeout/interactive_timeout/net_read_timeout/net_write_timeout
コマンド:set global xxx_timeout=28800;
コマンド:set global xxx_timeout=28800;
mysql> show global variables like '%timeout';
+----------------------------+-------+
| Variable_name | Value |
+----------------------------+-------+
| connect_timeout | 10 |
| delayed_insert_timeout | 300 |
| innodb_lock_wait_timeout | 50 |
| innodb_rollback_on_timeout | OFF |
| interactive_timeout | 28800 |
| net_read_timeout | 30 |
| net_write_timeout | 60 |
| slave_net_timeout | 3600 |
| table_lock_wait_timeout | 50 |
| wait_timeout | 28800 |
+----------------------------+-------+
10 rows in set
mysql> set global wait_timeout=28800;
Query OK, 0 rows affected
mysql> set global interactive_timeout=28800;
Query OK, 0 rows affected
mysql> set global net_read_timeout=28800;
Query OK, 0 rows affected
mysql> set global net_write_timeout=28800;
Query OK, 0 rows affected