mysql server crash accessing Virtual Column Index to Indirectly Index a JSON Column
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS |
New
|
Undecided
|
Unassigned |
Bug Description
Hi , We are testing Json to implement in our new project and as part of test we tried to create table with Json column and other columns(virtual) to pre populate data based on json column. Inserts go fine. But when i create index on one of the column. And try a select using where <index_column> mysql crashes. And we have seen this happening on both 5.7.10 and 5.7.11. Please help in resolving this issue.
-- Here is the table syntax:
mysql> show create table load_test_par\G
*******
Table: load_test_par
Create Table: CREATE TABLE `load_test_par` (
`data` json DEFAULT NULL,
`create_date` datetime GENERATED ALWAYS AS (replace(
`eventType` varchar(16) GENERATED ALWAYS AS (json_extract(
`appName` varchar(64) GENERATED ALWAYS AS (json_extract(
`appBuildVersion` varchar(32) GENERATED ALWAYS AS (json_extract(
`acquisitionD
`adNetwork` varchar(64) GENERATED ALWAYS AS (json_extract(
`dataCenter` varchar(64) GENERATED ALWAYS AS (json_extract(
`locale` varchar(8) GENERATED ALWAYS AS (json_extract(
`product` varchar(64) GENERATED ALWAYS AS (json_extract(
`channel` varchar(64) GENERATED ALWAYS AS (json_extract(
`moduleName` varchar(64) GENERATED ALWAYS AS (json_extract(
`providerSource` varchar(64) GENERATED ALWAYS AS (json_extract(
`productDivision` varchar(64) GENERATED ALWAYS AS (json_extract(
`queryOrigina
`resultType` varchar(64) GENERATED ALWAYS AS (json_extract(
`suspectCategory` varchar(64) GENERATED ALWAYS AS (json_extract(
`deviceType` varchar(64) GENERATED ALWAYS AS (json_extract(
`responseCode` varchar(64) GENERATED ALWAYS AS (json_extract(
`actionType` varchar(64) GENERATED ALWAYS AS (json_extract(
KEY `dba_idx` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50500 PARTITION BY RANGE ( to_seconds(
(PARTITION p1_10 VALUES LESS THAN (63628909500) ENGINE = InnoDB,
PARTITION p1_11 VALUES LESS THAN (63628909560) ENGINE = InnoDB,
PARTITION p1_12 VALUES LESS THAN (63628909620) ENGINE = InnoDB,
PARTITION p1_13 VALUES LESS THAN (63628909680) ENGINE = InnoDB,
PARTITION p1_14 VALUES LESS THAN (63628909740) ENGINE = InnoDB,
PARTITION p1_15 VALUES LESS THAN (63628909800) ENGINE = InnoDB,
PARTITION p1_16 VALUES LESS THAN (63628909860) ENGINE = InnoDB,
PARTITION p1_17 VALUES LESS THAN (63628909920) ENGINE = InnoDB,
PARTITION p1_18 VALUES LESS THAN (63628909980) ENGINE = InnoDB,
PARTITION p1_19 VALUES LESS THAN (63628910040) ENGINE = InnoDB,
PARTITION p1_20 VALUES LESS THAN (63628910100) ENGINE = InnoDB,
PARTITION p1_21 VALUES LESS THAN (63628910160) ENGINE = InnoDB,
PARTITION p1_22 VALUES LESS THAN (63628910220) ENGINE = InnoDB,
PARTITION p1_23 VALUES LESS THAN (63628910280) ENGINE = InnoDB,
PARTITION p1_24 VALUES LESS THAN (63628910340) ENGINE = InnoDB,
PARTITION p1_25 VALUES LESS THAN (63628910400) ENGINE = InnoDB,
PARTITION p1_26 VALUES LESS THAN (63628910460) ENGINE = InnoDB,
PARTITION p1_27 VALUES LESS THAN (63628910520) ENGINE = InnoDB,
PARTITION p1_28 VALUES LESS THAN (63628910580) ENGINE = InnoDB,
PARTITION p1_29 VALUES LESS THAN (63628910640) ENGINE = InnoDB,
PARTITION p1_30 VALUES LESS THAN (63628910700) ENGINE = InnoDB,
PARTITION p1_31 VALUES LESS THAN (63628910760) ENGINE = InnoDB,
PARTITION p1_32 VALUES LESS THAN (63628910820) ENGINE = InnoDB,
PARTITION p1_33 VALUES LESS THAN (63628910880) ENGINE = InnoDB,
PARTITION p1_34 VALUES LESS THAN (63628910940) ENGINE = InnoDB,
PARTITION p1_35 VALUES LESS THAN (63628911000) ENGINE = InnoDB,
PARTITION p1_36 VALUES LESS THAN (63628911060) ENGINE = InnoDB,
PARTITION p1_37 VALUES LESS THAN (63628911120) ENGINE = InnoDB,
PARTITION p1_END VALUES LESS THAN MAXVALUE ENGINE = InnoDB) */
1 row in set (0.00 sec)
mysql> show indexes from load_test_par\G
*******
Table: load_test_par
Non_unique: 1
Key_name: dba_idx
Seq_in_index: 1
Column_name: create_date
Collation: A
Cardinality: 1045
Sub_part: NULL
Packed: NULL
Null: YES
Index_type: BTREE
Comment:
Index_comment:
1 row in set (0.00 sec)
mysql>
System crashes with below select :
mysql> select locale,
--- Table size is 60GB .
Error message during crash :
016-05-03 21:48:39 0x7fefac191700 InnoDB: Assertion failure in thread 140667361236736 in file row0mysql.cc line 202
InnoDB: Failing assertion: len < 256
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://
InnoDB: about forcing recovery.
04:48:39 UTC - mysqld got signal 6 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
Attempting to collect some information that could help diagnose the problem.
As this is a crash and something is definitely wrong, the information
collection process might fail.
Please help us make Percona Server better by reporting any
bugs at http://
key_buffer_
read_buffer_
max_used_
max_threads=513
thread_count=1
connection_count=1
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_
Hope that's ok; if not, decrease some variables in the equation.
Thread pointer: 0x7fef3c000ae0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 7fefac190d40 thread_stack 0x40000
/usr/sbin/
/usr/sbin/
/lib64/
/lib64/
/lib64/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/usr/sbin/
/lib64/
/lib64/
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (7fef3c005770): is an invalid pointer
Connection ID (thread ID): 2
Status: NOT_KILLED
You may download the Percona Server operations manual by visiting
http://
in the manual which will help you identify the cause of the crash.
160503 21:48:39 mysqld_safe Number of processes running now: 0
160503 21:48:39 mysqld_safe mysqld restarted
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
2016-05-
Version: '5.7.10-3-log' socket: '/var/lib/
2016-05-
we have seen this on Server version: 5.7.10-3-log Percona Server (GPL) and Server version: 5.7.10-3-log Percona Server (GPL) and Server version: 5.7.11-4-log Percona Server (GPL).