OPTIMIZE TABLE w/o autocommit failure + shutdown failure

Description

1 2 3 4 # --no-defaults --plugin-load-add=tokudb=ha_tokudb.so --tokudb-check-jemalloc=0 CREATE TABLE t1 (c1 int) ENGINE=TokuDB; SET @@autocommit = FALSE; OPTIMIZE TABLE t1;

Qill cause this;

1 2 3 4 5 6 7 8 9 mysql> OPTIMIZE TABLE t1; +---------+----------+----------+-------------------------------------------------------------------+ | Table | Op | Msg_type | Msg_text | +---------+----------+----------+-------------------------------------------------------------------+ | test.t1 | optimize | note | Table does not support optimize, doing recreate + analyze instead | | test.t1 | optimize | error | Lock wait timeout exceeded; try restarting transaction | | test.t1 | optimize | status | Operation failed | +---------+----------+----------+-------------------------------------------------------------------+ 3 rows in set, 1 warning (4.12 sec)```

As well as this;

1 2 3 4 5 2017-02-02 14:41:13 25246 [ERROR] TokuDB: Cannot close environment due to open DBs /sda/PS-5.6.35_dbg/storage/tokudb/hatoku_hton.cc:727 tokudb_end: Assertion `Handlerton: error == 0 ' failed (errno=0) : Success Backtrace: (Note: toku_do_assert=0x0x7fe9a5d6866f)```

On attempt to shutdown

Environment

None

Status

Assignee

George Lorch

Reporter

roel.vandepaar

Labels

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

Freshdesk Tickets

None

Affects versions

5.7.17-11
5.6.35
5.7.13

Priority

Critical
Configure