Tag

online DDL

0 views collected around this technical thread.

Aikesheng Open Source Community
Aikesheng Open Source Community
Jun 11, 2025 · Databases

Why Does Adding a Column Trigger Duplicate Entry Errors in MySQL?

An experienced DBA explains why adding a new column in MySQL can unexpectedly raise duplicate entry errors during online DDL, detailing the role of primary and unique keys, the innodb_online_alter_log_max_size setting, and how concurrent DML operations cause the conflict.

DDLDatabaseMySQL
0 likes · 8 min read
Why Does Adding a Column Trigger Duplicate Entry Errors in MySQL?
Xiaolei Talks DB
Xiaolei Talks DB
May 16, 2025 · Databases

How Online DDL Impacts TPS/QPS in OceanBase: A Comprehensive Test

This article details a systematic performance test of OceanBase's online DDL capabilities, measuring TPS and QPS impacts across various DDL operations, describing the test environment, scripts, results, and conclusions for reliable database schema changes.

DatabaseOceanBasePerformance Testing
0 likes · 17 min read
How Online DDL Impacts TPS/QPS in OceanBase: A Comprehensive Test
Java Tech Enthusiast
Java Tech Enthusiast
Apr 4, 2025 · Databases

MySQL Large Table Index Optimization and Batch Deletion Strategies

By dropping a low‑selectivity composite index, adding targeted indexes on product_id‑sequence‑station_no and receive_time, and using online DDL with pt‑osc, the team reduced row scans and replication lag, then implemented batch deletions by primary‑key ranges, cutting delete time from minutes to seconds on a 100‑million‑row table.

Index OptimizationLarge TablesMySQL
0 likes · 14 min read
MySQL Large Table Index Optimization and Batch Deletion Strategies
vivo Internet Technology
vivo Internet Technology
Aug 7, 2024 · Databases

MySQL 5.7 DDL vs GH-OST: A Comprehensive Comparison of Online Schema Change Tools

While MySQL 5.7 native DDL methods (copy, inplace rebuild, index build, metadata‑only) vary in speed, space use, lock impact, and binlog output, GH‑OST consistently offers the fastest execution, lowest lock blocking, real‑time replication, albeit at roughly double storage cost, making it ideal for risk‑averse online schema changes.

DDLInnoDBMySQL
0 likes · 11 min read
MySQL 5.7 DDL vs GH-OST: A Comprehensive Comparison of Online Schema Change Tools
Aikesheng Open Source Community
Aikesheng Open Source Community
May 7, 2024 · Databases

Why Expanding a MySQL VARCHAR Column from 63 to 64 Characters Takes Much Longer

The article investigates why altering a MySQL VARCHAR column from a length that fits within 255 bytes to one that exceeds this limit (e.g., VARCHAR(63) to VARCHAR(64) in utf8mb4) triggers a costly copy operation, analyzes the storage mechanics, reproduces the issue, and provides practical recommendations to avoid performance penalties.

Database AdministrationMySQLVARCHAR
0 likes · 13 min read
Why Expanding a MySQL VARCHAR Column from 63 to 64 Characters Takes Much Longer
Aikesheng Open Source Community
Aikesheng Open Source Community
Feb 20, 2024 · Databases

Understanding and Testing Space Requirements for MySQL Online DDL Operations

This article explains the space requirements of MySQL Online DDL operations, analyzes temporary log, sort, and intermediate files, provides step‑by‑step test preparation, demonstrates failure and recovery scenarios, and summarizes best practices for avoiding space‑related errors.

Database AdministrationInnoDBMySQL
0 likes · 9 min read
Understanding and Testing Space Requirements for MySQL Online DDL Operations
Aikesheng Open Source Community
Aikesheng Open Source Community
Jan 30, 2024 · Databases

Troubleshooting VARCHAR Column Expansion Issues with MySQL Online DDL

This article analyzes why ALTER TABLE operations that extend VARCHAR columns sometimes fail in MySQL, explains the underlying Online DDL constraints, presents several real‑world problems such as default‑value handling, indexed columns, and hidden table‑rebuild quirks, and offers practical solutions for each case.

ALTER TABLEDatabase AdministrationMySQL
0 likes · 17 min read
Troubleshooting VARCHAR Column Expansion Issues with MySQL Online DDL
Code Ape Tech Column
Code Ape Tech Column
Jun 12, 2023 · Databases

Understanding MySQL DDL Execution and Online DDL Mechanisms

This article explains the differences between MySQL DDL and DML, describes how online DDL works—including copy and inplace algorithms, execution phases, common pitfalls, limitations, and recent MySQL 8.0 enhancements—providing practical guidance for safely altering large tables.

DDLDatabaseInnoDB
0 likes · 16 min read
Understanding MySQL DDL Execution and Online DDL Mechanisms
Aikesheng Open Source Community
Aikesheng Open Source Community
Apr 18, 2023 · Databases

Schema Change for a 400‑Million‑Row MySQL Table Using Cascade Replication

This article details a step‑by‑step strategy for expanding a VARCHAR column from 50 to 500 characters on a 4‑hundred‑million‑row MySQL 8.0 table, evaluating online DDL, gh‑ost, pt‑osc, and ultimately implementing a cascade replication workflow to meet a four‑hour downtime window.

MySQLcascade replicationgh-ost
0 likes · 10 min read
Schema Change for a 400‑Million‑Row MySQL Table Using Cascade Replication
Aikesheng Open Source Community
Aikesheng Open Source Community
Mar 6, 2023 · Databases

Adding Unique Indexes in MySQL: Methods, Risks, and Hook‑Based Mitigations

This article explains how to add unique indexes to large MySQL tables using Online DDL, pt‑osc, and gh‑ost, compares their advantages and drawbacks, outlines common data‑loss risks, and provides practical hook scripts and best‑practice recommendations to mitigate those risks.

MySQLdatabase migrationgh-ost
0 likes · 20 min read
Adding Unique Indexes in MySQL: Methods, Risks, and Hook‑Based Mitigations
Aikesheng Open Source Community
Aikesheng Open Source Community
Aug 11, 2022 · Databases

Exploring MySQL 8.0.29 Instant ADD/DROP COLUMN Feature and Its Impact on Online DDL

This article demonstrates how MySQL 8.0.29’s ALGORITHM=INSTANT enables instant column addition, deletion, and row‑size checks at any position in large tables, compares performance with previous versions, and discusses related XtraBackup backup considerations.

ALTER TABLEINSTANTMySQL
0 likes · 9 min read
Exploring MySQL 8.0.29 Instant ADD/DROP COLUMN Feature and Its Impact on Online DDL
Aikesheng Open Source Community
Aikesheng Open Source Community
May 26, 2022 · Databases

Resolving Xtrabackup Backup Failures Caused by Non‑Redo Logging DDL Operations in MySQL 5.7

This article analyses why physical backups using Xtrabackup fail when MySQL 5.7 performs online DDL operations that skip redo logging, demonstrates the issue with real‑world logs, and presents four practical solutions—including lock‑DDL parameters, per‑table MDL locks, and disabling online DDL—to ensure consistent backups.

DDLMySQLSorted Index Build
0 likes · 23 min read
Resolving Xtrabackup Backup Failures Caused by Non‑Redo Logging DDL Operations in MySQL 5.7
Top Architect
Top Architect
Dec 5, 2021 · Databases

Why MySQL Table Size Does Not Decrease After DELETE and How to Reduce It

This article explains why deleting rows in MySQL does not shrink the underlying table file, describes the InnoDB storage mechanics that cause this behavior, and provides practical solutions such as OPTIMIZE TABLE, ALTER TABLE, and Online DDL to reclaim space and avoid table‑locking issues.

ALTER TABLEDELETEDatabase
0 likes · 8 min read
Why MySQL Table Size Does Not Decrease After DELETE and How to Reduce It
Top Architect
Top Architect
Nov 17, 2021 · Databases

Why MySQL Table Size Does Not Decrease After DELETE and How to Reduce It

The article explains why MySQL’s DELETE command does not shrink the physical table file, describes InnoDB’s storage mechanics, and shows how to reclaim space using OPTIMIZE TABLE, ALTER TABLE, and Online DDL options.

ALTER TABLEDELETEDatabase Maintenance
0 likes · 7 min read
Why MySQL Table Size Does Not Decrease After DELETE and How to Reduce It
Top Architect
Top Architect
Jul 19, 2021 · Databases

Why MySQL DELETE Does Not Reduce Table File Size and How to Shrink It

The article explains why deleting rows in MySQL does not shrink the physical table file, describes the underlying InnoDB storage mechanisms, and provides practical methods such as OPTIMIZE TABLE, ALTER TABLE, and Online DDL to reclaim space and reorganize the table.

ALTER TABLEDELETEDatabase Maintenance
0 likes · 7 min read
Why MySQL DELETE Does Not Reduce Table File Size and How to Shrink It
Top Architect
Top Architect
Jun 9, 2021 · Databases

Why MySQL DELETE Does Not Reduce Table Size and How to Shrink It

The article explains why deleting rows in MySQL does not shrink the .ibd file because InnoDB only marks pages as reusable, and shows how to reclaim space using OPTIMIZE TABLE, ALTER TABLE, and Online DDL options.

ALTER TABLEDELETEDatabase Maintenance
0 likes · 7 min read
Why MySQL DELETE Does Not Reduce Table Size and How to Shrink It
Laravel Tech Community
Laravel Tech Community
May 13, 2021 · Databases

Why MySQL Table Size Doesn’t Shrink After DELETE and How to Reduce It

This article explains why deleting rows in MySQL does not decrease the physical table file size, describes the underlying InnoDB storage mechanisms, and shows how to reclaim space using OPTIMIZE TABLE, ALTER TABLE, and Online DDL options.

ALTER TABLEDELETEInnoDB
0 likes · 7 min read
Why MySQL Table Size Doesn’t Shrink After DELETE and How to Reduce It
360 Smart Cloud
360 Smart Cloud
Apr 1, 2021 · Databases

Using TiDB Data Migration (DM) for MySQL‑to‑TiDB Sync: Architecture, Features, Tuning and Troubleshooting

This article shares practical experience with TiDB Data Migration (DM), covering its background, architecture, key features, online DDL support, common error handling such as duplicate‑key issues, large‑scale import tuning, configuration limits, and cleanup recommendations for reliable MySQL‑to‑TiDB synchronization.

DMMySQLTiDB
0 likes · 16 min read
Using TiDB Data Migration (DM) for MySQL‑to‑TiDB Sync: Architecture, Features, Tuning and Troubleshooting
Aikesheng Open Source Community
Aikesheng Open Source Community
Dec 8, 2020 · Databases

Understanding MySQL Online DDL for VARCHAR Column Size Changes and In‑Place vs Copy Operations

The article explains how MySQL's Online DDL handles VARCHAR column expansions, demonstrates performance differences across character sets using sysbench, and clarifies why certain size changes trigger in‑place alterations while others require full table copies, providing practical guidance for DBAs.

Database PerformanceInnoDBMySQL
0 likes · 9 min read
Understanding MySQL Online DDL for VARCHAR Column Size Changes and In‑Place vs Copy Operations
360 Tech Engineering
360 Tech Engineering
Dec 4, 2020 · Databases

Practical Experience and Tips with TiDB Data Migration (DM) Tool

This article shares a comprehensive overview of TiDB Data Migration (DM), covering its architecture, configuration, online DDL support, common pitfalls such as duplicate‑key errors, large‑scale import tuning, version limits, and cleanup recommendations to help DBAs efficiently migrate MySQL/MariaDB workloads to TiDB.

DMMySQLReplication
0 likes · 16 min read
Practical Experience and Tips with TiDB Data Migration (DM) Tool