Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash in 2.0.9 when doing "LOAD MYSQL SERVERS FROM CONFIG" #2536

Closed
mensler opened this issue Feb 18, 2020 · 3 comments
Closed

Crash in 2.0.9 when doing "LOAD MYSQL SERVERS FROM CONFIG" #2536

mensler opened this issue Feb 18, 2020 · 3 comments
Assignees

Comments

@mensler
Copy link

mensler commented Feb 18, 2020

ProxySQL version: 2.0.9-209-g60923e2
OS: Ubuntu 16.04

Calling LOAD MYSQL SERVERS FROM CONFIG in admin module causes ProxySQL to crash:

mysql> LOAD MYSQL SERVERS FROM CONFIG;
ERROR 2013 (HY000): Lost connection to MySQL server during query

The error log shows the following lines:

2020-02-18 15:35:45 [INFO] Received LOAD MYSQL SERVERS FROM CONFIG command
proxysql: configfile.cpp:41: bool ProxySQL_ConfigFile::OpenFile(const char*): Assertion `__filename' failed.
Error: signal 6:
proxysql(_Z13crash_handleri+0x2d)[0x4ae68d]
/lib/x86_64-linux-gnu/libc.so.6(+0x354b0)[0x7ff9bea1a4b0]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0x38)[0x7ff9bea1a428]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x16a)[0x7ff9bea1c02a]
/lib/x86_64-linux-gnu/libc.so.6(+0x2dbd7)[0x7ff9bea12bd7]
/lib/x86_64-linux-gnu/libc.so.6(+0x2dc82)[0x7ff9bea12c82]
proxysql(_ZN19ProxySQL_ConfigFile8OpenFileEPKc+0xbb)[0x4ba58b]
proxysql(_Z34admin_handler_command_load_or_savePcjP13MySQL_SessionP14ProxySQL_AdminPS_Pj+0x29d7)[0x5607d7]
proxysql(_Z21admin_session_handlerP13MySQL_SessionPvP10_PtrSize_t+0x1b87)[0x564587]
proxysql(_ZN13MySQL_Session7handlerEv+0x1aa1)[0x515351]
proxysql(_Z11child_mysqlPv+0x392)[0x52fb82]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x76ba)[0x7ff9bfa636ba]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x6d)[0x7ff9beaec41d]
2020-02-18 15:35:47 main.cpp:1492:ProxySQL_daemonize_phase3(): [ERROR] ProxySQL crashed. Restarting!

Please find attached the config, full error log, binary and core dump:
proxysql_load_from_config_crash.zip

@xo4yecTb
Copy link

Same problem on Debian Stretch distrib after upgrade proxysql to 2.0.9:

mysql> SHOW VARIABLES LIKE '%version%';
+----------------------+---------------------+
| Variable_name        | Value               |
+----------------------+---------------------+
| mysql-server_version | 5.7.28              |
| admin-version        | 2.0.9-209-g60923e24 |
+----------------------+---------------------+
2 rows in set (0.00 sec)
mysql> LOAD MYSQL SERVERS FROM CONFIG;
ERROR 2013 (HY000): Lost connection to MySQL server during query
mysql> LOAD MYSQL SERVERS FROM CONFIG;
ERROR 2006 (HY000): MySQL server has gone away
No connection. Trying to reconnect...
Connection id:    1
Current database: *** NONE ***

ERROR 2013 (HY000): Lost connection to MySQL server during query
mysql> LOAD MYSQL SERVERS TO RUNTIME;
ERROR 2006 (HY000): MySQL server has gone away
No connection. Trying to reconnect...
Connection id:    1
Current database: *** NONE ***

Query OK, 0 rows affected (0.01 sec)

mysql> LOAD MYSQL SERVERS TO RUNTIME;
Query OK, 0 rows affected (0.01 sec)

error.log

2020-02-18 19:14:42 [INFO] Received LOAD MYSQL SERVERS FROM CONFIG command
proxysql: configfile.cpp:41: bool ProxySQL_ConfigFile::OpenFile(const char*): Assertion `__filename' failed.
Error: signal 6:
/usr/bin/proxysql(_Z13crash_handleri+0x1a)[0x560ec219a8da]
/lib/x86_64-linux-gnu/libc.so.6(+0x33060)[0x7f9963f30060]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0xcf)[0x7f9963f2ffff]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x16a)[0x7f9963f3142a]
/lib/x86_64-linux-gnu/libc.so.6(+0x2be67)[0x7f9963f28e67]
/lib/x86_64-linux-gnu/libc.so.6(+0x2bf12)[0x7f9963f28f12]
/usr/bin/proxysql(_ZN19ProxySQL_ConfigFile8OpenFileEPKc+0xbb)[0x560ec21a6a2b]
/usr/bin/proxysql(_Z34admin_handler_command_load_or_savePcjP13MySQL_SessionP14ProxySQL_AdminPS_Pj+0x3d0b)[0x560ec2248f9b]
/usr/bin/proxysql(_Z21admin_session_handlerP13MySQL_SessionPvP10_PtrSize_t+0x1bfd)[0x560ec224bbdd]
/usr/bin/proxysql(_ZN13MySQL_Session7handlerEv+0x1acc)[0x560ec21feb1c]
/usr/bin/proxysql(_Z11child_mysqlPv+0x34a)[0x560ec22183fa]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x74a4)[0x7f99651664a4]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x3f)[0x7f9963fe5d0f]
2020-02-18 19:14:42 main.cpp:1492:ProxySQL_daemonize_phase3(): [ERROR] ProxySQL crashed. Restarting!

@renecannao
Copy link
Contributor

Assigning to @Val214

Thank you for the report

@renecannao
Copy link
Contributor

Solved in 2.0.10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants