Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

pkgacct mysql error since 70.0.42 update

Discussion in 'Data Protection' started by Josh Strike, May 17, 2018.

  1. Josh Strike

    Josh Strike Registered

    Joined:
    May 17, 2018
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Oregon
    cPanel Access Level:
    Root Administrator
    Since last night's update, our cron jobs running pkgacct have been throwing an error like:

    warn [pkgacct] SHOW GRANTS FAILED: show grants for 'username'@'server.myhostname.com'; Cpanel::Exception::Database::Error/(XID j7hkte) The system received an error from the “MySQL” database “mysql”: ER_NONEXISTING_GRANT (There is no such grant defined for user 'username' on host 'server.myhostname.com')

    where 'server.myhostname.com' is the hostname of the WHM server.

    I can only assume that up until last night's update, pkgacct was running mysqldump as 'username'@'localhost' for each of these accounts, and now it's running it as 'username'@'server.myhostname.com'. Why would it do that? There is no reason to add grants for each and every mysql account to the explicit hostname of the WHM server. In fact, what it should be reading are the grants for localhost. Is there a way to set it to run the way it used to?
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,749
    Likes Received:
    1,884
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello @Josh Strike,

    Can you let us know if skip-name-resolve is enabled in the system's /etc/my.cnf file? This option is unsupported and can lead to the issue you have described.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Josh Strike

    Josh Strike Registered

    Joined:
    May 17, 2018
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Oregon
    cPanel Access Level:
    Root Administrator
    We do use skip-name-resolve and we have been using it for ten years. I suspect that turning it off would cause a lot of problems with remote mysql access, as we have other servers that need access to this database.

    Also, server.myhostname.com doesn't resolve to 127.0.0.1. It resolves to one of the dedicated IPs of the server. So if we turned off skip-name-resolve, mysqldump would probably fail completely.

    The question is how do we get pkgacct to use the user @ 'localhost' -- as it has always done up until now?
     
  4. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,749
    Likes Received:
    1,884
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello @Josh Strike,

    It's possible you started seeing this warning message in cPanel & WHM version 70 due to the inclusion of the following case:

    Fixed case CPANEL-18831: Warn when show_grants() gets an unexpected string.

    Using skip-name-resolve in a server's MySQL configuration file is unsupported. We don't test the product with this option enabled, and it's been known to lead to MySQL connection issues in the past under several scenarios (e.g. when using a remote MySQL server, during account backups/transfers/restorations, and with phpMyAdmin). We document this at:

    Manage MySQL Profiles - Version 70 Documentation - cPanel Documentation

    Can you temporarily disable that option, restart MySQL, and then test if Pkgacct continues to fail? If the issue persists, please feel free to open a support ticket using the link in my signature so we can take a closer look.

    Additionally, I encourage you to vote and add feedback to the following feature request if you'd like to see support for the skip-name-resolve MySQL option added to the product:

    Allow skip-name-resolve in the MySQL configuration.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice