SBDavid
Mar 10th, 2013
Mar 10th, 2013
Restoring a User’s Database Access For WHM version 11.36
Restoring a User’s Database Access For WHM version 11.36
If a database user loses access to databases, you may be able to restore the user’s grants to the database using the restoregrants utility.
Using Restoregrants to Restore the User’s Database Access
Execute one of the following commands from the command line:
/usr/local/cpanel/bin/restoregrants –cpuser=$cpuser –db={mysql, pg} –dbuser=$dbuser
or
/usr/local/cpanel/bin/restoregrants –cpuser=$cpuser –db={mysql, pg} –all
or
/usr/local/cpanel/bin/restoregrants –cpuser=$cpuser –db={mysql, pg} –all
$cpuser The cPanel username which has lost access to databases.
{mysql, pg} The type of database: mysql for MySQL or pg for PostgreSQL.
$dbuser The database user whose privileges you wish to restore.