2021-11-22 13:57:14 0x4568 InnoDB: Assertion failure in file D:\winx64-packages\build\src\storage\innobase\trx\trx0trx.cc line 1292
InnoDB: Failing assertion: UT_LIST_GET_LEN(lock.trx_locks) == 0
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to https://jira.mariadb.org/
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: https://mariadb.com/kb/en/library/innodb-recovery-modes/
InnoDB: about forcing recovery.
211122 13:57:14 [ERROR] mysqld got exception 0x80000003 ;
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.
To report this bug, see https://mariadb.com/kb/en/reporting-bugs
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.
Server version: 10.5.13-MariaDB
key_buffer_size=134217728
read_buffer_size=131072
max_used_connections=265
max_threads=65537
thread_count=33
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 142745966 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
Thread pointer: 0x249c7dc3ec8
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...
server.dll!my_parameter_handler()[my_init.c:278]
ucrtbase.dll!raise()
ucrtbase.dll!abort()
server.dll!ut_dbg_assertion_failed()[ut0dbg.cc:60]
server.dll!trx_t::commit_in_memory()[trx0trx.cc:1292]
server.dll!trx_t::commit()[trx0trx.cc:1509]
server.dll!trx_commit_for_mysql()[trx0trx.cc:1642]
server.dll!innobase_commit()[ha_innodb.cc:4343]
server.dll!commit_one_phase_2()[handler.cc:1956]
server.dll!ha_commit_one_phase()[handler.cc:1937]
server.dll!ha_commit_trans()[handler.cc:1729]
server.dll!trans_commit_stmt()[transaction.cc:473]
server.dll!mysql_execute_command()[sql_parse.cc:6117]
server.dll!mysql_parse()[sql_parse.cc:8104]
server.dll!dispatch_command()[sql_parse.cc:1894]
server.dll!do_command()[sql_parse.cc:1370]
server.dll!threadpool_process_request()[threadpool_common.cc:370]
server.dll!tp_callback()[threadpool_common.cc:194]
ntdll.dll!RtlInitializeCriticalSection()
ntdll.dll!RtlAcquireSRWLockExclusive()
KERNEL32.DLL!BaseThreadInitThunk()
ntdll.dll!RtlUserThreadStart()
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (0x249db6fffe0): SELECT
ic.ips_status_id as _Status_id,
IFNULL(ic.ips_status,'safe') as _Status,
IFNULL(GROUP_CONCAT(DISTINCT CASE WHEN md.`alarm_text`='No Error' THEN '' ELSE md.`alarm_text` END),'') as `Error`,
CONCAT(
'',
ic.cluster_name,
''
) as `IPS Cluster`,
`organisation`.`name` as Organisation,
ic.ice_status_datetime as Ice,
ic.preventive_status_datetime as Preventive,
IF(
ic.ice_status_datetime IS NULL AND ic.preventive_status_datetime IS NULL,
NULL,
COALESCE(
LEAST(ice_status.ice_status_datetime, preventive_status.preventive_status_datetime),
ice_status.ice_status_datetime,
preventive_status.preventive_status_datetime
)
) as `Stop Time`,
1 as _Task_Prio,
if(
lg.datetime < DATE_SUB(UTC_TIMESTAMP(), INTERVAL 24 HOUR),
NULL,
CONCAT(
IFNULL(CONCAT(lg.comment,'
'),''),
IFNULL(
CONCAT(
'',
GROUP_CONCAT(DISTINCT(d.decision) SEPARATOR ''),
''
),
''
)
)
) as Log,
if(lg.datetime < DATE_SUB(UTC_TIMESTAMP(), INTERVAL 24 HOUR),NULL,lg.datetime) as 'Log Time',
IFNULL(
CONCAT('',`topwind_user2`.`username`,''),
if(
lg.datetime < DATE_SUB(UTC_TIMESTAMP(), INTERVAL 24 HOUR),
NULL,
`topwind_user`.`username`
)
) as Operator,
min(md.meteo_datetime) > DATE_SUB(UTC_TIMESTAMP(), INTERVAL 20 MINUTE) as _ShowSensor,
min(md_one_hour_ago.meteo_datetime) > DATE_SUB(md.meteo_datetime, INTERVAL 2 HOUR) as _ShowSensorDiff,
round(min(md.`temperature`),1) as Temp,
sign(round(1/0.2*avg(
(md.`temperature`-md_one_hour_ago.`temperature`)
/(TIMESTAMPDIFF(minute,md_one_hour_ago.meteo_datetime,md.meteo_datetime)/60)
))) as _Temp_Change,
round(max(md.`relative_humidity`)) as Humidity,
sign(round(1/3*avg(
(md.`relative_humidity`-md_one_hour_ago.`relative_humidity`)
/(TIMESTAMPDIFF(minute,md_one_hour_ago.meteo_datetime,md.meteo_datetime)/60)
))) as _Humidity_Change,
case when max(md.`precipitation`)=1 then 'x' else '' end as Precip,
round(max(md.`risk_number`)) as Risk,
sign(round(1/5*avg(
(md.`risk_number`-md_one_hour_ago.`risk_number`)
/(TIMESTAMPDIFF(minute,md_one_hour_ago.meteo_datetime,md.meteo_datetime)/60)
))) as _Risk_Change,
min(md.`minute_preventive_overrule`) as `Prev Overrule`,
min(md.`minute_ice_overrule`) as `Ice Overrule`,
snooze_datetime as `Snooze Until`,
task_type.task_type as `Open Task`,
ic.calamity as _Calamity,
IFNULL(GROUP_CONCAT(DISTINCT(COALESCE(md.meteo_datetime,'NULL')) SEPARATOR ','),'NULL') as Delay
FROM
`meteo_data_last_day` `md`
RIGHT OUTER JOIN `ips` `i` ON (`md`.`ips_id` = `i`.`ips_id` OR `md`.`ips_id` IS NULL)
LEFT OUTER JOIN `meteo_data_last_day` `md_one_hour_ago` ON (`md_one_hour_ago`.`ips_id` = `i`.`ips_id` OR `md_one_hour_ago`.`ips_id` IS NULL)
LEFT OUTER JOIN
( SELECT
ips_cluster_id,
organisation_id,
cluster_name,
calamity,
show_dashboard,
snooze_datetime,
topwind_user_id_who_has_detail_page_open,
task_type_id,
ips_status.ips_status_id,
ips_status.ips_status,
dashboard_position,
ice_status_datetime,
preventive_status_datetime
FROM
(
SELECT
ips_cluster.ips_cluster_id,
ips_cluster.organisation_id,
ips_cluster.cluster_name,
ips_cluster.calamity,
ips_cluster.show_dashboard,
ips_cluster.snooze_datetime,
ips_cluster.topwind_user_id_who_has_detail_page_open,
ips_cluster.task_type_id,
MAX(IF(event_recent.end_datetime is null,ips_status.status_priority,NULL)) max_prio,
MIN(
IF(
event_recent.end_datetime is null AND event_recent.event_type_id IN (11,21,41,60,111,211),
event_recent.start_datetime,
NULL
)
) ice_status_datetime,
MIN(
IF(
event_recent.end_datetime is null AND event_recent.event_type_id IN (12,22,42,61,121,221),
event_recent.start_datetime,
NULL
)
) preventive_status_datetime
FROM
ips_cluster
LEFT OUTER JOIN ips ON (ips.ips_cluster_id = ips_cluster.ips_cluster_id)
LEFT OUTER JOIN event_recent ON (event_recent.ips_id = ips.ips_id)
LEFT OUTER JOIN event_type ON (event_recent.event_type_id = event_type.event_type_id)
LEFT OUTER JOIN ips_status ON (event_type.ips_status_id = ips_status.ips_status_id)
GROUP BY ips_cluster.ips_cluster_id
) cluster_status
LEFT OUTER JOIN ips_status ON (cluster_status.max_prio = ips_status.status_priority)
) `ic` ON (`ic`.`ips_cluster_id` = `i`.`ips_cluster_id` OR `ic`.`ips_cluster_id` IS NULL)
LEFT OUTER JOIN
(
SELECT ice_status_event2.ips_id, MIN(start_datetime) as ice_status_datetime
FROM
event_recent ice_status_event2
LEFT OUTER JOIN
(
SELECT ips_id, MAX(start_datetime) as ts
FROM
(
SELECT
ips_id,
IF(
event_type_id_next IN (21,211),
TIMESTAMPDIFF(MINUTE, start_datetime, start_datetime_next),
IF(
event_type_id_next_next IN (21,211),
TIMESTAMPDIFF(MINUTE, start_datetime, start_datetime_next_next),
NULL
)
) AS time_diff,
start_datetime
FROM
(
SELECT
ips_id,
event_type_id,
LEAD(event_type_id) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS event_type_id_next,
LEAD(event_type_id,2) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS event_type_id_next_next,
start_datetime,
LEAD(start_datetime) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS start_datetime_next,
LEAD(start_datetime,2) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS start_datetime_next_next
FROM event_recent ice_status_event
) AS ice_status_sq
WHERE
(event_type_id=30 OR event_type_id=51 OR event_type_id=41 ) AND
NOT (event_type_id_next=30) AND
NOT (event_type_id_next=51) AND
NOT (event_type_id_next=41)
) AS ice_status_sq2
WHERE time_diff IS NULL OR time_diff>30
GROUP BY ips_id
) ice_status_sq3 ON (ice_status_event2.ips_id=ice_status_sq3.ips_id)
WHERE event_type_id IN (21,211) AND ice_status_event2.start_datetime > ice_status_sq3.ts
GROUP BY ips_id
) ice_status ON (i.ips_id = ice_status.ips_id OR ice_status.ips_id IS NULL)
LEFT OUTER JOIN
(
SELECT preventive_status_event2.ips_id, MIN(start_datetime) as preventive_status_datetime
FROM
event_recent preventive_status_event2
LEFT OUTER JOIN
(
SELECT ips_id, MAX(start_datetime) as ts
FROM
(
SELECT
ips_id,
IF(
event_type_id_next IN (22,221),
TIMESTAMPDIFF(MINUTE, start_datetime, start_datetime_next),
IF(
event_type_id_next_next IN (22,221),
TIMESTAMPDIFF(MINUTE, start_datetime, start_datetime_next_next),
NULL
)
) AS time_diff,
start_datetime
FROM
(
SELECT
ips_id,
event_type_id,
LEAD(event_type_id) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS event_type_id_next,
LEAD(event_type_id,2) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS event_type_id_next_next,
start_datetime,
LEAD(start_datetime) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS start_datetime_next,
LEAD(start_datetime,2) OVER (PARTITION BY ips_id ORDER BY start_datetime) AS start_datetime_next_next
FROM event_recent preventive_status_event
) AS preventive_status_sq
WHERE
(event_type_id=30 OR event_type_id=51 OR event_type_id=42) AND
NOT (event_type_id_next=30) AND
NOT (event_type_id_next=51) AND
NOT (event_type_id_next=42)
) AS preventive_status_sq2
WHERE time_diff IS NULL OR time_diff>30
GROUP BY ips_id
) preventive_status_sq3 ON (preventive_status_event2.ips_id=preventive_status_sq3.ips_id)
WHERE event_type_id IN (22,221) AND preventive_status_event2.start_datetime > preventive_status_sq3.ts
GROUP BY ips_id
) preventive_status ON (i.ips_id = preventive_status.ips_id OR preventive_status.ips_id IS NULL)
LEFT OUTER JOIN `organisation` ON (`ic`.`organisation_id` = `organisation`.`organisation_id` OR `organisation`.`organisation_id` IS NULL)
LEFT OUTER JOIN `log` `lg` ON (`ic`.`ips_cluster_id` = `lg`.`ips_cluster_id` OR lg.`ips_cluster_id` IS NULL)
LEFT OUTER JOIN `protocol` `p` ON (`ic`.`ips_cluster_id` = `p`.`ips_cluster_id`)
LEFT OUTER JOIN `decision` `d` ON (`lg`.`decision_id` = `d`.`decision_id` OR `d`.`decision_id` IS NULL)
LEFT OUTER JOIN `topwind_user` ON (`lg`.`topwind_user_id` = `topwind_user`.`topwind_user_id` OR `topwind_user`.`topwind_user_id` IS NULL)
LEFT OUTER JOIN `topwind_user` `topwind_user2` ON (`ic`.`topwind_user_id_who_has_detail_page_open` = `topwind_user2`.`topwind_user_id` OR `topwind_user2`.`topwind_user_id` IS NULL)
LEFT OUTER JOIN `task_type` ON (`ic`.`task_type_id` = `task_type`.`task_type_id` OR `task_type`.`task_type_id` IS NULL)
WHERE
(
md.meteo_datetime = (
SELECT MAX(`meteo_data_last_day`.`meteo_datetime`)
FROM `meteo_data_last_day`
WHERE ips_id = i.ips_id
) OR
md.ips_id IS NULL
) AND
(
md_one_hour_ago.meteo_datetime = IFNULL((
SELECT MAX(md_one_hour_ago_1.`meteo_datetime`)
FROM `meteo_data_last_day` md_one_hour_ago_1
WHERE ips_id = i.ips_id AND
md_one_hour_ago_1.`meteo_datetime` < DATE_SUB(md.meteo_datetime, INTERVAL 1 HOUR)
),(SELECT MAX(md_one_hour_ago_2.`meteo_datetime`)
FROM `meteo_data_last_day` md_one_hour_ago_2
WHERE ips_id = i.ips_id AND
md_one_hour_ago_2.`meteo_datetime` = md.meteo_datetime))
OR
md_one_hour_ago.ips_id IS NULL
) AND
(
lg.`datetime` = (
SELECT MAX(`log`.`datetime`)
FROM `log`
WHERE ips_cluster_id = ic.ips_cluster_id
) OR
lg.`ips_cluster_id` IS NULL
) AND
(
p.`last_status_change` = (
SELECT MAX(`protocol`.`last_status_change`)
FROM `protocol`
WHERE ips_cluster_id = ic.ips_cluster_id
)
) AND ic.ips_cluster_id IS NOT NULL AND
(
(NOT ic.ips_status_id IS NULL AND NOT ic.dashboard_position IS NULL) OR
NOT (IFNULL(CASE WHEN md.`alarm_text`='No Error' THEN '' ELSE md.`alarm_text` END,'')='')
) AND
(ic.ips_cluster_id IN (-1) OR (1)) AND
(ic.show_dashboard = 1 OR (1)) AND
((ic.ips_cluster_id>1000000 AND ic.ips_cluster_id<2000000))
GROUP BY ic.`ips_cluster_id`
ORDER BY ic.dashboard_position,`Log Time`,least(Ice,Preventive) ,ic.cluster_name
Connection ID (thread ID): 426563
Status: NOT_KILLED
Optimizer switch: index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,engine_condition_pushdown=off,index_condition_pushdown=on,derived_merge=on,derived_with_keys=on,firstmatch=on,loosescan=on,materialization=on,in_to_exists=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr=off,mrr_cost_based=off,mrr_sort_keys=off,outer_join_with_cache=on,semijoin_with_cache=on,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on,table_elimination=on,extended_keys=on,exists_to_in=on,orderby_uses_equalities=on,condition_pushdown_for_derived=on,split_materialized=on,condition_pushdown_for_subquery=on,rowid_filter=on,condition_pushdown_from_having=on,not_null_range_scan=off
The manual page at https://mariadb.com/kb/en/how-to-produce-a-full-stack-trace-for-mysqld/ contains
information that should help you find out what is causing the crash.
Writing a core file at D:\MariaDB\data\