SOLVED [CPANEL-21968] Auto Adjust Mysql Limits using 100%

starchild2012

Member
Jul 24, 2012
21
2
53
cPanel Access Level
Root Administrator
Hi,

I've noticed for a few days now, the following script using 100% CPU constantly. I don't ever recall seeing this before.

Should I be concerned?

/usr/local/cpanel/3rdparty/bin/perl /usr/local/cpanel/scripts/auto-adjust-mysql-limits --no-restart

We're currently running CENTOS 7.4 standard [server], v74.0.6
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello @starchild2012,

This is a known issue where it's possible for the auto-adjust-mysql-limits script to hang during the attempt to restart MySQL upon the adjustment to the /etc/my.cnf file. A fix is scheduled for publication in an upcoming build of cPanel & WHM version 74 as part of internal case CPANEL-21968. I'll update this thread again once it's published. In the meantime, the temporary workaround is to manually kill the auto-adjust-mysql-limits process and then restart MySQL using the steps below:

1. Find the process ID associated with the auto-adjust-mysql-limits process:

Code:
ps aux|grep auto-adjust-mysql-limits
2. Kill the process ID:

Code:
kill -9 $PID
3. Restart MySQL:

Code:
/scripts/restartsrv_mysql
Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello,

To update, this is fixed in cPanel & WHM version 76:

Fixed case CPANEL-21968: Avoid hang when restarting MySQL if my.cnf needs adjustment.

You can monitor the following page to see when version 76 reaches each release tier:

cPanel Release Highlights

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Why does this have to run? Can it be disabled?
Hello @sparek-3,

You can disable the following options in WHM >> Tweak Settings if you want to disable the automatic adjustment of the /etc/my.cnf file:

Allow cPanel & WHM to determine the best value for your MySQL open_files_limit configuration?
Allow cPanel & WHM to determine the best value for your MySQL max_allowed_packet configuration?
Allow cPanel & WHM to determine the best value for your MySQL innodb_buffer_pool_size configuration?


We document how this script works at:

The auto-adjust-mysql-limits Script - Version 76 Documentation - cPanel Documentation

Thank you.