Common SQL Errors

MySQL Error 50: EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION - How to Fix and Prevent

Galaxy Team
August 5, 2025

The MySQL option-file parser skipped an !include or !includedir directive because the maximum nesting depth (10) was exceeded.

Sign up for the latest in common SQL errors from the Galaxy Team!
Welcome to the Galaxy, Guardian!
You'll be receiving a confirmation email

Follow us on twitter :)
Oops! Something went wrong while submitting the form.

What is MySQL error 50 EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION?

MySQL Error 50: EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION signals that the server ignored an !include directive after hitting the 10-level include depth limit. Remove circular or deeply nested config includes, or flatten your my.cnf hierarchy, to resolve the issue.

Error Highlights

Typical Error Message

Skipping '%s' directive as maximum include recursion level was reached in file %s at line %d. EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION was added in 8.0.13.

Error Type

Configuration Error

Language

MySQL

Symbol

EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION

Error Code

50

SQL State

Explanation

Table of Contents

What is MySQL error 50 EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION?

Why does this warning appear at startup?

MySQL raises error 50 with condition name EE_SKIPPING_DIRECTIVE_DUE_TO_MAX_INCLUDE_RECURSION when the option-file reader encounters an !include or !includedir directive but has already followed ten nested include levels. To avoid infinite loops, the parser silently skips any further directive and emits this message.

The error is logged during server or client start-up, not during SQL execution.

Beginning with MySQL 8.0.13, the message appears in the error log and on stderr so administrators can detect misconfigured configuration files early.

What does the message look like?

Typical output: 2024-05-28T14:22:01.012345Z 0 [Warning] [MY-000050] [Server] Skipping '!include' directive as maximum include recursion level was reached in file /etc/mysql/my.cnf at line 12.

How does it impact the server?

The skipped directive means the referenced option file is not read, so any variables set inside it stay at defaults.

Startup may still succeed, but expected configuration changes are lost, potentially leading to wrong buffer sizes, authentication settings, or plugin loading.

.

Common Causes

Circular include directives

File A includes file B, and file B includes file A, creating an endless loop that quickly reaches the 10-level limit.

Deeply chained includes

Administrators split configuration into many nested files (A includes B, B includes C, and so on) for organizational reasons.

Ten levels are enough for most cases, but overly granular setups hit the ceiling.

Third-party automation tools

Configuration management systems may generate my.cnf fragments and nest them without awareness of the MySQL limit.

Mistyped include paths

An !includedir pointing back to an upper directory can create recursive discovery of the same file set, exhausting the depth.

.

Related Errors

FAQs

Does this error stop MySQL from starting?

Usually no. MySQL skips the directive and continues with default settings, but missing options may cause indirect failures.

Can I raise the include depth limit?

No runtime variable controls the limit. The value is compiled into the server at 10 levels. Redesign the configuration instead.

Where is the depth counted from?

The main configuration file is level 0. Each subsequent !include increases the level by one. Directories added with !includedir also add a level per file processed.

How does Galaxy help here?

Galaxy’s startup checks alert you to MySQL warnings, and its shared editor lets teams audit my.cnf versions together, reducing the risk of circular includes.

Start Querying with the Modern SQL Editor Today!
Welcome to the Galaxy, Guardian!
You'll be receiving a confirmation email

Follow us on twitter :)
Oops! Something went wrong while submitting the form.

Check out some other errors

Trusted by top engineers on high-velocity teams
Aryeo Logo
Assort Health
Curri
Rubie Logo
Bauhealth Logo
Truvideo Logo