Articles in this section

How to change the max_user_connections value in MySQL/MariaDB on a Plesk server

Plesk for Windows kb: how-to Plesk for Linux ABT: Group B

Applicable to:

  • Plesk for Linux
  • Plesk for Windows

Question

How to adjust the max_user_connections value in MySQL/MariaDB on a Plesk server?

Answer

For Plesk on Linux
  1. Connect to your Plesk server via SSH.
  2. Open the my.cnf file in a text editor. In this example, we are using vi editor:
    • on CentOS/RHEL-based distributions 

      # vi /etc/my.cnf

    • on Debian/Ubuntu-based distributions

      # vi /etc/mysql/my.cnf

       

  3. Add the following line under the [MySQLD] section:

    # grep max_user_connections /etc/my.cnf
    max_user_connections = 100

  4. Save the changes and close the file.
  5. Restart the MySQL/MariaDB service to apply the changes:

    # systemctl restart mariadb

For Plesk on Windows Server
  1. Connect to your Plesk server via RDP.
  2. Open the file %plesk_dir%Databases\MySQL\my.ini in a text editor (just paste this path in Windows Explorer to open).
  3. Increase the value of max_user_connections:

    Note: If max_user_connections does not exist, add this line under the [MySQLD] section.

    CONFIG_TEXT: max_user_connections = 100

  4. Save the changes and close the file.
  5. Open Plesk Services Monitor in Windows Start > All Programs > Plesk.
  6. Select MySQL56 or MariaDB103 under the SQL Server section and click Restart to apply the changes.
Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.