mariadb2tidb 
A command-line tool that converts MariaDB schemas into TiDB-compatible SQL.
Features
- Schema transformation to TiDB dialect
- Database extraction from multi-DB dumps
- Parallel import to TiDB
- Validation and diff generation
Installation
Requires Go 1.24+.
Quick install (latest):
go install github.com/developer-Bushido/mariadb2tidb/cmd/mariadb2tidb@latest
From source:
git clone https://github.com/developer-Bushido/mariadb2tidb.git
cd mariadb2tidb
make build
./bin/mariadb2tidb version
Usage
Transform a MariaDB schema:
mariadb2tidb transform schema.sql -o schema_tidb.sql
You can also define default input and output directories in a YAML config file:
input_dir: ./DUMPLING
output_dir: ./LIGHTNING
Run commands with --config to read these paths.
See mariadb2tidb --help for all commands.
Configuration file
Minimal config/default.yaml example:
input_dir: ./DUMPLING
output_dir: ./LIGHTNING
enabled_rules: []
disabled_rules: []
strict_mode: true
Documentation
Contributing
Contributions are welcome! Please see CONTRIBUTING.md for guidelines.
Development
License
mariadb2tidb is licensed under the Apache 2.0 license.
Code of Conduct
This project follows a Code of Conduct. Please read it to understand the expected behavior.
Security
If you discover a security vulnerability, please follow our Security Policy and report it privately via GitHub Security Advisories.