The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

MySQL server access restored.

Discussion in 'Database Discussions' started by morteza3245, Jul 2, 2015.

  1. morteza3245

    morteza3245 Well-Known Member

    Joined:
    Sep 16, 2013
    Messages:
    104
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    Root Administrator
    Hello
    after i did increase using below command:
    echo 524288 > /proc/sys/net/ipv4/ip_conntrack_max

    i received below error in email:

    Code:
    MySQL server access restored.
       
    
    The system was unable to authenticate to the local MySQL server on “localhost”.
    
    The connection driver reported the following error: Too many connections
    
    The system automatically reset the MySQL root password in order to restore normal operations.
    
    The system restored the password to the password in “/root/.my.cnf”.
    what is it?

    how i can resolve it?
     
  2. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,146
    Likes Received:
    34
    Trophy Points:
    48
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Hello,

    I can see you are getting Too many connections error so you need to increase your connection limit value in your my.cnf file to resolve this issues.
     
  3. morteza3245

    morteza3245 Well-Known Member

    Joined:
    Sep 16, 2013
    Messages:
    104
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    Root Administrator
    if i do not increase connection , server will see down time?

    and

    which one i should increase exactly?

    Thanks.
     
  4. DonaldBennett

    DonaldBennett Registered

    Joined:
    Jul 4, 2015
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Tampa, FL
    cPanel Access Level:
    DataCenter Provider
    Hello,

    You can increase the server max_connections limit in /etc/my.cnf

    So, SSH Into the server And Run The Following Steps:

    1. nano /etc/my.cnf
    2. On a new line you can type max_connections=250 (Or Whatever your limit maybe 250 is pretty Standard)
    3. Save The File holding Ctrl+O And it will Save The File.
    4. Restart MySQL Using: service mysql restart
    5. Check Connection limit: echo "show variables like 'max_connections';" | mysql

    Try it out and let me know. :)

    Thank You.
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    You can review your MySQL error log (/var/lib/mysql/$hostname.err) to see the specific error message when MySQL fails to load. This will help you determine which entries to change in your /etc/my.cnf file.

    Thank you.
     
Loading...

Share This Page