Derek Coleman & Associates Inc logoDerek Coleman & Associates Inc

Home / Docs / MySQL Community Server (Hardened) / Configuration

Configure MySQL Community Server (Hardened)

Configuration files

AWS: /etc/my.cnf and /etc/my.cnf.d/zz-hardening.cnf (bind-address 127.0.0.1; mysqlx off/loopback; auth_socket plugin loaded — duplicated in both files deliberately). GCE: /etc/mysql/mysql.conf.d/zz-hardening.cnf (same bind/mysqlx keys) over the Ubuntu defaults in /etc/mysql/.

Credential rotation

Not applicable to root (socket auth). For app users you create: ALTER USER ... IDENTIFIED BY with your own secret.

Monitoring & logging

Upgrades

Prefer replacing the instance with the newest image version (monthly + event-driven CVE rebuilds). In place: `sudo dnf update mysql-community-server` (AWS) or `sudo apt upgrade mysql-server` (GCE) between refreshes. Major-version upgrades follow MySQL's documented path — take a backup first.

Backup & restore

mysqldump --all-databases via `sudo mysql`, or stop mysqld and snapshot the volume. Restore: standard mysql import into a fresh instance.