Symptoms
dbmap tool UI and CLI - fail with error when you attempt to map a cPanel username to itself.
Description
When running the CLI command as follows for the cPanel user cptest you get an error.
/usr/local/cpanel/bin/dbmaptool cptest --type mysql --dbusers cptest
A DB map Owner cannot own itself! at /usr/local/cpanel/Cpanel/DB/Map/Owner.pm line 55.
!···Cpanel::DB::Map::Owner::add_dbuser(Cpanel::DB::Map::Owner=HASH(0x317f548), HASH(0x2e51b90)) called at /usr/local/ cpanel/bin/dbmaptool line 83
The same happens when using the Database Map Tool within WHM UI.
Note: This is not an error per se. It really isn't possible to map a cPanel user as a DB user. The case we filed below is about making the error message a little easier to understand.
We've opened an internal case for our development team to investigate this further. For reference, the case number is CPANEL-50415. Follow this article to receive an email notification when a solution is published in the product.
Workaround
None at the moment.