GoAdmio
GoAdmio Documentation

Repair MySQL Database

From the GoAdmio knowledge base.

Repair MySQL Database

This page explains the Repair MySQL Database screen in GoAdmio. It lets you check for and fix corrupted MySQL/MariaDB tables directly from the panel, without needing the command line or phpMyAdmin.

Location: Admin Panel → Databases → Repair MySQL Database
Location (User Panel): Databases → Repair MySQL Database



Overview

Database tables can become corrupted for several reasons: a sudden power loss, a server crash, a killed MySQL process, a full disk during a write, or a hardware fault. Corrupted tables often show symptoms like:

  • "Table is marked as crashed and should be repaired"
  • Queries returning errors or incomplete results
  • A website showing database connection errors
  • SELECT queries failing on specific tables
GoAdmio includes a Repair MySQL Database tool that runs MySQL's native REPAIR TABLE and mysqlcheck utilities to detect and fix corruption. The tool is engine-aware: it applies the correct repair method depending on whether a table uses MyISAM or InnoDB.

> Warning: Repairing a database can lead to data loss in severe cases. Always take a snapshot or backup before repairing. See Snapshots and Backup Wizard. If the data is critical, restore from a known-good backup instead of repairing.



What the Page Shows

| Field / Column | Description |
|---|---|
| Database | The database to check or repair |
| Tables | The tables within the database (or "All Tables" for a full repair) |
| Check | Run a check only — report corruption without fixing |
| Repair | Run a repair — attempt to fix corruption |
| Optimize | Run an optimize — rebuild table data and indexes (also useful after repair) |
| Status / Output | The result of the operation, including errors and warnings |

> Tip: Use Check first to see whether a repair is needed. A repair is only necessary if the check reports an error or corruption.



How It Works — Engine Differences

The repair method depends on the table's storage engine:

| Engine | Can REPAIR TABLE fix it? | Recommended method |
|---|---|---|
| MyISAM | ✅ Yes | REPAIR TABLE or mysqlcheck --repair |
| Aria (MariaDB) | ✅ Yes | REPAIR TABLE or mariadb-check --repair |
| InnoDB | ❌ No (in most versions) | InnoDB performs automatic crash recovery on startup. REPAIR TABLE is not supported. |

> Important: REPAIR TABLE and mysqlcheck --auto-repair apply to MyISAM (and Aria/ARCHIVE/CSV) tables. InnoDB tables are not repaired by REPAIR TABLE — InnoDB recovers itself from its redo log on server start. If an InnoDB table is corrupted beyond automatic recovery, the solution is to restore from backup or use innodb_force_recovery (advanced)[reference:0][reference:1][reference:2].

GoAdmio's Repair tool handles this automatically — it will run the correct operation for each table's engine and report any table it cannot repair.



How to Repair a Database

Via the Admin Panel

  1. Log in to the GoAdmio Admin Panel (or User Panel).
  2. Navigate to Databases → Repair MySQL Database.
  3. Select the domain and the database you want to check or repair.
  4. Choose the operation:
- Check — detect corruption (non-destructive) - Repair — attempt to fix corruption - Optimize — rebuild tables and indexes (recommended after a repair)
  1. Choose the scope:
- All Tables — run on the entire database - Specific Table — select one table
  1. Click Run.
  2. Review the Status / Output column for results.
> Tip: Run Check first. If it returns OK, no repair is needed. If it reports corrupt or crashed, proceed with Repair. After a successful repair, run Optimize to rebuild indexes and reclaim space.

Via CLI

GoAdmio provides a /go/repair command for scripted repairs. The exact syntax depends on your version; see Command Reference. The general form is:

```bash
/go/repair <database_name>

↑