Skip to content
Eren Gaygusuz
Go back

Troubleshooting Local MySQL Startup

This final archived 2016 note addresses a local MySQL service that fails to start and a simple shutdown habit for local development services. It is not a general recovery procedure: identify the cause from the database logs and make a backup before changing configuration.

innodb_force_recovery is an emergency recovery setting. Do not leave it enabled, do not use it for normal operation, and do not perform destructive writes while it is active. If the data matters, stop and make a copy of the data directory before proceeding.

Local MySQL troubleshooting configuration and orderly service shutdown

Table of contents

Open Table of contents

Locating the MySQL Configuration

When the local MySQL service does not start, open the MySQL area in the local-server application and choose its configuration option.

Opening MySQL section in local server application Opening local MySQL configuration

The Archived Recovery Setting

The source adds the following line below the [mysql] section of the configuration file:

innodb_force_recovery = 1
Adding innodb force recovery setting to MySQL configuration

This setting is intended only to help access damaged InnoDB data long enough to diagnose or export it. After the recovery task, remove the line, restore normal configuration, and investigate the underlying failure using the MySQL error log.

Shutting Down Services Cleanly

When local work is complete, stop the running services from the local-server application before closing it. The source calls out MySQL, Apache, FTP, and MongoDB; stop only services you actually use, and wait for each to finish.

Stopping local services before exiting local server application

Summary

Treat recovery configuration as a temporary, last-resort diagnostic measure. Clean shutdowns and regular backups are the safer routine for a local Moodle environment.


Share this post:

Comments


Previous Post
Connecting to an AWS EC2 Instance with WinSCP and PuTTY
Next Post
Streaming to Twitch with OBS for Moodle