[MDEV-16575] rocksdb.bulk_load_errors fails in buildbot with wrong result Created: 2018-06-25 Updated: 2018-08-13 Resolved: 2018-08-13 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - RocksDB, Tests |
| Affects Version/s: | 10.2 |
| Fix Version/s: | 10.2.17, 10.3.9 |
| Type: | Bug | Priority: | Major |
| Reporter: | Elena Stepanova | Assignee: | Sergei Petrunia |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
http://buildbot.askmonty.org/buildbot/builders/winx64-packages/builds/8855
|
| Comments |
| Comment by Sergei Petrunia [ 2018-08-13 ] | ||||||||||||||||||||||||||||||||
|
Investigation: this should be "Found error 198". The cause of the error is that the datafiles (or is it the MemTable?) still have the data (and/or tombstones) with the same keys as the ones being loaded. The upstream has this error. | ||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2018-08-13 ] | ||||||||||||||||||||||||||||||||
|
Looking at the failing test:
dosconnect con1 will cause myrocks::rocksdb_close_connection to be called, which will try to finish the bulk load and hit the error. How can we be sure that search_pattern_in_file.inc is called AFTER the bulk load mode cleanup is finished? It seems the author of the testcase tried to achieve that by calling wait_until_count_sessions.inc. The problem is that it doesn't help in MariaDB. I have modified the code in myrocks::rocksdb_close_connection to loop forever, and then I can see that the disconnecting thread is stuck here:
while wait_for_count_sessions.inc would not have succeeded: Threads_connected status variable shows 1, I_S.processlist doesn't include the thread being disconnected, etc, etc. | ||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2018-08-13 ] | ||||||||||||||||||||||||||||||||
|
The upstream does not have this problem: If I force the execution to loop in myrocks::rocksdb_close_connection(), the thread that is being terminated is still counted in Threads_connected counter:
| ||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2018-08-13 ] | ||||||||||||||||||||||||||||||||
|
I don't see any ways to make sure that myrocks::rocksdb_close_connection is finished, except A) using DEBUG_SYNC (which is only available in debug builds), or B) properly shutting down the server and starting it back. Implementing B. |