<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel>
        <title>MySQL Forums - InnoDB</title>
        <description>Forum for InnoDB Storage Engine.</description>
        <link>https://forums.mysql.com/list.php?22</link>
        <lastBuildDate>Sun, 12 Apr 2026 12:06:07 +0000</lastBuildDate>
        <generator>Phorum 5.2.23</generator>
        <item>
            <guid>https://forums.mysql.com/read.php?22,741437,741437#msg-741437</guid>
            <title>Question about REPEATABLE READ isolatin level. (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,741437,741437#msg-741437</link>
            <description><![CDATA[ Hey guys,<br />
<br />
From the description of this isolation level here: <a href="https://dev.mysql.com/doc/refman/8.4/en/innodb-transaction-isolation-levels.html"  rel="nofollow">https://dev.mysql.com/doc/refman/8.4/en/innodb-transaction-isolation-levels.html</a>, it says &#039;It is not recommended to mix locking statements (UPDATE, INSERT, DELETE, or SELECT ... FOR ...) with non-locking SELECT statements in a single REPEATABLE READ transaction&#039;.<br />
<br />
Does it mean that it is preferable that we feed it with READ-ONLY transactions or ones with only DML statements inside? I test it with the following transaction:<br />
<br />
start transaction;<br />
<br />
insert into t values (1, 1);<br />
<br />
select * from t;<br />
<br />
commit;<br />
<br />
It commits successfully though. Is there something like a performance penalty if I do this in a production environment?<br />
<br />
Stephan]]></description>
            <dc:creator>Stephan Smith</dc:creator>
            <category>InnoDB</category>
            <pubDate>Sat, 29 Nov 2025 04:29:08 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,741427,741427#msg-741427</guid>
            <title>InnoDB Table - Instant Add Column taking a long time (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,741427,741427#msg-741427</link>
            <description><![CDATA[ I&#039;ve a MySQL table, which I&#039;m having trouble to add a column using instant algorithm. There is no error when I run the DDL, but it runs forever.<br />
<br />
Type: InnoDB<br />
MySQL Version: 8.0.35 (Hosted on OVH MySQL managed services)<br />
Table Size: 95GB (None partitioned)<br />
Full text indexes: None<br />
Schema: Note that I&#039;ve masked client data with xxxx<br />
<br />
CREATE TABLE `xxxx` (<br />
  `column1` binary(16) NOT NULL,<br />
  `column2` binary(16) NOT NULL,<br />
  `column3` binary(16) NOT NULL,<br />
  `column1_type` binary(16) DEFAULT NULL,<br />
  `column4` binary(16) NOT NULL,<br />
  `column5` int NOT NULL,<br />
  `column6` int NOT NULL DEFAULT &#039;0&#039;,<br />
  `column7` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,<br />
  `column8` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,<br />
  `column9` tinyint(1) DEFAULT NULL,<br />
  PRIMARY KEY (`column1`),<br />
  UNIQUE KEY `xxxxx_column7` (`column3`,`column7`),<br />
  KEY `idx_xxxx_xxxx` (`column2`),<br />
  KEY `idx_xxxx_xxxxx` (`column4`),<br />
  KEY `idx_xxxx_xxxxxx` (`column7`),<br />
  KEY `idx_xxxx_xxxxxxx` (`column8`,`column1_type`,`column4`,`column5`),<br />
  KEY `idx_xxxx_column1type_column4_column3_column7` (`column1_type`,`column4`,`column3`,`column7`),<br />
  KEY `idx_xxxx_column1_type_column7` (`column1_type`,`column7`) USING BTREE,<br />
  CONSTRAINT `xxxx xxxxxx` FOREIGN KEY (`column3`) REFERENCES `bbbb` (`column3`) ON DELETE CASCADE ON UPDATE CASCADE,<br />
  CONSTRAINT `xxxx xxxxxx` FOREIGN KEY (`column2`) REFERENCES `aaaaa` (`column2`) ON DELETE CASCADE ON UPDATE CASCADE,<br />
  CONSTRAINT `xxxxx column1_type` FOREIGN KEY (`column1_type`) REFERENCES `yyyyy_type` (`column1_type`) ON DELETE CASCADE ON UPDATE CASCADE,<br />
  CONSTRAINT `xxxx xxxx` FOREIGN KEY (`column4`) REFERENCES `zzzz` (`column4`) ON DELETE CASCADE ON UPDATE CASCADE<br />
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;<br />
<br />
<br />
Other settings:<br />
		&quot;Engine&quot; : &quot;InnoDB&quot;,<br />
		&quot;Version&quot; : 10,<br />
		&quot;Row_format&quot; : &quot;Dynamic&quot;,<br />
		&quot;Rows&quot; : 159,829,897,<br />
		&quot;Avg_row_length&quot; : 165,<br />
		&quot;Data_length&quot; : 26444595200,<br />
		&quot;Max_data_length&quot; : 0,<br />
		&quot;Index_length&quot; : 76576980992,<br />
		&quot;Data_free&quot; : 4194304,<br />
		&quot;Auto_increment&quot; : null,<br />
		&quot;Check_time&quot; : null,<br />
		&quot;Collation&quot; : &quot;utf8mb4_unicode_ci&quot;,<br />
		&quot;Checksum&quot; : null,<br />
		&quot;Create_options&quot; : &quot;&quot;,<br />
		&quot;Comment&quot; : &quot;&quot;<br />
<br />
Versions: 0 (So there are more opportunities to run instant DDL)<br />
The whole MySQL instance has a replica (Through OVH high availability)<br />
<br />
DDL command trying to run:<br />
<br />
ALTER TABLE xxxx ADD COLUMN createdon_utc DATETIME, ALGORITHM=INSTANT;<br />
<br />
Outcome:<br />
1. No errors when executing. Tried with LOCK = EXCLUSIVE, LOCK = NONE etc. (Same)<br />
2. SHOW FULL PROCESSLIST; shows Altering table, not waiting for locks, etc<br />
3. Ran while all writes to the table were stopped (same behaviour)<br />
4. Ran for over 10 - 15 minutes, and can see the database size growing (before stopping it)<br />
5. I&#039;ve tried with adding NULL as default - Same behaviour<br />
<br />
I can&#039;t tune any OS level settings as it&#039;s in OVH hosting.<br />
<br />
I cannot afford to run this on Copy algorithm that&#039;s trying to follow.<br />
<br />
Anything I can do without causing any outage to add this column?<br />
<br />
I&#039;m able to add the same column on another copy of a locally installed DB, but with 20 GB-sized table. (Same schema, same settings)<br />
<br />
Best Regards,<br />
Roshan]]></description>
            <dc:creator>Roshan Jayalath</dc:creator>
            <category>InnoDB</category>
            <pubDate>Wed, 26 Nov 2025 06:27:56 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,741371,741371#msg-741371</guid>
            <title>Undo logs Bloat (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,741371,741371#msg-741371</link>
            <description><![CDATA[ we are experiencing a huge undo log bloat in the mysql version 8.0.40<br />
<br />
size of the undo log files grown<br />
<br />
580G	temp_undo_003.ibu<br />
102G	temp_undo_004.ibu<br />
521G	undo_001<br />
575G	undo_002<br />
<br />
<br />
History list length 2249562972<br />
<br />
<br />
mysql&gt;  SELECT SPACE, NAME, STATE, FILE_SIZE, ALLOCATED_SIZE FROM information_schema.innodb_tablespaces WHERE SPACE_TYPE=&#039;Undo&#039;;<br />
+------------+-----------------+----------+--------------+----------------+<br />
| SPACE      | NAME            | STATE    | FILE_SIZE    | ALLOCATED_SIZE |<br />
+------------+-----------------+----------+--------------+----------------+<br />
| 4294966771 | innodb_undo_001 | active   | 555879497728 |   555879653376 |<br />
| 4294966897 | innodb_undo_002 | inactive | 616831123456 |   616831246336 |<br />
| 4294967277 | temp_undo_003   | active   | 618643062784 |   618643353600 |<br />
| 4294967276 | temp_undo_004   | inactive | 109270007808 |   109270110208 |<br />
+------------+-----------------+----------+--------------+----------------+<br />
4 rows in set (0.06 sec)<br />
<br />
I could confirm that there is no long running transaction, but it is a heavy write system where more upsert queries will be running.<br />
<br />
it was about more than 30 days, it has been made inactive but still not become empty state. <br />
<br />
Any best solution to overcome this issue of clearing all the space occupied by the undo logs, within a very short interval of time.]]></description>
            <dc:creator>Azar Md</dc:creator>
            <category>InnoDB</category>
            <pubDate>Tue, 11 Nov 2025 09:48:58 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,741172,741172#msg-741172</guid>
            <title>MYSQL table end not ready? (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,741172,741172#msg-741172</link>
            <description><![CDATA[ Hi!<br />
<br />
I am creating an SQL table in a PHP program. The program runs fine, the data is written to a .cs file as well, there are no error messages, but the end of the SQL table is missing. <br />
Is there a solution? Perhaps buffering? <br />
Thank you.<br />
<br />
Regards<br />
<br />
Tamas Nedecki.<br />
<br />
System: win11, xampp, apache, mysql, fresh installing.]]></description>
            <dc:creator>Tamas Nedecki</dc:creator>
            <category>InnoDB</category>
            <pubDate>Sun, 07 Sep 2025 08:28:52 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,741085,741085#msg-741085</guid>
            <title>MySQL 8.4.3 – Transactions stuck in waiting for handler commit until restart (async master–master replication, high concurrency on InnoDB) (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,741085,741085#msg-741085</link>
            <description><![CDATA[ We are experiencing an intermittent but severe commit stall in MySQL 8.4.3 Community Edition (RHEL-compatible OS) running asynchronous master–master replication.<br />
<br />
Symptoms:<br />
<br />
Many client sessions remain in waiting for handler commit for thousands of seconds.<br />
<br />
Affected transactions are short (single-row UPDATE/INSERT/DELETE on InnoDB table radius_auth.re_auth_ctx).<br />
<br />
Application connections start aborting with Got an error reading communication packets.<br />
<br />
Condition persists until mysqld is restarted. After restart, same workload runs normally.<br />
<br />
The same workload on MySQL 5.7.15 does not show this behavior.<br />
<br />
Replication thread (SHOW PROCESSLIST) is idle — &quot;Source has sent all binlog to replica; waiting for more updates&quot;.<br />
<br />
InnoDB redo log status shows no backlog; LSN positions are stable and aligned.<br />
<br />
No Group Replication — only classic async replication.<br />
<br />
Example stuck sessions:<br />
<br />
<br />
| 31098 | sdpuser | ... | radius_auth | Query | 7651 | waiting for handler commit | update re_auth_ctx set next_re_auth_id=... |<br />
| 31100 | sdpuser | ... | radius_auth | Query | 7651 | waiting for handler commit | update re_auth_ctx set next_re_auth_id=... |<br />
Table DDL:<br />
<br />
<br />
CREATE TABLE re_auth_ctx (<br />
  correlation_id varchar(50) NOT NULL,<br />
  protocol enum(&#039;SIM&#039;,&#039;AKA&#039;) NOT NULL,<br />
  imsi bigint NOT NULL,<br />
  updated timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,<br />
  created timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,<br />
  identity varchar(200) DEFAULT NULL,<br />
  next_re_auth_id varchar(200) DEFAULT NULL,<br />
  counter int NOT NULL DEFAULT &#039;0&#039;,<br />
  master_key varchar(100) DEFAULT NULL,<br />
  k_aut varchar(100) DEFAULT NULL,<br />
  k_encr varchar(100) DEFAULT NULL,<br />
  nonce_s varchar(100) DEFAULT NULL,<br />
  PRIMARY KEY (imsi)<br />
) ENGINE=InnoDB DEFAULT CHARSET=latin1<br />
/*!50100 PARTITION BY HASH (imsi) PARTITIONS 100 */<br />
Workload:<br />
<br />
High QPS from multiple application nodes (RADIUS re-auth).<br />
<br />
Each transaction updates or inserts a single PK row.<br />
<br />
Async master–master replication between two MySQL 8.4.3 servers; only one server exhibits this issue at a time.<br />
<br />
my.cnf highlights:<br />
<br />
makefile<br />
Copy<br />
Edit<br />
innodb_flush_log_at_trx_commit=1<br />
innodb_doublewrite=0<br />
innodb_flush_method=O_DIRECT<br />
innodb_log_file_size=2G<br />
innodb_buffer_pool_size=8G<br />
max_connections=500<br />
binlog enabled (async replication)<br />
<br />
<br />
Additional Notes:<br />
<br />
Would appreciate guidance on whether this matches an existing 8.4.3 issue, and if upgrading to ≥8.4.6 is recommended.]]></description>
            <dc:creator>kayukaran Parameswaran</dc:creator>
            <category>InnoDB</category>
            <pubDate>Fri, 15 Aug 2025 05:30:00 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,740950,740950#msg-740950</guid>
            <title>Innodb_dict_tables metric - how to access it? (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,740950,740950#msg-740950</link>
            <description><![CDATA[ Hi everyone,<br />
<br />
I&#039;m currently working on monitoring our Percona XtraDB Cluster using LogicMonitor. Most of the basic MySQL metrics are being collected without any issues. However, I&#039;m having trouble with the Innodb_dict_tables metric — LogicMonitor shows a NaN (Not a Number) value for it.<br />
<br />
The tool gives this information:<br />
<br />
Innodb_dict_tables: NaN<br />
<br />
and the regex processing shows: <br />
<br />
(postProcessParam: Innodb_dict_tables,(?:variable_)*value=(\d+), reference=, useValue=output)<br />
<br />
I suspect this could be related to how the data is exposed by the Percona server, not necessarily an issue on the LogicMonitor side.<br />
<br />
Does anyone know if access to Innodb_dict_tables is restricted somehow, or if it requires a specific server variable, plugin, or configuration to be enabled? I would really appreciate any insights or experience you can share.<br />
<br />
Thank you so much in advance!]]></description>
            <dc:creator>Jiri Cieslar</dc:creator>
            <category>InnoDB</category>
            <pubDate>Wed, 09 Jul 2025 13:40:07 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,740799,740799#msg-740799</guid>
            <title>How recovery data in ibdata1 file? I truncate tables, but i need to recovery (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,740799,740799#msg-740799</link>
            <description><![CDATA[ Help!!!! <br />
I&#039;m using mysql 5.1 and was executed a truncate table in all tables of database!!!<br />
<br />
<br />
I made the backup as soon as the command was executed and I can see the data using a text editor in the ibdata file. I tried some programs to recover, but I was not successful.<br />
Can anyone help me recover this data? I beg you!!!!<br />
<br />
tks<br />
<br />
Anderson]]></description>
            <dc:creator>Anderson Silva Anderson</dc:creator>
            <category>InnoDB</category>
            <pubDate>Tue, 10 Jun 2025 11:39:16 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,740673,740673#msg-740673</guid>
            <title>Update of innodb_buffer_pool_instances (1 reply)</title>
            <link>https://forums.mysql.com/read.php?22,740673,740673#msg-740673</link>
            <description><![CDATA[ Dear Team,<br />
<br />
We are using MySQL 8.0.37 community version and want to update innodb_buffer_pool_instances and other variable too to increase the performance.<br />
<br />
I edited the my.ini to add entry for innodb_buffer_pool_instances=8 and restarted MySQL services. But system is taking dafult value for innodb_buffer_pool_instances=1.<br />
<br />
I tried to set the varibale through SET PERSIT and SET GLOBAL command. But couldn&#039;t set because of read only variable.<br />
<br />
Let me know if you have any clue to set innodb_buffer_pool_instances to 8.]]></description>
            <dc:creator>Girish Salunke</dc:creator>
            <category>InnoDB</category>
            <pubDate>Sun, 22 Mar 2026 22:13:28 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,740662,740662#msg-740662</guid>
            <title>How to debug very slow transactions stuck at &quot;waiting for handler commit&quot; state? (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,740662,740662#msg-740662</link>
            <description><![CDATA[ - My MySQL Setup:<br />
I have a production MySQL 8.0.33 database.<br />
<br />
All tables use the InnoDB storage engine.<br />
<br />
The database has been running smoothly for the last 9 months.<br />
<br />
Size: ~60GB of data and ~200 million rows.<br />
<br />
Primary keys are CHAR(24) BSON ObjectIDs. These are chronologically sortable, similar to UUIDv1. We are aware that the most efficient way to store BSON ObjectIDs is as BINARY(12), but migrating to that would require extensive breaking changes, which are difficult to implement.<br />
<br />
innodb_flush_log_at_trx_commit is set to 1, and sync_binlog is also set to 1.<br />
<br />
- The Incident:<br />
We have observed sudden MySQL slowdowns over the past few weeks. These incidents were temporary, lasting for several hours, and resolved on their own.<br />
<br />
During the incidents, the output of SHOW FULL PROCESSLIST showed that many write transactions were stuck in the &quot;waiting for handler commit&quot; state for several minutes. These were simple INSERT or UPDATE statements—no heavy or bulk writes were involved.<br />
<br />
We are currently unable to reproduce the issue.<br />
<br />
- My Question:<br />
In the event of a future incident, how can I troubleshoot the issue more deeply?<br />
I&#039;m not sure whether this is caused by disk saturation, an application-level issue (e.g., deadlocks), or possibly a MySQL bug.]]></description>
            <dc:creator>Erfan Safari</dc:creator>
            <category>InnoDB</category>
            <pubDate>Fri, 02 May 2025 14:12:35 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,740618,740618#msg-740618</guid>
            <title>[GCP Cloud SQL MySQL Upgrade Error] InnoDB Metadata Inconsistency - Unable to Drop Temporary Table #sql-xxx (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,740618,740618#msg-740618</link>
            <description><![CDATA[ Hi everyone,<br />
<br />
We&#039;re facing a critical issue during a MySQL upgrade (from version 5.7 to 8.0) on a Google Cloud SQL instance. The upgrade process fails due to metadata inconsistencies in InnoDB, and possibly corrupted or missing .frm files or table data directories.<br />
<br />
Here’s a snippet of the error log:<br />
<br />
INFO 2025-04-22T14:11:17.034592Z Error: Following tables show signs that either table datadir directory or frm<br />
INFO 2025-04-22T14:11:17.034744Z file was removed/corrupted. Please check server logs, examine datadir to<br />
INFO 2025-04-22T14:11:17.034915Z detect the issue and fix it before upgrade<br />
INFO 2025-04-22T14:11:17.041222Z database.#sql-7_2b1a9e4 - present in INFORMATION_SCHEMA&#039;s<br />
INFO 2025-04-22T14:11:17.041413Z INNODB_SYS_TABLES table but missing from TABLES table<br />
INFO 2025-04-22T14:11:17.045358Z 19) Tables recognized by InnoDB that belong to a different engine (engineMixup)<br />
<br />
Problem Summary:<br />
<br />
    Table #sql-7_2b1a9e4 is listed in INFORMATION_SCHEMA.INNODB_SYS_TABLES but not in INFORMATION_SCHEMA.TABLES.<br />
<br />
    It appears to be a leftover temporary table from a failed/crashed operation.<br />
<br />
    The logs indicate engineMixup, where InnoDB tables are being detected as belonging to a different storage engine.<br />
<br />
    This prevents the MySQL upgrade from proceeding.<br />
<br />
What We&#039;ve Tried:<br />
<br />
    Running:<br />
<br />
SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_TABLES WHERE NAME LIKE &#039;%#sql%&#039;;<br />
<br />
Attempting to drop the table with:<br />
<br />
    DROP TABLE `#mysql50##sql-7_2b1a9e4`;<br />
<br />
    But this fails, stating the table does not exist.<br />
<br />
Additional Constraints:<br />
<br />
    Dump and restore is not feasible, as the database size exceeds 500GB. This would result in unacceptable downtime for a production environment.<br />
<br />
Questions:<br />
<br />
    Is there a safe and clean way to remove orphan InnoDB table metadata (like #sql-7_2b1a9e4) without requiring a full export/import?<br />
<br />
    Are there any tools (e.g., from Percona, Oracle, or Google Cloud internal tools) that can repair or clean up InnoDB metadata inconsistencies?<br />
<br />
    If file-level repairs are an option, how can this be done securely within GCP Cloud SQL without risking data integrity?<br />
<br />
Any insights or similar experiences would be greatly appreciated, especially from those who have dealt with this type of upgrade issue on managed MySQL services. Thanks in advance!]]></description>
            <dc:creator>M Rudi Awalludin</dc:creator>
            <category>InnoDB</category>
            <pubDate>Thu, 24 Apr 2025 09:39:19 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,740413,740413#msg-740413</guid>
            <title>MySQL 8.4.2 MY-013935 IO-layer timeout before wait_timeout was reached. (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,740413,740413#msg-740413</link>
            <description><![CDATA[ Hello,<br />
<br />
we used MySQL 5.7.35 + java 17 web application with connector mysql-connector-j-8.2.0.<br />
<br />
Application is on different host and running on Windows platform. Database is running on Windows as well. <br />
<br />
<br />
We have migrated MySQL from 5.7.35 to 8.4.2 recently with connector mysql-connector-j-9.0.0. From that time, we can see a lot of errors in MySQL log:<br />
<br />
[ERROR] [MY-013935] [Server] IO-layer timeout before wait_timeout was reached.<br />
<br />
The message appears many times during day with no related application logs. Has anyone experience with this? What exactly that error mean?<br />
<br />
Thank you. Pavol]]></description>
            <dc:creator>Pavol S</dc:creator>
            <category>InnoDB</category>
            <pubDate>Mon, 10 Mar 2025 09:58:59 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,726553,726553#msg-726553</guid>
            <title>Deadlock (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,726553,726553#msg-726553</link>
            <description><![CDATA[ A couple of days ago this deadlock happened on our MySql 5.7 database:<br />
<br />
------------------------<br />
LATEST DETECTED DEADLOCK<br />
------------------------<br />
2024-09-25 11:03:39 0x14b52a06b700<br />
*** (1) TRANSACTION:<br />
TRANSACTION 7342267151, ACTIVE 0 sec starting index read<br />
mysql tables in use 1, locked 1<br />
LOCK WAIT 2 lock struct(s), heap size 1136, 1 row lock(s)<br />
MySQL thread id 23580984, OS thread handle 22769182357248, query id 422061910 10.11.1.43 multidialogo2 updating<br />
UPDATE `multiqueue` SET `postal_orders_generation_status` = &#039;DONE&#039; WHERE uuid = &#039;ff9c409d-7b11-55a2-a37f-a278d3b7a75b&#039;<br />
*** (1) WAITING FOR THIS LOCK TO BE GRANTED:<br />
RECORD LOCKS space id 5386 page no 877543 n bits 280 index uuid_uq of table `mdnetb_main`.`multiqueue` trx id 7342267151 lock_mode X locks rec but not gap waiting<br />
Record lock, heap no 214 PHYSICAL RECORD: n_fields 2; compact format; info bits 0<br />
 0: len 30; hex 66663963343039642d376231312d353561322d613337662d613237386433; asc ff9c409d-7b11-55a2-a37f-a278d3; (total 36 bytes);<br />
 1: len 4; hex 0012d0f0; asc     ;;<br />
<br />
*** (2) TRANSACTION:<br />
TRANSACTION 7342267150, ACTIVE 0 sec starting index read<br />
mysql tables in use 1, locked 1<br />
8 lock struct(s), heap size 1136, 5 row lock(s), undo log entries 1<br />
MySQL thread id 23580988, OS thread handle 22768326719232, query id 422061911 10.11.1.123 multidialogo2 updating<br />
UPDATE multiqueue SET `acknowledged_at` = &#039;2024-09-25 13:03:39&#039;, status = &#039;ACKNOWLEDGED&#039; , status_message = &#039;Queue has ben acknowledged by dispatch service&#039; , debug_last_modifier_class = &#039;Netbuilder\\Console\\Service\\Storage\\Queue\\QueueReportStorage&#039;  WHERE uuid = &#039;ff9c409d-7b11-55a2-a37f-a278d3b7a75b&#039;<br />
*** (2) HOLDS THE LOCK(S):<br />
RECORD LOCKS space id 5386 page no 877543 n bits 280 index uuid_uq of table `mdnetb_main`.`multiqueue` trx id 7342267150 lock mode S locks rec but not gap<br />
Record lock, heap no 214 PHYSICAL RECORD: n_fields 2; compact format; info bits 0<br />
 0: len 30; hex 66663963343039642d376231312d353561322d613337662d613237386433; asc ff9c409d-7b11-55a2-a37f-a278d3; (total 36 bytes);<br />
 1: len 4; hex 0012d0f0; asc     ;;<br />
<br />
<br />
The cause of the deadlock seems (to me) this:<br />
there are two PHP services that have issued two different UPDATE statements on the same table line *at the same instant*.<br />
<br />
I have two questions, though:<br />
<br />
1. the two statements are two UPDATE very similar, the lock mode should be X for both of them. Why the second one has the mode S ?<br />
2. the deadlock is caused by the simultaneity? What could be the best strategy to handle this risk? Adding a timeout the the UPDATE, in order to attempt again after the other one (hopefully) succeeds?<br />
<br />
Thanks in advance<br />
Nicola]]></description>
            <dc:creator>Nicola Farina</dc:creator>
            <category>InnoDB</category>
            <pubDate>Fri, 27 Sep 2024 09:45:46 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,725927,725927#msg-725927</guid>
            <title>Enhancing MVCC ReadView Scalability (5 replies)</title>
            <link>https://forums.mysql.com/read.php?22,725927,725927#msg-725927</link>
            <description><![CDATA[ The MVCC ReadView uses a vector to store the list of active transactions. In high-concurrency scenarios, this list can become large, leading to a larger working set. In NUMA environments, both querying and replication can become slower, potentially causing a single CPU time slice to miss its deadline and resulting in significant context-switching costs.]]></description>
            <dc:creator>Bin Wang</dc:creator>
            <category>InnoDB</category>
            <pubDate>Wed, 15 Jan 2025 13:33:30 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,725466,725466#msg-725466</guid>
            <title>MySql 5.7 wrong (apparently) value of character_maximum_length (2 replies)</title>
            <link>https://forums.mysql.com/read.php?22,725466,725466#msg-725466</link>
            <description><![CDATA[ Hi<br />
<br />
I am trying to analyze a table structure, to understand why ALTER TABLE operations take so long time.<br />
My attention comes to longtext and mediumtext columns.<br />
One of them, though, has a strange clue in the information_schema.COLUMNS view:<br />
character_maximum_length reports a extremely high value, which does not seem to relate to reality:<br />
<br />
this is the table structure:<br />
CREATE TABLE `multiqueue` (<br />
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,<br />
  `uuid` varchar(36) NOT NULL,<br />
  `draft_uuid` varchar(36) DEFAULT NULL COMMENT &#039;Original draft&#039;,<br />
  `main_queue_uuid` varchar(36) DEFAULT NULL COMMENT &#039;Means this is the alternative channels queue of another queue&#039;,<br />
  `original_request` mediumtext COMMENT &#039;Original request transmitted from the client&#039;,<br />
  `action` varchar(191) DEFAULT NULL,<br />
  `author_id` bigint(20) NOT NULL,<br />
  `idaccount` bigint(20) DEFAULT NULL COMMENT &#039;this is the owner_id&#039;,<br />
  `author_uuid` varchar(36) NOT NULL,<br />
  `owner_uuid` varchar(36) NOT NULL,<br />
  `idaccount_parent` bigint(20) DEFAULT NULL COMMENT &#039;Deprecated: the information is obtainable from idaccount&#039;,<br />
  `sendcode` varchar(191) DEFAULT NULL,<br />
  `client_name` varchar(32) NOT NULL DEFAULT &#039;UNKNOWN&#039;,<br />
  `client_version` varchar(191) DEFAULT NULL,<br />
  `client_key` varchar(191) DEFAULT NULL,<br />
  `memo` varchar(256) DEFAULT NULL,<br />
  `delivery_time` datetime DEFAULT NULL,<br />
  `upload_session_uuid` varchar(36) DEFAULT NULL,<br />
  `files` mediumtext,<br />
  `attachments` mediumtext,<br />
  `custom` mediumtext,<br />
  `sender` text,<br />
  `multicerta_options` text,<br />
  `posta_options` text,<br />
  `mail_options` text,<br />
  `multibox_options` text,<br />
  `dateins` datetime DEFAULT NULL,<br />
  `deadline_at` datetime DEFAULT NULL COMMENT &#039;Deadline to read, for channels like MultiCerta&#039;,<br />
  `deadline_event` enum(&#039;RECEIVED-NOTIFIED&#039;,&#039;RECEIVED-OPENED&#039;,&#039;RECEIVED-READ&#039;) DEFAULT NULL,<br />
  `codicelistino` varchar(191) DEFAULT NULL,<br />
  `sqs` smallint(1) NOT NULL,<br />
  `stato` varchar(4) NOT NULL COMMENT &#039;Deprecated: see status&#039;,<br />
  `log` text,<br />
  `invoice_tag` varchar(100) DEFAULT NULL,<br />
  `postal_account` text,<br />
  `notify_email` varchar(191) DEFAULT NULL COMMENT &#039;Deprecated field, use notification_email_addresses, instead&#039;,<br />
  `notification_email_addresses` varchar(512) DEFAULT NULL COMMENT &#039;Comma separated values of valid emails&#039;,<br />
  `status` enum(&#039;WAITING-FOR-COST-CONFIRMATION&#039;,&#039;COST-CONFIRMED&#039;,&#039;TRANSMITTED&#039;,&#039;ACKNOWLEDGED&#039;,&#039;ABANDONED&#039;,&#039;SUCCEDED&#039;,&#039;ARCHIVED&#039;,&#039;DISPATCH-ERROR&#039;,&#039;ABORTED-BY-USER&#039;) NOT NULL DEFAULT &#039;WAITING-FOR-COST-CONFIRMATION&#039; COMMENT &#039;\r\n            [WAITING-FOR-COST-CONFIRMATION] queue in pending cost confirmation status,\r\n            [COST-CONFIRMED] cost have been confirmed by user, or have been automatically confirmed due to his settings,\r\n            [TRANSMITTED] transmitted to dispatching service,\r\n            [ACKNOWLEDGED] received by dispatching service,\r\n            [ABANDONED] pending from too much time,\r\n            [SUCCEDED] queue has been delivered successfully to all of the recipients,\r\n            [ARCHIVED] succeded queue moved in the archive,\r\n            [DISPATCH-ERROR] error while dispatching service,\r\n            [ABORTED-BY-USER] refused by user after acknowledgement&#039;,<br />
  `status_message` varchar(512) NOT NULL,<br />
  `created_at` datetime NOT NULL,<br />
  `cost_confirmed_at` datetime DEFAULT NULL,<br />
  `transmitted_at` datetime DEFAULT NULL,<br />
  `acknowledged_at` datetime DEFAULT NULL,<br />
  `error_at` datetime DEFAULT NULL,<br />
  `abandoned_at` datetime DEFAULT NULL,<br />
  `succeded_at` datetime DEFAULT NULL,<br />
  `archived_at` datetime DEFAULT NULL COMMENT &#039;Date the user moved the queue in the archive, cannot be acheived if the queue is not succeded&#039;,<br />
  `aborted_by_user_at` datetime DEFAULT NULL,<br />
  `status_error_message` text,<br />
  `recipient_settings_extracted` bit(1) NOT NULL DEFAULT b&#039;0&#039; COMMENT &#039;indicates that this queue&#039;&#039;s recipients data have been extracted and saved in the recipient log table.&#039;,<br />
  `postal_orders_generation_status` enum(&#039;NONE&#039;,&#039;PENDING&#039;,&#039;DONE&#039;,&#039;ERROR&#039;) DEFAULT &#039;NONE&#039; COMMENT &#039;Status of postal order (files) generation, NONE: no postal order to process, PENDING: processing postal orders, DONE: processed, ERROR: error during processing&#039;,<br />
  `history_year` int(4) DEFAULT NULL COMMENT &#039;Year to be used in historicization&#039;,<br />
  `history_month` int(2) DEFAULT NULL COMMENT &#039;Year to be used in historicization&#039;,<br />
  `history_day` int(2) DEFAULT NULL COMMENT &#039;Year to be used in historicization&#039;,<br />
  `debug_last_modifier_class` varchar(512) DEFAULT &#039;UNKNOWN&#039; COMMENT &#039;last class acceding to storage service&#039;,<br />
  `save_cost_with_legacy_strategy` enum(&#039;YES&#039;,&#039;NO&#039;) DEFAULT &#039;YES&#039;,<br />
  `search_uses_email` tinyint(4) NOT NULL COMMENT &#039;The queue uses email&#039;,<br />
  `search_uses_pec` tinyint(4) NOT NULL COMMENT &#039;The queue uses pec&#039;,<br />
  `search_uses_letter` tinyint(4) NOT NULL COMMENT &#039;The queue uses letter (ex sendposta)&#039;,<br />
  `search_uses_multibox` tinyint(4) NOT NULL COMMENT &#039;The queue uses multibox&#039;,<br />
  `search_uses_multicerta` tinyint(4) NOT NULL COMMENT &#039;The queue uses multicerta&#039;,<br />
  `search_recipients_text` longtext NOT NULL COMMENT &#039;Used to search recipients associated to queue&#039;,<br />
  `directory` enum(&#039;ARCHIVE&#039;) DEFAULT NULL,<br />
  PRIMARY KEY (`id`),<br />
  UNIQUE KEY `uuid_uq` (`uuid`),<br />
  KEY `multiqueue_upload_session_fk` (`upload_session_uuid`),<br />
  KEY `multiqueue_multiqueue_draft_uuid_fk` (`draft_uuid`),<br />
  KEY `multiqueue_sendcode_idx` (`sendcode`),<br />
  KEY `multiqueue_idaccount_fk` (`idaccount`),<br />
  KEY `multiqueue_idaccount_parent_fk` (`idaccount_parent`),<br />
  KEY `multiqueue_owner_uuid_account_uuid_fk` (`owner_uuid`),<br />
  KEY `multiqueue_dateins_idx` (`dateins`),<br />
  KEY `multiqueue_status_idx` (`status`),<br />
  KEY `postal_orders_generation_status_idx` (`postal_orders_generation_status`),<br />
  KEY `multiqueue_client_name_idx` (`client_name`),<br />
  KEY `multiqueue_history_year_idx` (`history_year`),<br />
  KEY `multiqueue_history_month_idx` (`history_month`),<br />
  KEY `multiqueue_history_day_idx` (`history_day`),<br />
  KEY `multiqueue_multiqueue_main_queue_uuid_fk` (`main_queue_uuid`),<br />
  KEY `multiqueue_author_uuid_account_uuid_fk` (`author_uuid`),<br />
  KEY `multiqueue_author_id_account_idaccount_fk` (`author_id`),<br />
  KEY `multiqueue_directory_idx` (`directory`),<br />
  CONSTRAINT `multiqueue_author_id_account_idaccount_fk` FOREIGN KEY (`author_id`) REFERENCES `account` (`IDACCOUNT`),<br />
  CONSTRAINT `multiqueue_author_uuid_account_uuid_fk` FOREIGN KEY (`author_uuid`) REFERENCES `account` (`uuid`),<br />
  CONSTRAINT `multiqueue_idaccount_fk` FOREIGN KEY (`idaccount`) REFERENCES `account` (`IDACCOUNT`) ON DELETE SET NULL,<br />
  CONSTRAINT `multiqueue_idaccount_parent_fk` FOREIGN KEY (`idaccount_parent`) REFERENCES `account` (`IDACCOUNT`) ON DELETE SET NULL,<br />
  CONSTRAINT `multiqueue_multiqueue_draft_uuid_fk` FOREIGN KEY (`draft_uuid`) REFERENCES `multiqueue_draft` (`uuid`),<br />
  CONSTRAINT `multiqueue_multiqueue_main_queue_uuid_fk` FOREIGN KEY (`main_queue_uuid`) REFERENCES `multiqueue` (`uuid`),<br />
  CONSTRAINT `multiqueue_owner_uuid_account_uuid_fk` FOREIGN KEY (`owner_uuid`) REFERENCES `account` (`uuid`),<br />
  CONSTRAINT `multiqueue_upload_session_fk` FOREIGN KEY (`upload_session_uuid`) REFERENCES `file_transfer_upload_session` (`uuid`) ON DELETE SET NULL<br />
) ENGINE=InnoDB AUTO_INCREMENT=1186654 DEFAULT CHARSET=utf8<br />
<br />
For the column &#039;search_recipients_text&#039; the view COLUMNS reports<br />
4294967295 for CHARACTER_MAXIMUM_LENGTH<br />
<br />
If I run this query, though:<br />
<br />
select length(q.search_recipients_text), q.search_recipients_text, q.*<br />
from multiqueue q<br />
order by length(q.search_recipients_text) desc<br />
<br />
the biggest length I get is 114649<br />
<br />
Perhaps am I misunderstanding the meaning of the CHARACTER_MAXIMUM_LENGTH field ?<br />
<br />
Thanks in advance<br />
Nicola]]></description>
            <dc:creator>Nicola Farina</dc:creator>
            <category>InnoDB</category>
            <pubDate>Tue, 13 Aug 2024 13:50:23 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,725456,725456#msg-725456</guid>
            <title>MySQL execute plan behaves different in Master and Slave (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,725456,725456#msg-725456</link>
            <description><![CDATA[ I have one MySQL query, and that query is using an index on the master but not using an index on the slave.<br />
<br />
The query is as simple as SELECT * FROM table1 JOIN table2 ON table1.primary_id = table2.fk_id with simple where condition.<br />
<br />
We checked the structure, indexes, global variables, data, and everything else. Everything is in sync.<br />
<br />
I am expecting the query to use the index on the slave.]]></description>
            <dc:creator>Jagadeesh Chinnathambi</dc:creator>
            <category>InnoDB</category>
            <pubDate>Sun, 11 Aug 2024 18:24:35 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,725416,725416#msg-725416</guid>
            <title>Delete With JSON Filling /tmp Space (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,725416,725416#msg-725416</link>
            <description><![CDATA[ MySQL 8.0.37<br />
<br />
statement:  DELETE FROM table WHERE datefield&lt;&#039;date&#039;;<br />
<br />
table has 6 int, date, timestamp, and short (&lt;32) varchar fields and 1 LARGE JSON field.  Deleting 2500 records is filling 800M of /tmp space.<br />
<br />
Is the select part saving the JSON field?  My estimate of the record space is just over the available /tmp space.<br />
<br />
If so, why?  Is this part of the problem/documentation issue I have seen reported for blobs filling the sort buffers?]]></description>
            <dc:creator>Sam Beard</dc:creator>
            <category>InnoDB</category>
            <pubDate>Wed, 07 Aug 2024 22:10:30 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,725070,725070#msg-725070</guid>
            <title>innodb_buffer_pool (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,725070,725070#msg-725070</link>
            <description><![CDATA[ Storage pool size parameter: innodb_buffer_pool<br />
1. Understanding the size of the storage pool: When accessing a large amount of data, the time for large amounts of data is not directly related to the size of the storage pool.<br />
2. When the storage pool memory is exhausted, querying data will require a large number of disk IO operations;<br />
3. Causes the database server CPU and IO to become full, eventually causing the service to crash;<br />
<br />
question. Is there a MYSQL data indicator that can monitor that the storage pool size is about to be used up, and subsequent disk scans will be performed, requiring memory expansion operations?]]></description>
            <dc:creator>小强 小</dc:creator>
            <category>InnoDB</category>
            <pubDate>Mon, 08 Jul 2024 10:13:52 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,725054,725054#msg-725054</guid>
            <title>mysql buffer pool how monitor (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,725054,725054#msg-725054</link>
            <description><![CDATA[ The memory size of my server is 128GB with a 4-core processor, and I have configured the MySQL buffer pool to 12GB. Every time when concurrent requests start, I notice that the MySQL service becomes slow, with FREE_BUFFERS approaching 0, server I/O reaching 100%, and CPU usage spiking to 400%. Despite having reasonable indexes for queries. How should I adjust the MySQL buffer pool size to avoid the aforementioned issues, or which MySQL metrics should I monitor to set alerts for the server to prevent crashes?]]></description>
            <dc:creator>c h</dc:creator>
            <category>InnoDB</category>
            <pubDate>Sun, 07 Jul 2024 13:06:51 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724860,724860#msg-724860</guid>
            <title>[ERROR] InnoDB: Database page corruption on disk or a failed file read of page (2 replies)</title>
            <link>https://forums.mysql.com/read.php?22,724860,724860#msg-724860</link>
            <description><![CDATA[ Hello,<br />
<br />
I ran into a problem with my MySQL database on a Nvidia Jetson Nano. All of a sudden the database went corrupt with message:<br />
[ERROR] InnoDB: Database page corruption on disk or a failed file read of page [page id: space=0, page number=2078]. You may have to recover from a backup.<br />
<br />
According to the IT-guy who restored the database one of the files were missing<br />
pid-file        = /var/run/mysqld/mysqld.pid<br />
socket          = /var/run/mysqld/mysqld.sock<br />
<br />
The version was:<br />
Server version: 5.7.42-0ubuntu0.18.04.1 (Ubuntu)<br />
<br />
The restoration process was:<br />
* Put mysql in recovery mode<br />
* Made a backup with mysqldump<br />
* Deleted the databases<br />
* Cleared transaction logs<br />
* Restored the system database<br />
* Imported the mysql dump<br />
* Removed recovery mode<br />
* Started in normal mode<br />
<br />
No data was lost but we had some off time, and we don&#039;t want this to happen again. I am grateful for responses so we can prevent this to happen again.<br />
<br />
Is there any knowns bugs for this version that could have caused this or any other known problems that can cause this?<br />
<br />
<br />
$ sudo tail /var/log/mysql/error.log -n 10000<br />
<br />
2024-06-17T11:22:36.184533Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.42-0ubuntu0.18.04.1) starting as process 9827 ...<br />
<br />
2024-06-17T11:22:36.196894Z 0 [Note] InnoDB: PUNCH HOLE support available<br />
<br />
2024-06-17T11:22:36.196969Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins<br />
<br />
2024-06-17T11:22:36.196999Z 0 [Note] InnoDB: Uses event mutexes<br />
<br />
2024-06-17T11:22:36.197026Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier<br />
<br />
2024-06-17T11:22:36.197053Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.13<br />
<br />
2024-06-17T11:22:36.197080Z 0 [Note] InnoDB: Using Linux native AIO<br />
<br />
2024-06-17T11:22:36.198518Z 0 [Note] InnoDB: Number of pools: 1<br />
<br />
2024-06-17T11:22:36.198950Z 0 [Note] InnoDB: Not using CPU crc32 instructions<br />
<br />
2024-06-17T11:22:36.204126Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M<br />
<br />
2024-06-17T11:22:36.240555Z 0 [Note] InnoDB: Completed initialization of buffer pool<br />
<br />
2024-06-17T11:22:36.246257Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().<br />
<br />
2024-06-17T11:22:36.262871Z 0 [Note] InnoDB: Highest supported file format is Barracuda.<br />
<br />
2024-06-17T11:22:36.266851Z 0 [Note] InnoDB: Log scan progressed past the checkpoint lsn 11307628957<br />
<br />
2024-06-17T11:22:36.266921Z 0 [Note] InnoDB: Doing recovery: scanned up to log sequence number 11307629499<br />
<br />
2024-06-17T11:22:36.267349Z 0 [Note] InnoDB: Database was not shutdown normally!<br />
<br />
2024-06-17T11:22:36.267387Z 0 [Note] InnoDB: Starting crash recovery.<br />
<br />
2024-06-17T11:22:36.453977Z 0 [Note] InnoDB: Removed temporary tablespace data file: &quot;ibtmp1&quot;<br />
<br />
2024-06-17T11:22:36.454055Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables<br />
<br />
2024-06-17T11:22:36.454205Z 0 [Note] InnoDB: Setting file &#039;./ibtmp1&#039; size to 12 MB. Physically writing the file full; Please wait ...<br />
<br />
2024-06-17T11:22:37.092688Z 0 [Note] InnoDB: File &#039;./ibtmp1&#039; size is now 12 MB.<br />
<br />
2024-06-17T11:22:37.095278Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.<br />
<br />
2024-06-17T11:22:37.095333Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.<br />
<br />
2024-06-17T11:22:37.096459Z 0 [Note] InnoDB: Waiting for purge to start<br />
<br />
2024-06-17T11:22:37.146798Z 0 [Note] InnoDB: 5.7.42 started; log sequence number 11307629499<br />
<br />
2024-06-17T11:22:37.147194Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool<br />
<br />
2024-06-17T11:22:37.147768Z 0 [Note] Plugin &#039;FEDERATED&#039; is disabled.<br />
<br />
2024-06-17T11:22:37.157476Z 0 [Note] InnoDB: Buffer pool(s) load completed at 240617 13:22:37<br />
<br />
2024-06-17T11:22:37.170107Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them.<br />
<br />
2024-06-17T11:22:37.170190Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory.<br />
<br />
2024-06-17T11:22:37.170215Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher.<br />
<br />
2024-06-17T11:22:37.170234Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher.<br />
<br />
2024-06-17T11:22:37.172061Z 0 [Warning] CA certificate ca.pem is self signed.<br />
<br />
2024-06-17T11:22:37.172185Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory.<br />
<br />
2024-06-17T11:22:37.172456Z 0 [Note] Server hostname (bind-address): &#039;127.0.0.1&#039;; port: 3306<br />
<br />
2024-06-17T11:22:37.172497Z 0 [Note]   - &#039;127.0.0.1&#039; resolves to &#039;127.0.0.1&#039;;<br />
<br />
2024-06-17T11:22:37.172566Z 0 [Note] Server socket created on IP: &#039;127.0.0.1&#039;.<br />
<br />
2024-06-17T11:22:37.218912Z 0 [Note] Event Scheduler: Loaded 0 events<br />
<br />
2024-06-17T11:22:37.219457Z 0 [Note] /usr/sbin/mysqld: ready for connections.<br />
<br />
Version: &#039;5.7.42-0ubuntu0.18.04.1&#039;  socket: &#039;/var/run/mysqld/mysqld.sock&#039;  port: 3306  (Ubuntu)<br />
<br />
2024-06-17T11:22:37.288008Z 0 [ERROR] InnoDB: Database page corruption on disk or a failed file read of page [page id: space=0, page number=2078]. You may have to recover from a backup.<br />
<br />
2024-06-17T11:22:37.288078Z 0 [Note] InnoDB: Page dump in ascii and hex (16384 bytes):]]></description>
            <dc:creator>Tony Karlsson</dc:creator>
            <category>InnoDB</category>
            <pubDate>Mon, 22 Jul 2024 12:56:55 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724810,724810#msg-724810</guid>
            <title>Troubleshooting innodb mysql-router containers as they are in a unhealthy state (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,724810,724810#msg-724810</link>
            <description><![CDATA[ Hi,<br />
<br />
I have been facing an issue with my innodb setup of 3 nodes. Each node runs two containers  with image mysql/mysql-server:5.7 and mysql/mysql-router:latest. <br />
<br />
These nodes are VM of an esxi which were restarted because of a crash. So when I restarted the containers I am not able to get the router container to a healthy state rather keeps restarting.<br />
<br />
so I exec to the vantage-mysql container and mysqlsh to access the shell in order to administer the database. On the master node,  Using the JS console I am not able to get the cluster state so here is what I always see:<br />
<br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  JS &gt; var cluster = dba.getCluster(&#039;prodCluster_new&#039;);<br />
Dba.getCluster: This function is not available through a session to an instance belonging to an unmanaged replication group (RuntimeError)<br />
<br />
I tried to reboot the cluster but here is what I got:<br />
<br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  JS &gt; var cluster = dba.rebootClusterFromCompleteOutage();<br />
Dba.rebootClusterFromCompleteOutage: This function is not available through a session to an instance belonging to an unmanaged replication group (RuntimeError)<br />
<br />
 <br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  SQL &gt; SELECT * FROM performance_schema.replication_group_members;<br />
+---------------------------+--------------------------------------+---------------+-------------+--------------+<br />
| CHANNEL_NAME              | MEMBER_ID                            | MEMBER_HOST   | MEMBER_PORT | MEMBER_STATE |<br />
+---------------------------+--------------------------------------+---------------+-------------+--------------+<br />
| group_replication_applier | b0d2cc2d-2993-11ef-b92f-00505680c619 | 1XX.1XX.XX.XX |        3306 | ONLINE       |<br />
+---------------------------+--------------------------------------+---------------+-------------+--------------+<br />
1 row in set (0.0004 sec)<br />
<br />
<br />
So from the above there is only one member which is the master that is online<br />
<br />
so from another member I ran the above code and here is what I got:<br />
<br />
MySQL  1XX.1XX.XX.XX:3306 ssl  SQL &gt; CHANGE MASTER TO MASTER_HOST=&#039;1XX.1XX.XX.XX&#039;, MASTER_USER=&#039;repl&#039;, MASTER_PASSWORD=&#039;password&#039;, MASTER_LOG_FILE=&#039;binlog.000442&#039;, MASTER_LOG_POS=295030;<br />
Query OK, 0 rows affected, 1 warning (0.0136 sec)<br />
Note (code 1760): Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the &#039;START SLAVE Syntax&#039; in the MySQL Manual for more information.<br />
<br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  SQL &gt; START GROUP_REPLICATION;<br />
Query OK, 0 rows affected, 1 warning (6.0626 sec)<br />
Warning (code 1681): &#039;group_replication_allow_local_disjoint_gtids_join&#039; is deprecated and will be removed in a future release.<br />
<br />
 MySQL  192.168.XX.XX:3306 ssl  SQL &gt; SELECT * FROM performance_schema.replication_group_members;<br />
+---------------------------+--------------------------------------+---------------+-------------+--------------+<br />
| CHANNEL_NAME              | MEMBER_ID                            | MEMBER_HOST   | MEMBER_PORT | MEMBER_STATE |<br />
+---------------------------+--------------------------------------+---------------+-------------+--------------+<br />
| group_replication_applier | 9cc4dc4f-2993-11ef-b5a9-005056806695 | 192.168.40.47 |        3306 | RECOVERING   |<br />
| group_replication_applier | a97b2419-2993-11ef-b86e-005056809797 | 192.168.40.46 |        3306 | RECOVERING   |<br />
| group_replication_applier | b0d2cc2d-2993-11ef-b92f-00505680c619 | 192.168.40.45 |        3306 | ONLINE       |<br />
+---------------------------+--------------------------------------+---------------+-------------+--------------+<br />
<br />
the same for the other two nodes. So these nodes always say that they are in RECOVERING state whereas the master is always ONLINE<br />
<br />
so when I run the command &quot;show slave status&quot; on the master node here is what I get:<br />
<br />
Fatal error: The slave I/O thread stops because master and slave have equal MySQL server ids; these ids must be different for replication to work (or the --replicate-same-server-id option must be used on slave but this does not always make sense; please check the manual before using it). |  <br />
<br />
So I check the server_ids which are all unique:<br />
<br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  SQL &gt; SHOW VARIABLES LIKE &#039;server_id&#039;;<br />
+---------------+-------+<br />
| Variable_name | Value |<br />
+---------------+-------+<br />
| server_id     | 45    |<br />
+---------------+-------+<br />
1 row in set (0.0029 sec)<br />
<br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  SQL &gt;  SHOW VARIABLES LIKE &#039;server_id&#039;;<br />
+---------------+-------+<br />
| Variable_name | Value |<br />
+---------------+-------+<br />
| server_id     | 46    |<br />
+---------------+-------+<br />
1 row in set (0.0028 sec)<br />
<br />
 MySQL  1XX.1XX.XX.XX:3306 ssl  SQL &gt; SHOW VARIABLES LIKE &#039;server_id&#039;;<br />
+---------------+-------+<br />
| Variable_name | Value |<br />
+---------------+-------+<br />
| server_id     | 47    |<br />
+---------------+-------+<br />
1 row in set (0.0033 sec)<br />
<br />
For each node 1XX.1XX.XX.XX are different IP addresses, I didnt want to reveal the ip address here.]]></description>
            <dc:creator>Faisal Basha</dc:creator>
            <category>InnoDB</category>
            <pubDate>Fri, 14 Jun 2024 16:30:49 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724625,724625#msg-724625</guid>
            <title>Innodb: join of large table to small table is slow if small table has less than 7 rows (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,724625,724625#msg-724625</link>
            <description><![CDATA[ I happened to read this post  <a href="https://forums.mysql.com/read.php?22,620920,620920#msg-620920"  rel="nofollow">https://forums.mysql.com/read.php?22,620920,620920#msg-620920</a> of 2014 and I tried and confirmed that it could even be reproduced now in 2024.<br />
<br />
I wonder if there&#039;s any method to solve this problem or any way to let the optimizer do better?<br />
<br />
My MySQL is a RDS instance from one public cloud provider, and the version is :<br />
mysql&gt; show variables like &quot;%innodb_version&quot;;<br />
+----------------+--------+<br />
| Variable_name  | Value  |<br />
+----------------+--------+<br />
| innodb_version | 8.0.28 |<br />
+----------------+--------+<br />
1 row in set (0.00 sec)<br />
<br />
mysql&gt; show variables like &quot;version&quot;;<br />
+---------------+---------------+<br />
| Variable_name | Value         |<br />
+---------------+---------------+<br />
| version       | 8.0.28-230701 |<br />
+---------------+---------------+<br />
1 row in set (0.00 sec)<br />
<br />
<br />
<br />
Below is how I reproduced the problem(some sql copied from the original post):<br />
<br />
#create the large table<br />
CREATE TABLE t1 (id int(11) NOT NULL AUTO_INCREMENT, name varchar(255) NOT NULL, t2_id int(11) NOT NULL, PRIMARY KEY (id)) ENGINE=InnoDB DEFAULT CHARSET=utf8;<br />
<br />
#create the small table<br />
CREATE TABLE t2 (id int(11) NOT NULL AUTO_INCREMENT, name varchar(255) NOT NULL, PRIMARY KEY (id)) ENGINE=InnoDB DEFAULT CHARSET=utf8;<br />
<br />
#insert 1 record in the small table<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
<br />
#insert 262144 records in the large table; we do this by inserting 1 record and exponentially duplicating the records 18 times<br />
INSERT INTO t1 (name, t2_id) VALUES (&#039;large table&#039;, 1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
INSERT INTO t1 (name, t2_id) (SELECT name, t2_id FROM t1);<br />
<br />
#we now have 262144 identical rows in t1<br />
mysql&gt; select count(*) from t1;<br />
+----------+<br />
| count(*) |<br />
+----------+<br />
|   262144 |<br />
+----------+<br />
1 row in set (0.04 sec)<br />
<br />
mysql&gt; select count(*) from t2;<br />
+----------+<br />
| count(*) |<br />
+----------+<br />
|        1 |<br />
+----------+<br />
1 row in set (0.01 sec)<br />
<br />
<br />
<br />
#run the following query; this runs relatively slow; 0.12s<br />
SELECT t1.id, t1.name, t2.id, t2.name FROM t1, t2 WHERE t1.t2_id=t2.id ORDER BY t1.id LIMIT 0,10;<br />
+----+-------------+----+-------------+<br />
| id | name        | id | name        |<br />
+----+-------------+----+-------------+<br />
|  1 | large table |  1 | small table |<br />
|  2 | large table |  1 | small table |<br />
|  3 | large table |  1 | small table |<br />
|  4 | large table |  1 | small table |<br />
|  6 | large table |  1 | small table |<br />
|  7 | large table |  1 | small table |<br />
|  8 | large table |  1 | small table |<br />
|  9 | large table |  1 | small table |<br />
| 13 | large table |  1 | small table |<br />
| 14 | large table |  1 | small table |<br />
+----+-------------+----+-------------+<br />
10 rows in set (0.12 sec)<br />
<br />
<br />
#run explain; the primary keys are NOT used<br />
EXPLAIN format=tree SELECT t1.id, t1.name, t2.id, t2.name FROM t1, t2 WHERE t1.t2_id=t2.id ORDER BY t1.id LIMIT 0,10;<br />
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br />
| EXPLAIN                                                                                                                                                                                                                                                                                                                                                             |<br />
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br />
| -&gt; Limit: 10 row(s)<br />
    -&gt; Sort: t1.id, limit input to 10 row(s) per chunk<br />
        -&gt; Stream results  (cost=26302.50 rows=26201)<br />
            -&gt; Inner hash join (t1.t2_id = t2.id)  (cost=26302.50 rows=26201)<br />
                -&gt; Table scan on t1  (cost=2721.35 rows=262010)<br />
                -&gt; Hash<br />
                    -&gt; Table scan on t2  (cost=0.25 rows=1)<br />
 |<br />
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br />
1 row in set (0.00 sec)<br />
<br />
<br />
<br />
#Now, let&#039;s add 6 more records to the small table<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
INSERT INTO t2 (name) VALUES (&#039;small table&#039;);<br />
<br />
#We now have 7 rows in the small table<br />
mysql&gt; select count(*) from t1;<br />
+----------+<br />
| count(*) |<br />
+----------+<br />
|   262144 |<br />
+----------+<br />
1 row in set (0.02 sec)<br />
<br />
mysql&gt; select count(*) from t2;<br />
+----------+<br />
| count(*) |<br />
+----------+<br />
|        7 |<br />
+----------+<br />
1 row in set (0.01 sec)<br />
<br />
<br />
#run the query again; now it is fast; 0.00s<br />
SELECT t1.id, t1.name, t2.id, t2.name FROM t1, t2 WHERE t1.t2_id=t2.id ORDER BY t1.id LIMIT 0,10;<br />
+----+-------------+----+-------------+<br />
| id | name        | id | name        |<br />
+----+-------------+----+-------------+<br />
|  1 | large table |  1 | small table |<br />
|  2 | large table |  1 | small table |<br />
|  3 | large table |  1 | small table |<br />
|  4 | large table |  1 | small table |<br />
|  6 | large table |  1 | small table |<br />
|  7 | large table |  1 | small table |<br />
|  8 | large table |  1 | small table |<br />
|  9 | large table |  1 | small table |<br />
| 13 | large table |  1 | small table |<br />
| 14 | large table |  1 | small table |<br />
+----+-------------+----+-------------+<br />
10 rows in set (0.00 sec)<br />
<br />
#run explain; the primary keys are used<br />
EXPLAIN format=tree SELECT t1.id, t1.name, t2.id, t2.name FROM t1, t2 WHERE t1.t2_id=t2.id ORDER BY t1.id LIMIT 0,10;<br />
+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br />
| EXPLAIN                                                                                                                                                                                                                                                      |<br />
+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br />
| -&gt; Limit: 10 row(s)  (cost=39302.51 rows=10)<br />
    -&gt; Nested loop inner join  (cost=39302.51 rows=10)<br />
        -&gt; Index scan on t1 using PRIMARY  (cost=0.00 rows=10)<br />
        -&gt; Single-row index lookup on t2 using PRIMARY (id=t1.t2_id)  (cost=0.15 rows=1)<br />
 |<br />
+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+<br />
<br />
#More info<br />
mysql&gt; show table status;<br />
+------+--------+---------+------------+--------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+---------------------+------------+-----------------+----------+----------------+---------+<br />
| Name | Engine | Version | Row_format | Rows   | Avg_row_length | Data_length | Max_data_length | Index_length | Data_free | Auto_increment | Create_time         | Update_time         | Check_time | Collation       | Checksum | Create_options | Comment |<br />
+------+--------+---------+------------+--------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+---------------------+------------+-----------------+----------+----------------+---------+<br />
| t1   | InnoDB |      10 | Dynamic    | 262010 |             42 |    11026432 |               0 |            0 |   4194304 |         458731 | 2024-06-04 15:31:25 | 2024-06-04 15:31:47 | NULL       | utf8_general_ci |     NULL |                |         |<br />
| t2   | InnoDB |      10 | Dynamic    |      7 |           2340 |       16384 |               0 |            0 |         0 |              8 | 2024-06-04 15:31:30 | 2024-06-04 15:34:20 | NULL       | utf8_general_ci |     NULL |                |         |<br />
+------+--------+---------+------------+--------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+---------------------+------------+-----------------+----------+----------------+---------+<br />
2 rows in set (0.01 sec)<br />
<br />
<br />
mysql&gt; show variables like &#039;innodb%&#039;;<br />
+-----------------------------------------------------+-------------------------+<br />
| Variable_name                                       | Value                   |<br />
+-----------------------------------------------------+-------------------------+<br />
| innodb_adaptive_flushing                            | ON                      |<br />
| innodb_adaptive_flushing_lwm                        | 10                      |<br />
| innodb_adaptive_hash_index                          | OFF                     |<br />
| innodb_adaptive_hash_index_parts                    | 8                       |<br />
| innodb_adaptive_max_sleep_delay                     | 150000                  |<br />
| innodb_api_bk_commit_interval                       | 5                       |<br />
| innodb_api_disable_rowlock                          | OFF                     |<br />
| innodb_api_enable_binlog                            | OFF                     |<br />
| innodb_api_enable_mdl                               | OFF                     |<br />
| innodb_api_trx_level                                | 0                       |<br />
| innodb_autoextend_increment                         | 64                      |<br />
| innodb_autoinc_lock_mode                            | 2                       |<br />
| innodb_buffer_pool_chunk_size                       | 134217728               |<br />
| innodb_buffer_pool_dump_at_shutdown                 | ON                      |<br />
| innodb_buffer_pool_dump_now                         | OFF                     |<br />
| innodb_buffer_pool_dump_pct                         | 25                      |<br />
| innodb_buffer_pool_filename                         | ib_buffer_pool          |<br />
| innodb_buffer_pool_in_core_file                     | ON                      |<br />
| innodb_buffer_pool_instances                        | 1                       |<br />
| innodb_buffer_pool_load_abort                       | OFF                     |<br />
| innodb_buffer_pool_load_at_startup                  | ON                      |<br />
| innodb_buffer_pool_load_now                         | OFF                     |<br />
| innodb_buffer_pool_size                             | 1073741824              |<br />
| innodb_change_buffer_max_size                       | 25                      |<br />
| innodb_change_buffering                             | all                     |<br />
| innodb_checksum_algorithm                           | crc32                   |<br />
| innodb_cmp_per_index_enabled                        | OFF                     |<br />
| innodb_commit_concurrency                           | 0                       |<br />
| innodb_compression_failure_threshold_pct            | 5                       |<br />
| innodb_compression_level                            | 6                       |<br />
| innodb_compression_pad_pct_max                      | 50                      |<br />
| innodb_concurrency_tickets                          | 5000                    |<br />
| innodb_data_file_path                               | ibdata1:128M:autoextend |<br />
| innodb_data_home_dir                                |                         |<br />
| innodb_ddl_buffer_size                              | 1048576                 |<br />
| innodb_ddl_threads                                  | 4                       |<br />
| innodb_deadlock_detect                              | ON                      |<br />
| innodb_dedicated_server                             | OFF                     |<br />
| innodb_default_row_format                           | dynamic                 |<br />
| innodb_directories                                  |                         |<br />
| innodb_disable_sort_file_cache                      | OFF                     |<br />
| innodb_doublewrite                                  | ON                      |<br />
| innodb_doublewrite_batch_size                       | 0                       |<br />
| innodb_doublewrite_dir                              |                         |<br />
| innodb_doublewrite_files                            | 2                       |<br />
| innodb_doublewrite_pages                            | 120                     |<br />
| innodb_extend_and_initialize                        | ON                      |<br />
| innodb_fast_shutdown                                | 1                       |<br />
| innodb_file_per_table                               | ON                      |<br />
| innodb_fill_factor                                  | 100                     |<br />
| innodb_flush_log_at_timeout                         | 1                       |<br />
| innodb_flush_log_at_trx_commit                      | 1                       |<br />
| innodb_flush_method                                 | O_DIRECT                |<br />
| innodb_flush_neighbors                              | 0                       |<br />
| innodb_flush_sync                                   | ON                      |<br />
| innodb_flushing_avg_loops                           | 30                      |<br />
| innodb_force_load_corrupted                         | OFF                     |<br />
| innodb_force_recovery                               | 0                       |<br />
| innodb_fsync_threshold                              | 0                       |<br />
| innodb_ft_aux_table                                 |                         |<br />
| innodb_ft_cache_size                                | 8000000                 |<br />
| innodb_ft_enable_diag_print                         | OFF                     |<br />
| innodb_ft_enable_stopword                           | ON                      |<br />
| innodb_ft_max_token_size                            | 84                      |<br />
| innodb_ft_min_token_size                            | 3                       |<br />
| innodb_ft_num_word_optimize                         | 2000                    |<br />
| innodb_ft_result_cache_limit                        | 2000000000              |<br />
| innodb_ft_server_stopword_table                     |                         |<br />
| innodb_ft_sort_pll_degree                           | 2                       |<br />
| innodb_ft_total_cache_size                          | 640000000               |<br />
| innodb_ft_user_stopword_table                       |                         |<br />
| innodb_idle_flush_pct                               | 100                     |<br />
| innodb_io_capacity                                  | 12000                   |<br />
| innodb_io_capacity_max                              | 24000                   |<br />
| innodb_lock_wait_timeout                            | 50                      |<br />
| innodb_log_buffer_size                              | 33554432                |<br />
| innodb_log_checksums                                | ON                      |<br />
| innodb_log_compressed_pages                         | ON                      |<br />
| innodb_log_file_size                                | 1048576000              |<br />
| innodb_log_files_in_group                           | 2                       |<br />
| innodb_log_group_home_dir                           | ./                      |<br />
| innodb_log_spin_cpu_abs_lwm                         | 80                      |<br />
| innodb_log_spin_cpu_pct_hwm                         | 50                      |<br />
| innodb_log_wait_for_flush_spin_hwm                  | 400                     |<br />
| innodb_log_write_ahead_size                         | 8192                    |<br />
| innodb_log_writer_threads                           | ON                      |<br />
| innodb_lru_scan_depth                               | 2048                    |<br />
| innodb_max_dirty_pages_pct                          | 75.000000               |<br />
| innodb_max_dirty_pages_pct_lwm                      | 0.000000                |<br />
| innodb_max_purge_lag                                | 0                       |<br />
| innodb_max_purge_lag_delay                          | 0                       |<br />
| innodb_max_undo_log_size                            | 1073741824              |<br />
| innodb_monitor_disable                              |                         |<br />
| innodb_monitor_enable                               |                         |<br />
| innodb_monitor_reset                                |                         |<br />
| innodb_monitor_reset_all                            |                         |<br />
| innodb_numa_interleave                              | OFF                     |<br />
| innodb_old_blocks_pct                               | 37                      |<br />
| innodb_old_blocks_time                              | 1000                    |<br />
| innodb_online_alter_log_max_size                    | 134217728               |<br />
| innodb_open_files                                   | 10240                   |<br />
| innodb_optimize_fulltext_only                       | OFF                     |<br />
| innodb_page_cleaners                                | 1                       |<br />
| innodb_page_size                                    | 16384                   |<br />
| innodb_parallel_read_threads                        | 4                       |<br />
| innodb_print_all_deadlocks                          | OFF                     |<br />
| innodb_print_ddl_logs                               | OFF                     |<br />
| innodb_purge_batch_size                             | 300                     |<br />
| innodb_purge_rseg_truncate_frequency                | 128                     |<br />
| innodb_purge_threads                                | 4                       |<br />
| innodb_random_read_ahead                            | OFF                     |<br />
| innodb_rds_data_file_purge                          | OFF                     |<br />
| innodb_rds_data_file_purge_all_at_shutdown          | OFF                     |<br />
| innodb_rds_data_file_purge_dir                      |                         |<br />
| innodb_rds_data_file_purge_immediate                | OFF                     |<br />
| innodb_rds_data_file_purge_interval                 | 100                     |<br />
| innodb_rds_data_file_purge_max_size                 | 32                      |<br />
| innodb_rds_data_lock_info_enabled                   | OFF                     |<br />
| innodb_rds_fatal_semaphore_timeout_seconds          | 600                     |<br />
| innodb_rds_print_data_file_purge_process            | OFF                     |<br />
| innodb_rds_warning_long_semaphore_threshold_seconds | 240                     |<br />
| innodb_read_ahead_threshold                         | 56                      |<br />
| innodb_read_io_threads                              | 4                       |<br />
| innodb_read_only                                    | OFF                     |<br />
| innodb_redo_log_archive_dirs                        |                         |<br />
| innodb_redo_log_encrypt                             | OFF                     |<br />
| innodb_replication_delay                            | 0                       |<br />
| innodb_rollback_on_timeout                          | OFF                     |<br />
| innodb_rollback_segments                            | 128                     |<br />
| innodb_segment_reserve_factor                       | 12.500000               |<br />
| innodb_sort_buffer_size                             | 1048576                 |<br />
| innodb_spin_wait_delay                              | 6                       |<br />
| innodb_spin_wait_pause_multiplier                   | 50                      |<br />
| innodb_stats_auto_recalc                            | ON                      |<br />
| innodb_stats_include_delete_marked                  | ON                      |<br />
| innodb_stats_method                                 | nulls_equal             |<br />
| innodb_stats_on_metadata                            | OFF                     |<br />
| innodb_stats_persistent                             | ON                      |<br />
| innodb_stats_persistent_sample_pages                | 20                      |<br />
| innodb_stats_transient_sample_pages                 | 8                       |<br />
| innodb_status_output                                | OFF                     |<br />
| innodb_status_output_locks                          | OFF                     |<br />
| innodb_strict_mode                                  | OFF                     |<br />
| innodb_sync_array_size                              | 1                       |<br />
| innodb_sync_spin_loops                              | 30                      |<br />
| innodb_table_locks                                  | ON                      |<br />
| innodb_temp_data_file_path                          | ibtmp1:12M:autoextend   |<br />
| innodb_temp_tablespaces_dir                         | ./#innodb_temp/         |<br />
| innodb_thread_concurrency                           | 0                       |<br />
| innodb_thread_sleep_delay                           | 10000                   |<br />
| innodb_tmpdir                                       |                         |<br />
| innodb_undo_directory                               | ./                      |<br />
| innodb_undo_log_encrypt                             | OFF                     |<br />
| innodb_undo_log_truncate                            | ON                      |<br />
| innodb_undo_tablespaces                             | 2                       |<br />
| innodb_use_fdatasync                                | OFF                     |<br />
| innodb_use_native_aio                               | ON                      |<br />
| innodb_validate_tablespace_paths                    | ON                      |<br />
| innodb_version                                      | 8.0.28                  |<br />
| innodb_write_io_threads                             | 4                       |<br />
+-----------------------------------------------------+-------------------------+<br />
160 rows in set (0.01 sec)<br />
<br />
<br />
mysql&gt; show index from t1;<br />
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+<br />
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment | Visible | Expression |<br />
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+<br />
| t1    |          0 | PRIMARY  |            1 | id          | A         |      262010 |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |<br />
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+<br />
1 row in set (0.04 sec)<br />
<br />
mysql&gt; show index from t2;<br />
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+<br />
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment | Visible | Expression |<br />
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+<br />
| t2    |          0 | PRIMARY  |            1 | id          | A         |           7 |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |<br />
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+]]></description>
            <dc:creator>Wenfeng Hu</dc:creator>
            <category>InnoDB</category>
            <pubDate>Tue, 04 Jun 2024 07:43:13 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724535,724535#msg-724535</guid>
            <title>Need help to review a serializability implementation for MySQL Cluster (12 replies)</title>
            <link>https://forums.mysql.com/read.php?22,724535,724535#msg-724535</link>
            <description><![CDATA[ Hey guys,<br />
<br />
I&#039;ve developed a serializability implementation for MySQL Cluster(NDB Cluster) and you are invited to peer-review it for me. I believe it is the fifth one in commercial database systems after: MySQL InnoDB&#039;s<br />
2PL, PostgreSQL&#039;s Serializable Snapshot Isolation, Google&#039;s Spanner&#039;s isolation level(I gave a proof in Appendix D of my article, the google guys<br />
may not have known this), CockroachDB&#039;s timestamp-based serializability implementation. The aim is to solve consistent, large(usually implies<br />
a distributed architecture) and performance-boosted database applications, which is daunting for those who care about consistency and<br />
serializability. This solution to the serializability problem is a 2nd-tier one, which means it doesn&#039;t require any coding. So as long as you can<br />
manage a MySQL Cluster, you can readily deploy and test your application with it. <br />
<br />
This on-going project is hosted @ <a href="https://github.com/creamyfish/conflict_serializability"  rel="nofollow">https://github.com/creamyfish/conflict_serializability</a><br />
I also set up a discussion site @ <a href="https://www.reddit.com/r/Serializability/"  rel="nofollow">https://www.reddit.com/r/Serializability/</a>, besides that of github&#039;s <br />
<br />
I am posting here since it also tackle the thrashing problem of 2PL with the so called Generalized Serializability Theorems.<br />
<br />
Come check it out if you are interested. Your help is highly appreciated!]]></description>
            <dc:creator>Alex Ou</dc:creator>
            <category>InnoDB</category>
            <pubDate>Fri, 02 Jan 2026 03:04:56 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724474,724474#msg-724474</guid>
            <title>Reproducing Bug #115113 (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,724474,724474#msg-724474</link>
            <description><![CDATA[ <a href="https://bugs.mysql.com/bug.php?id=115113"  rel="nofollow">https://bugs.mysql.com/bug.php?id=115113</a><br />
<br />
Could you pelase try to reproduce the following bug with Linux (amd64)?<br />
<br />
I think it is present across 8.0.x-8.4.0 codebase, I think it is reproducible on a variety of platforms/environments.<br />
<br />
Best,<br />
Gabriel]]></description>
            <dc:creator>Gabriel Barcelo</dc:creator>
            <category>InnoDB</category>
            <pubDate>Mon, 27 May 2024 11:09:42 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724345,724345#msg-724345</guid>
            <title>Informations and tune for Purge system! (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,724345,724345#msg-724345</link>
            <description><![CDATA[ Hi all,<br />
i have some questions about MySQL purge system.<br />
I read from the official documentation the purge system is automatically scheduled so i don&#039;t need to enable it in some way, but i didn&#039;t understand very weel how often it run; if i&#039;m not wrong, i read it runs every 128 DELETE queryes and i can change this value with the innodb_purge_rseg_truncate_frequency parameter (for example if i want it runs more frequently).<br />
Can you confirm me if i understood correcly the documentation?<br />
Unfortunalty i worked for a long time with PostgreSQL and here there is the VACUUM process, i have a few experience with MySQL, i am learning day by day.<br />
Thanks a lot in advance<br />
Christian]]></description>
            <dc:creator>Christian Marinelli</dc:creator>
            <category>InnoDB</category>
            <pubDate>Thu, 16 May 2024 13:45:47 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724037,724037#msg-724037</guid>
            <title>Why is this deadlock happening? (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,724037,724037#msg-724037</link>
            <description><![CDATA[ I see that one microsservice is causing this deadlock bellow but couldn&#039;t find the root cause. I wouldn&#039;t expect this to happen sice 2 different threads are executing a replace command for 2 different keys on the table. Any idea?<br />
<br />
Table DDL<br />
<br />
CREATE TABLE faturamento (<br />
  DT_FATURA date NOT NULL COMMENT &#039;Data da fatura&#039;,<br />
  COD_GRUPO_FATURA varchar(500) NOT NULL<br />
  JSON_CFG_COBRANCA json NOT NULL<br />
  VL_BRUTO decimal(32,16) NOT NULL <br />
  VL_DESCONTO decimal(32,16) DEFAULT NULL<br />
  VL_LIQUIDO decimal(32,16) NOT NULL <br />
  JSON_APURACOES json NOT NULL <br />
  DESCONTOS_APLICADOS json NOT NULL<br />
  PRIMARY KEY (DT_FATURA,COD_GRUPO_FATURA)<br />
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;<br />
Database output (table was empty)<br />
<br />
2024-05-03 19:26:03 367417139072<br />
*** (1) TRANSACTION:<br />
TRANSACTION 8020, ACTIVE 0 sec inserting<br />
mysql tables in use 1, locked 1<br />
LOCK WAIT 3 lock struct(s), heap size 1128, 2 row lock(s)<br />
MySQL thread id 1172, OS thread handle 370219057024, query id 47288 172.19.0.9 root update<br />
replace into faturamento ( <br />
DT_FATURA, <br />
COD_GRUPO_FATURA, <br />
JSON_CFG_COBRANCA, <br />
VL_BRUTO, <br />
VL_DESCONTO, <br />
VL_LIQUIDO, <br />
DESCONTOS_APLICADOS,JSON_APURACOES) <br />
values (&#039;2030-02-01&#039;, &#039;B&#039;, &#039;{\n  &quot;cobrancaItens&quot; : [ {\n    &quot;metodo&quot; : &quot;DELEGATE&quot;,\n    &quot;configuracao&quot; : &quot;{\\&quot;delegateConfig\\&quot;:{\\&quot;autoConfirmada\\&quot;:true,\\&quot;queue\\&quot;:\\&quot;delegate.queue\\&quot;}}&quot;\n  } ],\n  &quot;configRetentativas&quot; : [ {\n    &quot;metodo&quot; : &quot;DELEGATE&quot;,\n    &quot;totalRetentativas&quot; : 1,\n    &quot;contadorRetentativas&quot; : null,\n    &quot;frequencia&quot; : &quot;DIARIA&quot;,\n    &quot;dia&quot; : 0\n  } ]\n}&#039;, 102.90, 0.00, 102.90, &#039;[ ]&#039;, &#039;[ {\n  &quot;dtMovimento&quot; : &quot;2030-02-01&quot;,\n  &quot;idItemApurado&quot; : &quot;c6bf5dff-9c88-4952-98d5-a43df68a20b3&quot;,\n  &quot;idCicloApuracao&quot; : &quot;2030-01-01-1-2030&quot;,\n  &quot;frequencia&quot; : &quot;DIARIA&quot;,\n  &quot;vlPrecoApuracaoRef&quot; : 102.90,\n  &quot;tpValorApuracao&quot; : &quot;TARIFA&quot;,\n  &quot;qtdCumulativaApuracaoCiclo&quot; : 31,\n  &quot;vlSaldoAcumulado&quot; : 102.9000000000000000,\n  &quot;cfgUltimaApuracao&quot; : {\n    &quot;modelo&quot; : &quot;FIXO&quot;,\n    &quot;frequencia&quot; : &quot;DIARIA&quot;,\n    &quot;dia&quot; : 1,\n    &quot;condicao&quot; : null\n  },\n  &quot;jsonItemApurado&quot; : &quot;{\\n  \\&quot;id\\&quot; : \\&quot;c6bf5dff-9c88-4952-98d5-a43df68a20b3\\&quot;,\\n  \\&quot;codContratante\\&quot; : 9000001,\\n  \\&quot;codContratada\\&quot; : 1000006,\\n  \\&quot;dtInicioVigencia\\&quot; : \\&quot;2999-01-01\\&quot;,\\n  \\&quot;dtFimVigencia\\&quot; : \\&quot;2024-01-01\\&quot;,\\n  \\&quot;infoAdicionalContratante\\&quot; : \\&quot;{\\\\\\&quot;mcc\\\\\\&quot;: \\\\\\&quot;105\\\\\\&quot;, \\\\\\&quot;cnae\\\\\\&quot;: 3350707, \\\\\\&quot;cnpj\\\\\\&quot;: \\\\\\&quot;12.22.184/0001-04\\\\\\&quot;}\\&quot;,\\n  \\&quot;infoAdicionalContratada\\&quot; : \\&quot;{}\\&quot;,\\n  \\&quot;cfgPrecificacao\\&quot; : {\\n    \\&quot;insumo\\&quot; : null,\\n    \\&quot;refContrato\\&quot; : null,\\n    \\&quot;faixas\\&quot; : null,\\n    \\&quot;fixo\\&quot; : {\\n      \\&quot;tipo\\&quot; : \\&quot;TARIFA\\&quot;,\\n      \\&quot;valor\\&quot; : 102.9\\n    }\\n  },\\n  \\&quot;cfgApuracao\\&quot; : {\\n    \\&quot;modelo\\&quot; : \\&quot;FIXO\\&quot;,\\n    \\&quot;frequencia\\&quot; : \\&quot;DIARIA\\&quot;,\\n    \\&quot;dia\\&quot; : 1,\\n    \\&quot;condicao\\&quot; : null\\n  },\\n  \\&quot;cfgDesconto\\&quot; : null,\\n  \\&quot;cfgFaturamento\\&quot; : {\\n    \\&quot;frequencia\\&quot; : \\&quot;MENSAL\\&quot;,\\n    \\&quot;dia\\&quot; : 1,\\n    \\&quot;codAgrupamentoFatura\\&quot; : \\&quot;B\\&quot;,\\n    \\&quot;diasFaturamento\\&quot; : 0\\n  },\\n  \\&quot;cfgCobranca\\&quot; : {\\n    \\&quot;cobrancaItens\\&quot; : [ {\\n      \\&quot;metodo\\&quot; : \\&quot;DELEGATE\\&quot;,\\n      \\&quot;configuracao\\&quot; : \\&quot;{\\\\\\&quot;delegateConfig\\\\\\&quot;:{\\\\\\&quot;autoConfirmada\\\\\\&quot;:true,\\\\\\&quot;queue\\\\\\&quot;:\\\\\\&quot;delegate.queue\\\\\\&quot;}}\\&quot;\\n    } ],\\n    \\&quot;configRetentativas\\&quot; : [ {\\n      \\&quot;metodo\\&quot; : \\&quot;DELEGATE\\&quot;,\\n      \\&quot;totalRetentativas\\&quot; : 1,\\n      \\&quot;frequencia\\&quot; : \\&quot;DIARIA\\&quot;,\\n      \\&quot;dia\\&quot; : 0\\n    } ]\\n  },\\n  \\&quot;cdStatus\\&quot; : \\&quot;ATIVO\\&quot;\\n}&quot;,\n  &quot;dtCriacaoRegistro&quot; : &quot;2024-04-29T19:01:52-03:00&quot;,\n  &quot;dtUltimaAtualiacao&quot; : &quot;2024-05-03T13:23:52-03:00&quot;,\n  &quot;tpValorDesconto&quot; : null\n} ]&#039; )<br />
<br />
*** (1) HOLDS THE LOCK(S):<br />
RECORD LOCKS space id 18 page no 4 n bits 72 index PRIMARY of table `apurador`.`faturamento` trx id 8020 lock_mode X<br />
Record lock, heap no 1 PHYSICAL RECORD: n_fields 1; compact format; info bits 0<br />
 0: len 8; hex 73757072656d756d; asc supremum;;<br />
<br />
<br />
*** (1) WAITING FOR THIS LOCK TO BE GRANTED:<br />
RECORD LOCKS space id 18 page no 4 n bits 72 index PRIMARY of table `apurador`.`faturamento` trx id 8020 lock_mode X insert intention waiting<br />
Record lock, heap no 1 PHYSICAL RECORD: n_fields 1; compact format; info bits 0<br />
 0: len 8; hex 73757072656d756d; asc supremum;;<br />
<br />
<br />
*** (2) TRANSACTION:<br />
TRANSACTION 8022, ACTIVE 0 sec inserting<br />
mysql tables in use 1, locked 1<br />
LOCK WAIT 3 lock struct(s), heap size 1128, 2 row lock(s)<br />
MySQL thread id 1193, OS thread handle 372167667584, query id 47290 172.19.0.9 root update<br />
replace into faturamento ( <br />
DT_FATURA, <br />
COD_GRUPO_FATURA, <br />
JSON_CFG_COBRANCA, <br />
VL_BRUTO, <br />
VL_DESCONTO, <br />
VL_LIQUIDO, <br />
DESCONTOS_APLICADOS,JSON_APURACOES) <br />
values (&#039;2030-02-01&#039;, &#039;A&#039;, &#039;{\n  &quot;cobrancaItens&quot; : [ {\n    &quot;metodo&quot; : &quot;DELEGATE&quot;,\n    &quot;configuracao&quot; : &quot;{\\&quot;delegateConfig\\&quot;:{\\&quot;autoConfirmada\\&quot;:true,\\&quot;queue\\&quot;:\\&quot;delegate.queue\\&quot;}}&quot;\n  } ],\n  &quot;configRetentativas&quot; : [ {\n    &quot;metodo&quot; : &quot;DELEGATE&quot;,\n    &quot;totalRetentativas&quot; : 1,\n    &quot;contadorRetentativas&quot; : null,\n    &quot;frequencia&quot; : &quot;DIARIA&quot;,\n    &quot;dia&quot; : 0\n  } ]\n}&#039;, 89.90, 0.00, 89.90, &#039;[ ]&#039;, &#039;[ {\n  &quot;dtMovimento&quot; : &quot;2030-02-01&quot;,\n  &quot;idItemApurado&quot; : &quot;7b3107c0-930e-4e6f-9090-54cf73ac5b05&quot;,\n  &quot;idCicloApuracao&quot; : &quot;2030-01-01-1-2030&quot;,\n  &quot;frequencia&quot; : &quot;DIARIA&quot;,\n  &quot;vlPrecoApuracaoRef&quot; : 89.90,\n  &quot;tpValorApuracao&quot; : &quot;TARIFA&quot;,\n  &quot;qtdCumulativaApuracaoCiclo&quot; : 30,\n  &quot;vlSaldoAcumulado&quot; : 89.9000000000000000,\n  &quot;cfgUltimaApuracao&quot; : {\n    &quot;modelo&quot; : &quot;FIXO&quot;,\n    &quot;frequencia&quot; : &quot;DIARIA&quot;,\n    &quot;dia&quot; : 1,\n    &quot;condicao&quot; : null\n  },\n  &quot;jsonItemApurado&quot; : &quot;{\\n  \\&quot;id\\&quot; : \\&quot;7b3107c0-930e-4e6f-9090-54cf73ac5b05\\&quot;,\\n  \\&quot;codContratante\\&quot; : 9000001,\\n  \\&quot;codContratada\\&quot; : 7000005,\\n  \\&quot;dtInicioVigencia\\&quot; : \\&quot;2999-01-01\\&quot;,\\n  \\&quot;dtFimVigencia\\&quot; : \\&quot;2024-01-01\\&quot;,\\n  \\&quot;infoAdicionalContratante\\&quot; : \\&quot;{\\\\\\&quot;mcc\\\\\\&quot;: \\\\\\&quot;998\\\\\\&quot;, \\\\\\&quot;cnae\\\\\\&quot;: 3250709, \\\\\\&quot;cnpj\\\\\\&quot;: \\\\\\&quot;11.156.184/0001-08\\\\\\&quot;}\\&quot;,\\n  \\&quot;infoAdicionalContratada\\&quot; : \\&quot;{}\\&quot;,\\n  \\&quot;cfgPrecificacao\\&quot; : {\\n    \\&quot;insumo\\&quot; : null,\\n    \\&quot;refContrato\\&quot; : null,\\n    \\&quot;faixas\\&quot; : null,\\n    \\&quot;fixo\\&quot; : {\\n      \\&quot;tipo\\&quot; : \\&quot;TARIFA\\&quot;,\\n      \\&quot;valor\\&quot; : 89.9\\n    }\\n  },\\n  \\&quot;cfgApuracao\\&quot; : {\\n    \\&quot;modelo\\&quot; : \\&quot;FIXO\\&quot;,\\n    \\&quot;frequencia\\&quot; : \\&quot;DIARIA\\&quot;,\\n    \\&quot;dia\\&quot; : 1,\\n    \\&quot;condicao\\&quot; : null\\n  },\\n  \\&quot;cfgDesconto\\&quot; : null,\\n  \\&quot;cfgFaturamento\\&quot; : {\\n    \\&quot;frequencia\\&quot; : \\&quot;MENSAL\\&quot;,\\n    \\&quot;dia\\&quot; : 1,\\n    \\&quot;codAgrupamentoFatura\\&quot; : \\&quot;A\\&quot;,\\n    \\&quot;diasFaturamento\\&quot; : 0\\n  },\\n  \\&quot;cfgCobranca\\&quot; : {\\n    \\&quot;cobrancaItens\\&quot; : [ {\\n      \\&quot;metodo\\&quot; : \\&quot;DELEGATE\\&quot;,\\n      \\&quot;configuracao\\&quot; : \\&quot;{\\\\\\&quot;delegateConfig\\\\\\&quot;:{\\\\\\&quot;autoConfirmada\\\\\\&quot;:true,\\\\\\&quot;queue\\\\\\&quot;:\\\\\\&quot;delegate.queue\\\\\\&quot;}}\\&quot;\\n    } ],\\n    \\&quot;configRetentativas\\&quot; : [ {\\n      \\&quot;metodo\\&quot; : \\&quot;DELEGATE\\&quot;,\\n      \\&quot;totalRetentativas\\&quot; : 1,\\n      \\&quot;frequencia\\&quot; : \\&quot;DIARIA\\&quot;,\\n      \\&quot;dia\\&quot; : 0\\n    } ]\\n  },\\n  \\&quot;cdStatus\\&quot; : \\&quot;ATIVO\\&quot;\\n}&quot;,\n  &quot;dtCriacaoRegistro&quot; : &quot;2024-04-29T22:22:50-03:00&quot;,\n  &quot;dtUltimaAtualiacao&quot; : &quot;2024-05-03T13:23:52-03:00&quot;,\n  &quot;tpValorDesconto&quot; : null\n} ]&#039; )<br />
<br />
*** (2) HOLDS THE LOCK(S):<br />
RECORD LOCKS space id 18 page no 4 n bits 72 index PRIMARY of table `apurador`.`faturamento` trx id 8022 lock_mode X<br />
Record lock, heap no 1 PHYSICAL RECORD: n_fields 1; compact format; info bits 0<br />
 0: len 8; hex 73757072656d756d; asc supremum;;<br />
<br />
<br />
*** (2) WAITING FOR THIS LOCK TO BE GRANTED:<br />
RECORD LOCKS space id 18 page no 4 n bits 72 index PRIMARY of table `apurador`.`faturamento` trx id 8022 lock_mode X insert intention waiting<br />
Record lock, heap no 1 PHYSICAL RECORD: n_fields 1; compact format; info bits 0<br />
 0: len 8; hex 73757072656d756d; asc supremum;;<br />
<br />
*** WE ROLL BACK TRANSACTION (2)<br />
I tried to analyze de db logs but couldn&#039;t understand why a replace command in two different table keys caused a deadlock.<br />
<br />
I was able to reproduce the problem using 2 mysql clients. Steps:<br />
<br />
execute begin transaction on both clients<br />
execute query on both clients using different values for parameter COD_GRUPO_FATURA: SELECT DT_FATURA, COD_GRUPO_FATURA, JSON_CFG_COBRANCA, VL_BRUTO, VL_DESCONTO, VL_LIQUIDO, DESCONTOS_APLICADOS,JSON_APURACOES from faturamento where DT_FATURA = ? and COD_GRUPO_FATURA = ? FOR UPDATE<br />
execute query on both clients using same parameters from step 2: replace into faturamento ( DT_FATURA, COD_GRUPO_FATURA, JSON_CFG_COBRANCA, VL_BRUTO, VL_DESCONTO, VL_LIQUIDO, DESCONTOS_APLICADOS,JSON_APURACOES)<br />
question is: aren&#039;t both commands using row lock? why the deadlock?]]></description>
            <dc:creator>Vinicius Faleiro</dc:creator>
            <category>InnoDB</category>
            <pubDate>Sat, 04 May 2024 13:58:32 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,724024,724024#msg-724024</guid>
            <title>MySQL 8.4 LTS – new production-ready defaults for InnoDB (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,724024,724024#msg-724024</link>
            <description><![CDATA[ <a href="https://lefred.be/content/mysql-8-4-lts-new-production-ready-defaults-for-innodb/"  rel="nofollow">https://lefred.be/content/mysql-8-4-lts-new-production-ready-defaults-for-innodb/</a>]]></description>
            <dc:creator>Edwin Desouza</dc:creator>
            <category>InnoDB</category>
            <pubDate>Fri, 03 May 2024 18:17:02 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,723880,723880#msg-723880</guid>
            <title>MySQL 8.0.35 crashes during startup (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,723880,723880#msg-723880</link>
            <description><![CDATA[ We are facing problem where MySQL service crashes with below error. ‘binlog_transaction_compression’ is also turned off in our setup. We are able to force recovery. Can someone tell us the reason for crash? The OS has enough disk space.<br />
<br />
<br />
2024-04-25T05:36:23Z UTC - mysqld got exception 0x16 ;<br />
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.<br />
Thread pointer: 0x1c1a641a9f0<br />
Attempting backtrace. You can use the following information to find out<br />
where mysqld died. If you see no messages after this, something went<br />
terribly wrong...<br />
7ff750dec388    mysqld.exe!?my_print_stacktrace@@YAXPEBEK@Z()<br />
7ff74ff5f461    mysqld.exe!?print_fatal_signal@@YAXH@Z()<br />
7ff74ff5f1a3    mysqld.exe!?my_server_abort@@YAXXZ()<br />
7ff750dd09aa    mysqld.exe!?my_abort@@YAXXZ()<br />
7ff750fa1359    mysqld.exe!?do_reset@Zstd_dec@compression@transaction@binary_log@@EEAAXXZ()<br />
7ff750efc9cb    mysqld.exe!?do_reset@Zstd_dec@compression@transaction@binary_log@@EEAAXXZ()<br />
<br />
<br />
Can you please help us in posting this reply in below MySQL Forum link.<br />
<a href="https://forums.mysql.com/read.php?22,705028,705028"  rel="nofollow">https://forums.mysql.com/read.php?22,705028,705028</a>]]></description>
            <dc:creator>Praveen Kumar B A</dc:creator>
            <category>InnoDB</category>
            <pubDate>Thu, 25 Apr 2024 11:05:19 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,723879,723879#msg-723879</guid>
            <title>MySQL 8.0.35 crashes (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,723879,723879#msg-723879</link>
            <description><![CDATA[ Hi All <br />
<br />
The application is performing a read query but the database is crashing and not recovering.  The force_innodb_recovery flag has to be set to 2 inorder to recover. The operating system has enough disk space. Here is the stack trace for the crash. Is there a way to identify the root cause for this crash? <br />
<br />
2024-02-20T15:44:17.070850+01:00 3021 [Warning] [MY-012638] [InnoDB] Retry attempts for writing partial data failed.<br />
2024-02-20T15:44:17.072376+01:00 3021 [ERROR] [MY-012639] [InnoDB] Write to file .\#innodb_temp\temp_9.ibt failed at offset 3423600640, 1048576 bytes should have been written, only 0 were written. Operating system error number 33. Check that your OS and file system support files of this size. Check also that the disk is not full or a disk quota exceeded.<br />
2024-02-20T15:44:17.074315+01:00 3021 [ERROR] [MY-012640] [InnoDB] Error number 33 means &#039;Domain error&#039;<br />
2024-02-20T15:44:17.075637+01:00 3021 [Warning] [MY-012145] [InnoDB] Error while writing 4194304 zeroes to .\#innodb_temp\temp_9.ibt starting at offset 3422552064<br />
2024-02-20T15:44:17.076548+01:00 3021 [ERROR] [MY-013132] [Server] The table &#039;C:\Windows\SERVIC~1\NETWOR~1\AppData\Local\Temp\#sql100c_bcd_38&#039; is full!<br />
2024-02-20T15:44:17.124983+01:00 3022 [Warning] [MY-012638] [InnoDB] Retry attempts for writing partial data failed.<br />
2024-02-20T15:44:17.125847+01:00 3022 [Warning] [MY-012145] [InnoDB] Error while writing 4194304 zeroes to .\#innodb_temp\temp_8.ibt starting at offset 801112064<br />
2024-02-20T15:44:17.126754+01:00 3022 [ERROR] [MY-013132] [Server] The table &#039;C:\Windows\SERVIC~1\NETWOR~1\AppData\Local\Temp\#sql100c_bce_38&#039; is full!<br />
2024-02-20T15:44:21.229098+01:00 3017 [ERROR] [MY-000035] [Server] Disk is full writing &#039;.\redacted-bin.000021&#039; (OS errno 28 - No space left on device). Waiting for someone to free space... Retry in 60 secs. Message reprinted in 600 secs.<br />
2024-02-20T15:44:51.256533+01:00 3028 [Warning] [MY-013360] [Server] Plugin mysql_native_password reported: &#039;&#039;mysql_native_password&#039; is deprecated and will be removed in a future release. Please use caching_sha2_password instead&#039;<br />
2024-02-20T15:44:51.585328+01:00 3017 [ERROR] [MY-010907] [Server] Error writing file &#039;redacted-bin&#039; (errno: 28 - No space left on device)<br />
2024-02-20T15:44:51.586284+01:00 3017 [ERROR] [MY-011072] [Server] Binary logging not possible. Message: An error occurred during flush stage of the commit. &#039;binlog_error_action&#039; is set to &#039;ABORT_SERVER&#039;. Server is being stopped..<br />
2024-02-20T14:44:51Z UTC - mysqld got exception 0x16 ;<br />
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.<br />
Thread pointer: 0x27152f3f0d0<br />
Attempting backtrace. You can use the following information to find out<br />
where mysqld died. If you see no messages after this, something went<br />
terribly wrong...<br />
7ff75f53c388    mysqld.exe!?my_print_stacktrace@@YAXPEBEK@Z()<br />
7ff75e6af461    mysqld.exe!?print_fatal_signal@@YAXH@Z()<br />
7ff75e6af1a3    mysqld.exe!?my_server_abort@@YAXXZ()<br />
7ff75f5209aa    mysqld.exe!?my_abort@@YAXXZ()<br />
7ff75f2dc95c    mysqld.exe!?ending_trans@@YA_NPEAVTHD@@_N@Z()<br />
7ff75f2df285    mysqld.exe!?handle_binlog_flush_or_sync_error@MYSQL_BIN_LOG@@AEAAXPEAVTHD@@_NPEBD@Z()<br />
7ff75f2e522d    mysqld.exe!?ordered_commit@MYSQL_BIN_LOG@@AEAAHPEAVTHD@@_N1@Z()<br />
7ff75f2daba1    mysqld.exe!?commit@MYSQL_BIN_LOG@@UEAA?AW4enum_result@TC_LOG@@PEAVTHD@@_N@Z()<br />
7ff75e475092    mysqld.exe!?ha_commit_trans@@YAHPEAVTHD@@_N1@Z()<br />
7ff75e6a4b06    mysqld.exe!?trans_commit@@YA_NPEAVTHD@@_N@Z()<br />
7ff75e66740f    mysqld.exe!?mysql_execute_command@@YAHPEAVTHD@@_N@Z()<br />
7ff75e6629bf    mysqld.exe!?dispatch_sql_command@@YAXPEAVTHD@@PEAVParser_state@@@Z()<br />
7ff75e6615ba    mysqld.exe!?dispatch_command@@YA_NPEAVTHD@@PEBTCOM_DATA@@W4enum_server_command@@@Z()<br />
7ff75e662d76    mysqld.exe!?do_command@@YA_NPEAVTHD@@@Z()<br />
7ff75e469bf8    mysqld.exe!?thread_id@THD@@QEBAIXZ()<br />
7ff75fabf189    mysqld.exe!?my_init_dynamic_array@@YA_NPEAUDYNAMIC_ARRAY@@IIPEAXII@Z()<br />
7ff75f52cb7c    mysqld.exe!?my_thread_self_setname@@YAXPEBD@Z()<br />
7ffc77cc6b4c    ucrtbase.dll!_recalloc()<br />
7ffc79344cb0    KERNEL32.DLL!BaseThreadInitThunk()<br />
7ffc7a2ce8ab    ntdll.dll!RtlUserThreadStart()<br />
<br />
Trying to get some variables.<br />
Some pointers may be invalid and cause the dump to abort.<br />
Query (27189bb00f0): COMMIT<br />
Connection ID (thread ID): 3017<br />
Status: KILL_CONNECTION]]></description>
            <dc:creator>Praveen Kumar B A</dc:creator>
            <category>InnoDB</category>
            <pubDate>Thu, 25 Apr 2024 11:00:49 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,723868,723868#msg-723868</guid>
            <title>Incorrect string value (1 reply)</title>
            <link>https://forums.mysql.com/read.php?22,723868,723868#msg-723868</link>
            <description><![CDATA[ I have a table in an InnoDB database.<br />
<br />
The character set is utf8mb4 and the collation is utf8mb4_0900_ai_ci. I have a field in the table defined as longtext, whose collation is also utf8mb4_0900_ai_ci.<br />
<br />
When I copy the following content:<br />
<br />
Man they are on it this week😊<br />
<br />
<br />
<br />
<br />
Into this field, I get the following warnings:<br />
<br />
1300 - Invalid utf8mb3 character string: &#039;F09F98&#039;<br />
1366 - Incorrect string value: &#039;\xF0\x9F\x98\x8A&#039; for column &#039;Action&#039; at row 1<br />
<br />
<br />
<br />
What do I need to do to fix this?]]></description>
            <dc:creator>Gina-Marie Rollock</dc:creator>
            <category>InnoDB</category>
            <pubDate>Mon, 29 Apr 2024 19:31:44 +0000</pubDate>
        </item>
        <item>
            <guid>https://forums.mysql.com/read.php?22,723848,723848#msg-723848</guid>
            <title>MySQL restarts - mysqld got signal 11 ; (no replies)</title>
            <link>https://forums.mysql.com/read.php?22,723848,723848#msg-723848</link>
            <description><![CDATA[ We host a web app using MySQL on AWS RDS. We recently upgraded to MySQL8 (8.0.28) and since then we are seeing the server restart itself approximately every 5-7 days with the following error. <br />
<br />
========<br />
2024-04-22T14:28:25Z mysqld got signal 11 ; ;<br />
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.<br />
Thread pointer: 0x152666551800<br />
Attempting backtrace. You can use the following information to find out<br />
where mysqld died. If you see no messages after this, something went<br />
terribly wrong...<br />
2024-04-22T14:28:25.081395Z 47526151 [Warning] [MY-013360] [Server] Plugin mysql_native_password reported: &#039;&#039;mysql_native_password&#039; is deprecated and will be removed in a future release. Please use caching_sha2_password instead&#039;<br />
2024-04-22T14:28:25.087136Z 47526152 [Warning] [MY-013360] [Server] Plugin mysql_native_password reported: &#039;&#039;mysql_native_password&#039; is deprecated and will be removed in a future release. Please use caching_sha2_password instead&#039;<br />
2024-04-22T14:28:25.111052Z 47526153 [Warning] [MY-013360] [Server] Plugin mysql_native_password reported: &#039;&#039;mysql_native_password&#039; is deprecated and will be removed in a future release. Please use caching_sha2_password instead&#039;<br />
2024-04-22T14:28:25.122618Z 47526154 [Warning] [MY-013360] [Server] Plugin mysql_native_password reported: &#039;&#039;mysql_native_password&#039; is deprecated and will be removed in a future release. Please use caching_sha2_password instead&#039;<br />
stack_bottom = 1525b9a4b210 thread_stack 0x40000<br />
2024-04-22T14:28:25.141865Z 47526155 [Warning] [MY-013360] [Server] Plugin mysql_native_password reported: &#039;&#039;mysql_native_password&#039; is deprecated and will be removed in a future release. Please use caching_sha2_password instead&#039;<br />
/rdsdbbin/mysql/bin/mysqld(my_print_stacktrace(unsigned char const*, unsigned long)+0x2e) [0x151bd7e]<br />
/rdsdbbin/mysql/bin/mysqld(print_fatal_signal(int)+0x276) [0xc179e6]<br />
/rdsdbbin/mysql/bin/mysqld(handle_fatal_signal+0x7c) [0xc17c7c]<br />
/lib64/libpthread.so.0(+0x118e0) [0x1533428648e0]<br />
/rdsdbbin/mysql/bin/mysqld(has_external_table(Table_ref*)+0x32) [0xb2a512]<br />
/rdsdbbin/mysql/bin/mysqld(Sql_cmd_dml::execute(THD*)+0x66b) [0xb3246b]<br />
/rdsdbbin/mysql/bin/mysqld(mysql_execute_command(THD*, bool)+0x938) [0xaf39f8]<br />
/rdsdbbin/mysql/bin/mysqld(dispatch_sql_command(THD*, Parser_state*)+0x587) [0xaf74f7]<br />
/rdsdbbin/mysql/bin/mysqld(dispatch_command(THD*, COM_DATA const*, enum_server_command)+0x19df) [0xaf95ef]<br />
/rdsdbbin/mysql/bin/mysqld(do_command(THD*)+0x1c9) [0xafa059]<br />
/rdsdbbin/mysql/bin/mysqld() [0xc18b8f]<br />
/rdsdbbin/mysql/bin/mysqld() [0x18cedbf]<br />
/lib64/libpthread.so.0(+0x744b) [0x15334285a44b]<br />
/lib64/libc.so.6(clone+0x3f) [0x15334203f52f]<br />
<br />
Trying to get some variables.<br />
Some pointers may be invalid and cause the dump to abort.<br />
====<br />
<br />
It is always the same query in the error log(but on different databases) which is causing the error, however, when we run the query manually, it is fine. It feels like it is only in certain circumstances, e.g. hitting some kind of memory limit and causing it to fall over? I have read this could be an OS problem causing the OS to run out of memory and kill MySQL. <br />
<br />
Can anyone advise? Should we start by reducing the amount of memory MySQL is trying to use, and if so, how best to do that?]]></description>
            <dc:creator>Mark Phillips</dc:creator>
            <category>InnoDB</category>
            <pubDate>Tue, 23 Apr 2024 09:12:10 +0000</pubDate>
        </item>
    </channel>
</rss>
