{"action":"created","issue":{"url":"https://api.github.com/repos/sysown/proxysql/issues/1427","repository_url":"https://api.github.com/repos/sysown/proxysql","labels_url":"https://api.github.com/repos/sysown/proxysql/issues/1427/labels{/name}","comments_url":"https://api.github.com/repos/sysown/proxysql/issues/1427/comments","events_url":"https://api.github.com/repos/sysown/proxysql/issues/1427/events","html_url":"https://github.com/sysown/proxysql/issues/1427","id":306758532,"number":1427,"title":"ProxySQL crash","user":{"login":"cggy2012","id":34909365,"avatar_url":"https://avatars3.githubusercontent.com/u/34909365?v=4","gravatar_id":"","url":"https://api.github.com/users/cggy2012","html_url":"https://github.com/cggy2012","followers_url":"https://api.github.com/users/cggy2012/followers","following_url":"https://api.github.com/users/cggy2012/following{/other_user}","gists_url":"https://api.github.com/users/cggy2012/gists{/gist_id}","starred_url":"https://api.github.com/users/cggy2012/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cggy2012/subscriptions","organizations_url":"https://api.github.com/users/cggy2012/orgs","repos_url":"https://api.github.com/users/cggy2012/repos","events_url":"https://api.github.com/users/cggy2012/events{/privacy}","received_events_url":"https://api.github.com/users/cggy2012/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-03-20T07:44:56Z","updated_at":"2018-03-26T16:48:21Z","closed_at":null,"author_association":"NONE","body":"**OS version** \r\nLinux dtkdb_ps3 3.10.0-693.17.1.el7.x86_64 #1 SMP Thu Jan 25 20:13:58 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux\r\n\r\n**proxysql version**  \r\nmysql> select version();\r\n+-------------------+\r\n| version()         |\r\n+-------------------+\r\n| 1.4.7-23-g64e0eef |\r\n+-------------------+\r\n\r\n**mysql version**\r\nmysql [(none)]>select version();\r\n+------------+\r\n| version()  |\r\n+------------+\r\n| 5.7.21-log |\r\n+------------+\r\n\r\n**found error step**\r\n\r\n1. I found that there are core files in the directory.\r\n2. I read proxysql.log and found that there is crash information.\r\n3. Then I found the PHP has an error (\"PDO::beginTransaction(): MySQL server has gone away\")\r\n\r\n**I used native mysql group replication.**\r\n\r\nmysql> select * from mysql_group_replication_hostgroups;\r\n+------------------+-------------------------+------------------+-------------------+--------+-------------+-----------------------+-------------------------+---------+\r\n| writer_hostgroup | backup_writer_hostgroup | reader_hostgroup | offline_hostgroup | active | max_writers | writer_is_also_reader | max_transactions_behind | comment |\r\n+------------------+-------------------------+------------------+-------------------+--------+-------------+-----------------------+-------------------------+---------+\r\n| 0                | 4                       | 1                | 2                 | 1      | 1           | 0                     | 100                     | NULL    |\r\n+------------------+-------------------------+------------------+-------------------+--------+-------------+-----------------------+-------------------------+---------+\r\n\r\nmysql> select * from runtime_mysql_servers;\r\n+--------------+----------------+------+--------+--------+-------------+-----------------+---------------------+---------+----------------+---------+\r\n| hostgroup_id | hostname       | port | status | weight | compression | max_connections | max_replication_lag | use_ssl | max_latency_ms | comment |\r\n+--------------+----------------+------+--------+--------+-------------+-----------------+---------------------+---------+----------------+---------+\r\n| 0            | 192.168.11.186 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n| 1            | 192.168.11.190 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n| 1            | 192.168.11.188 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n| 1            | 192.168.11.191 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n| 1            | 192.168.11.189 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n| 1            | 192.168.11.187 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n| 1            | 192.168.11.185 | 3306 | ONLINE | 1      | 0           | 1000            | 0                   | 0       | 0              |         |\r\n+--------------+----------------+------+--------+--------+-------------+-----------------+---------------------+---------+----------------+---------+\r\n\r\nmysql> select rule_id,active,username,schemaname,match_pattern,destination_hostgroup from runtime_mysql_query_rules;\r\n+---------+--------+----------+------------+----------------------+-----------------------+\r\n| rule_id | active | username | schemaname | match_pattern        | destination_hostgroup |\r\n+---------+--------+----------+------------+----------------------+-----------------------+\r\n| 1       | 1      | NULL     | NULL       | ^SELECT.*FOR UPDATE$ | 0                     |\r\n| 2       | 1      | NULL     | NULL       | ^SELECT              | 1                     |\r\n| 3       | 1      | NULL     | NULL       | ^\\(?SELECT           | 1                     |\r\n| 4       | 1      | NULL     | NULL       | ^UPDATE              | 0                     |\r\n+---------+--------+----------+------------+----------------------+-----------------------+\r\n\r\nmysql> select * from global_variables;\r\n+-----------------------------------------------------+--------------------+\r\n| variable_name                                       | variable_value     |\r\n+-----------------------------------------------------+--------------------+\r\n| mysql-shun_on_failures                              | 5                  |\r\n| mysql-shun_recovery_time_sec                        | 10                 |\r\n| mysql-query_retries_on_failure                      | 1                  |\r\n| mysql-connect_retries_delay                         | 1                  |\r\n| mysql-connection_delay_multiplex_ms                 | 0                  |\r\n| mysql-connection_max_age_ms                         | 0                  |\r\n| mysql-connect_timeout_server_max                    | 10000              |\r\n| mysql-eventslog_filename                            |                    |\r\n| mysql-eventslog_filesize                            | 104857600          |\r\n| mysql-default_charset                               | utf8               |\r\n| mysql-free_connections_pct                          | 40                 |\r\n| mysql-session_idle_ms                               | 1000               |\r\n| mysql-monitor_enabled                               | true               |\r\n| mysql-monitor_connect_timeout                       | 600                |\r\n| mysql-monitor_ping_max_failures                     | 3                  |\r\n| mysql-monitor_ping_timeout                          | 1000               |\r\n| mysql-monitor_replication_lag_interval              | 10000              |\r\n| mysql-monitor_replication_lag_timeout               | 1000               |\r\n| mysql-monitor_groupreplication_healthcheck_interval | 5000               |\r\n| mysql-monitor_groupreplication_healthcheck_timeout  | 800                |\r\n| mysql-monitor_replication_lag_use_percona_heartbeat |                    |\r\n| mysql-monitor_query_interval                        | 60000              |\r\n| mysql-monitor_query_timeout                         | 100                |\r\n| mysql-monitor_slave_lag_when_null                   | 60                 |\r\n| mysql-monitor_wait_timeout                          | true               |\r\n| mysql-monitor_writer_is_also_reader                 | true               |\r\n| mysql-throttle_connections_per_sec_to_hostgroup     | 1000000            |\r\n| mysql-max_transaction_time                          | 14400000           |\r\n| mysql-multiplexing                                  | true               |\r\n| mysql-forward_autocommit                            | false              |\r\n| mysql-enforce_autocommit_on_reads                   | false              |\r\n| mysql-autocommit_false_not_reusable                 | false              |\r\n| mysql-autocommit_false_is_transaction               | false              |\r\n| mysql-verbose_query_error                           | true               |\r\n| mysql-hostgroup_manager_verbose                     | 1                  |\r\n| mysql-threshold_query_length                        | 524288             |\r\n| mysql-threshold_resultset_size                      | 4194304            |\r\n| mysql-query_digests_max_digest_length               | 2048               |\r\n| mysql-query_digests_max_query_length                | 65000              |\r\n| mysql-wait_timeout                                  | 1800000            |\r\n| mysql-throttle_max_bytes_per_second_to_client       | 2147483647         |\r\n| mysql-throttle_ratio_server_to_client               | 0                  |\r\n| mysql-max_stmts_cache                               | 10000              |\r\n| mysql-mirror_max_concurrency                        | 16                 |\r\n| mysql-mirror_max_queue_length                       | 32000              |\r\n| mysql-default_max_latency_ms                        | 1000               |\r\n| mysql-query_processor_iterations                    | 0                  |\r\n| mysql-query_processor_regex                         | 1                  |\r\n| mysql-long_query_time                               | 1000               |\r\n| mysql-query_cache_size_MB                           | 256                |\r\n| mysql-poll_timeout_on_failure                       | 100                |\r\n| mysql-server_capabilities                           | 45578              |\r\n| mysql-session_idle_show_processlist                 | true               |\r\n| mysql-query_digests                                 | false              |\r\n| mysql-query_digests_lowercase                       | false              |\r\n| mysql-servers_stats                                 | true               |\r\n| mysql-default_reconnect                             | true               |\r\n| mysql-ssl_p2s_ca                                    | (null)             |\r\n| mysql-ssl_p2s_cert                                  | (null)             |\r\n| mysql-ssl_p2s_key                                   | (null)             |\r\n| mysql-ssl_p2s_cipher                                | (null)             |\r\n| mysql-init_connect                                  | (null)             |\r\n| mysql-default_sql_mode                              |                    |\r\n| mysql-default_time_zone                             | SYSTEM             |\r\n| mysql-connpoll_reset_queue_length                   | 50                 |\r\n| mysql-stats_time_backend_query                      | false              |\r\n| mysql-stats_time_query_processor                    | false              |\r\n| mysql-threads                                       | 8                  |\r\n| mysql-max_connections                               | 10000              |\r\n| mysql-default_query_delay                           | 0                  |\r\n| mysql-default_query_timeout                         | 30000              |\r\n| mysql-have_compress                                 | true               |\r\n| mysql-poll_timeout                                  | 2000               |\r\n| mysql-interfaces                                    | 0.0.0.0:6033       |\r\n| mysql-default_schema                                | information_schema |\r\n| mysql-stacksize                                     | 1048576            |\r\n| mysql-server_version                                | 5.7.20             |\r\n| mysql-connect_timeout_server                        | 3000               |\r\n| mysql-monitor_username                              | mon_proxysql       |\r\n| mysql-monitor_password                              | qingtaokeDB520     |\r\n| mysql-monitor_history                               | 600000             |\r\n| mysql-monitor_connect_interval                      | 60000              |\r\n| mysql-monitor_ping_interval                         | 10000              |\r\n| mysql-monitor_read_only_interval                    | 1500               |\r\n| mysql-monitor_read_only_timeout                     | 500                |\r\n| mysql-ping_interval_server_msec                     | 120000             |\r\n| mysql-ping_timeout_server                           | 500                |\r\n| mysql-commands_stats                                | false              |\r\n| mysql-sessions_sort                                 | true               |\r\n| mysql-connect_retries_on_failure                    | 10                 |\r\n| mysql-client_found_rows                             | false              |\r\n| mysql-max_stmts_per_connection                      | 100                |\r\n| mysql-max_allowed_packet                            | 134217728          |\r\n| admin-stats_credentials                             | stats:stats        |\r\n| admin-stats_mysql_connections                       | 60                 |\r\n| admin-stats_mysql_connection_pool                   | 60                 |\r\n| admin-stats_mysql_query_cache                       | 60                 |\r\n| admin-stats_system_cpu                              | 60                 |\r\n| admin-stats_system_memory                           | 60                 |\r\n| admin-telnet_admin_ifaces                           | (null)             |\r\n| admin-telnet_stats_ifaces                           | (null)             |\r\n| admin-refresh_interval                              | 2000               |\r\n| admin-read_only                                     | false              |\r\n| admin-hash_passwords                                | true               |\r\n| admin-cluster_username                              |                    |\r\n| admin-cluster_password                              |                    |\r\n| admin-cluster_check_interval_ms                     | 1000               |\r\n| admin-cluster_check_status_frequency                | 10                 |\r\n| admin-cluster_mysql_query_rules_diffs_before_sync   | 3                  |\r\n| admin-cluster_mysql_servers_diffs_before_sync       | 3                  |\r\n| admin-cluster_mysql_users_diffs_before_sync         | 3                  |\r\n| admin-cluster_proxysql_servers_diffs_before_sync    | 3                  |\r\n| admin-cluster_mysql_query_rules_save_to_disk        | true               |\r\n| admin-cluster_mysql_servers_save_to_disk            | true               |\r\n| admin-cluster_mysql_users_save_to_disk              | true               |\r\n| admin-cluster_proxysql_servers_save_to_disk         | true               |\r\n| admin-checksum_mysql_query_rules                    | true               |\r\n| admin-checksum_mysql_servers                        | true               |\r\n| admin-checksum_mysql_users                          | true               |\r\n| admin-web_enabled                                   | false              |\r\n| admin-web_port                                      | 6080               |\r\n| admin-admin_credentials                             | admin:admin        |\r\n| admin-mysql_ifaces                                  | 0.0.0.0:6032       |\r\n| mysql-monitor_read_only_max_timeout_count           | 3                  |\r\n| admin-version                                       | 1.4.7-23-g64e0eef  |\r\n+-----------------------------------------------------+--------------------+\r\n"},"comment":{"url":"https://api.github.com/repos/sysown/proxysql/issues/comments/376233753","html_url":"https://github.com/sysown/proxysql/issues/1427#issuecomment-376233753","issue_url":"https://api.github.com/repos/sysown/proxysql/issues/1427","id":376233753,"user":{"login":"renecannao","id":3645227,"avatar_url":"https://avatars3.githubusercontent.com/u/3645227?v=4","gravatar_id":"","url":"https://api.github.com/users/renecannao","html_url":"https://github.com/renecannao","followers_url":"https://api.github.com/users/renecannao/followers","following_url":"https://api.github.com/users/renecannao/following{/other_user}","gists_url":"https://api.github.com/users/renecannao/gists{/gist_id}","starred_url":"https://api.github.com/users/renecannao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/renecannao/subscriptions","organizations_url":"https://api.github.com/users/renecannao/orgs","repos_url":"https://api.github.com/users/renecannao/repos","events_url":"https://api.github.com/users/renecannao/events{/privacy}","received_events_url":"https://api.github.com/users/renecannao/received_events","type":"User","site_admin":false},"created_at":"2018-03-26T16:48:21Z","updated_at":"2018-03-26T16:48:21Z","author_association":"CONTRIBUTOR","body":"Commit 5bd9a4b8959b1299a88de271e607714c29e801b9 is a possible fix for this #1427 (not #1428)"}}
{"actor":{"display_login":"renecannao"}}