forked from percona/percona-server
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing occasional MyRocks SIGABRT on shutdown (percona#122)
Summary: RocksDB has some static object dependencies, and without following dependencies, it hits SIGABRT. This diff has two fixes. 1. Updating RocksDB revision. D51789 in RocksDB changes the problematic mutex from global variable to local (function-level) static variable. 2. Changing MyRocks no to call ddl_manager.persist_stats() by kill_server_thread (which calls rocksdb_done_func()). By calling ddl_manager.persist_stats(), rocksdb::ThreadLocalPtr::StaticMeta::OnThreadExit() (which calls pthread_mutex_lock on "static port::Mutex mutex") is called at the end of the thread. On the other hand, there is a race between main thread and kill_server_thread. main thread calls pthread_mutex_destroy for the mutex. To guarantee not to call pthread_mutex_lock() after pthread_mutex_destroy(), it is necessary not to call ddl_manager.persist_stats() from kill_server_thread. This diff fixes the issue. update-submodule: rocksdb Reviewed By: jkedgar Differential Revision: https://reviews.facebook.net/D51933 fbshipit-source-id: ca6e0722d88
- Loading branch information
1 parent
08b9159
commit 786028f
Showing
2 changed files
with
4 additions
and
4 deletions.
There are no files selected for viewing
Submodule rocksdb
updated
77 files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters