Warning
Error Code:
80
MySQL Error 80: Option Value Auto-Adjusted
Description
This error indicates that a numeric value provided for a MySQL option was outside its expected range or inconsistent with its signedness. MySQL automatically corrected or adjusted this value to a valid one, allowing the operation to proceed but signaling a potential configuration issue. It often occurs when setting server variables or client options.
Error Message
option '%s': signed value %s adjusted to %s.
Known Causes
3 known causesIncorrect Value Range
The specified numeric value for a configuration option falls outside the permissible minimum or maximum range defined for that option.
Signedness Mismatch
An option expecting an unsigned integer or a specific signed range receives a value that, when interpreted as signed, is incompatible with its intended type.
Configuration Error
A typo, misunderstanding of the option's expected data type, or incorrect formatting leads to an invalid numeric input.
Solutions
3 solutions available1. Adjusting the `max_connections` Value easy
Increase the `max_connections` setting in your MySQL configuration to accommodate the desired number of connections.
1
Locate your MySQL configuration file. This is typically `my.cnf` on Linux/macOS or `my.ini` on Windows. Common locations include `/etc/mysql/my.cnf`, `/etc/my.cnf`, or within the MySQL installation directory.
2
Open the configuration file in a text editor with administrative privileges.
3
Find the `[mysqld]` section. If it doesn't exist, create it.
[mysqld]
4
Look for the `max_connections` parameter. If it's present, increase its value to a number slightly higher than what you believe you need. If it's not present, add it. The error message often indicates the adjusted value, which can give you a clue. For example, if it says `signed value 1000 adjusted to 16384`, you might set it to `17000` or higher to ensure it's not adjusted down again by system limits.
max_connections = 2000
5
Save the configuration file and exit the editor.
6
Restart the MySQL server for the changes to take effect.
sudo systemctl restart mysql
2. Increasing System-Level File Descriptor Limits medium
The error can occur if the operating system's limit on open file descriptors is lower than what MySQL requires for its connections.
1
Determine the current open file descriptor limit for the MySQL user. On Linux, you can use the `ulimit -n` command for the current session, or check `/etc/security/limits.conf` for persistent settings.
ulimit -n
2
Edit the `/etc/security/limits.conf` file (or a file in `/etc/security/limits.d/`) with administrative privileges.
3
Add or modify lines to increase the open file descriptor limit for the MySQL user. Replace `mysqluser` with the actual user MySQL runs as (often `mysql`).
mysqluser soft nofile 65536
mysqluser hard nofile 65536
4
Save the file and exit the editor.
5
To apply these changes immediately without a full system reboot, you might need to re-login as the MySQL user or restart the MySQL service. A system reboot is the most reliable way to ensure the limits are applied globally.
sudo systemctl restart mysql
3. Reviewing MySQL Configuration for Other Limit Parameters medium
Other MySQL configuration parameters might indirectly affect connection limits or resource allocation, leading to this adjustment.
1
Examine your MySQL configuration file (`my.cnf` or `my.ini`) for parameters that might be related to resource limits or connection handling. While `max_connections` is the most direct, consider others.
2
Pay attention to parameters like `open_files_limit` (which should generally be set to a value that respects the system's `nofile` limit), `thread_cache_size`, and `table_open_cache`. If these are set too low, they might indirectly contribute to issues that cause `max_connections` to be adjusted.
# Example: Ensure open_files_limit is reasonable
open_files_limit = 65535
3
If you make any changes to these parameters, save the configuration file.
4
Restart the MySQL server to apply the changes.
sudo systemctl restart mysql