diff options
author | Venkatesh Duggirala <venkatesh.duggirala@oracle.com> | 2013-01-02 16:31:58 +0530 |
---|---|---|
committer | Venkatesh Duggirala <venkatesh.duggirala@oracle.com> | 2013-01-02 16:31:58 +0530 |
commit | 39323920302a039ac7e3a80052fbd68d31e5e75d (patch) | |
tree | 7dd36d76fc6d62327ef5cefc6e124d7d55cdf501 /sql/mysqld.cc | |
parent | 10f8266d50ec134e72d9562e29d676c00249d9bb (diff) | |
download | mariadb-git-39323920302a039ac7e3a80052fbd68d31e5e75d.tar.gz |
BUG#11753923-SQL THREAD CRASHES ON DISK FULL
Problem:If Disk becomes full while writing into the binlog,
then the server instance hangs till someone frees the space.
After user frees up the disk space, mysql server crashes
with an assert (m_status != DA_EMPTY)
Analysis: wait_for_free_space is being called in an
infinite loop i.e., server instance will hang until
someone frees up the space. So there is no need to
set status bit in diagnostic area.
Fix: Replace my_error/my_printf_error with
sql_print_warning() which prints the warning in error log.
include/my_sys.h:
Provision to call sql_print_warning from mysys files
mysys/errors.c:
Replace my_error/my_printf_error with
sql_print_warning() which prints the warning in error log.
mysys/my_error.c:
implementation of my_printf_warning
mysys/my_write.c:
Adding logic to break infinite loop in the simulation
sql/mysqld.cc:
Provision to call sql_print_warning from mysys files
Diffstat (limited to 'sql/mysqld.cc')
-rw-r--r-- | sql/mysqld.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sql/mysqld.cc b/sql/mysqld.cc index 12b52a87adc..3b43217dd2f 100644 --- a/sql/mysqld.cc +++ b/sql/mysqld.cc @@ -4375,6 +4375,7 @@ we force server id to 2, but this MySQL server will not act as a slave."); After this we can't quit by a simple unireg_abort */ error_handler_hook= my_message_sql; + sql_print_warning_hook = sql_print_warning; start_signal_handler(); // Creates pidfile if (mysql_rm_tmp_tables() || acl_init(opt_noacl) || |