Go-Powered Engine

Database Ops,
Democratized.

The cross-database migration tool that treats your data like gold. Backup, encrypt, and restore MySQL, PostgreSQL, and MongoDB with a single binary.

Launch Interactive Mode
MySQL Postgres Mongo
user@server: ~/dbmigrate
~ ./dbmigrate interactive
Portal DB Migration Tool v1.0.0
Select an operation to perform:
1) Init/Add source server
2) Backup all databases
3) List backups
4) Restore to target
5) Push (Sync)
6) Exit
Choose option [1-6]:

The Migration Pipeline

Built on a modular Engine interface. Native tools for reliability, Go for orchestration.

01

Connect

Securely connects to Source using encrypted credentials stored in OS Keyring.

02

Dump & Tag

Triggers native dumps (pg_dump, mysqldump). Generates JSON metadata with checksums.

03

Encrypt & Store

Compresses to .gz and optionally encrypts via AES-256-GCM before writing to disk.

04

Restore / Push

Validates checksums and pushes data to the Target server with transaction safety.

Enterprise Grade Features

Military-Grade Encryption

Credentials are never stored in plain text. We utilize the native OS Keyring (macOS Keychain, Windows Credential Manager) for access, and AES-256-GCM for backup file encryption at rest.

AES-256 SHA-256 Checksums

Smart Metadata

Every backup is accompanied by a strictly typed JSON manifest containing engine version, size, timestamps, and origin.

{
  "id": "mysql_src_2025...",
  "checksum": "sha256:e3b0...",
  "engine": "mysql"
}

Structured Storage

Files are organized automatically by engine and timestamp. No more messy root directories.

  • backups/mysql/
  • backups/postgres/
  • backups/mongo/

Interactive Numbered CLI

Forget remembering complex flags. Just run `dbmigrate interactive` and use single keystrokes (1-9) to navigate menus. Built with Go's `term` package for raw input handling.

Choose an option:
1) Init Source
2) Backup DB
> _

Power User Controls

Automate via CI/CD or Cron using standard flags.

./dbmigrate init Copy

Prompts for Host, Port, User, Pass. Encrypts and saves to ~/.dbmigrate.json.

./dbmigrate backup --source mysql-prod --db users_db Copy

Fetches only the specified database. Use --all for full server dump.

./dbmigrate restore --backup ./backups/file.sql.gz --target local-dev

Unzips, verifies checksum, and pipes output to target database engine.

./dbmigrate list --json

Lists all local backups with their ID, Size, and Creation Timestamp.