SOLVED A few questions about MySQL & Redundancy

Bananenbaas

Member
Dec 8, 2014
11
3
53
cPanel Access Level
Root Administrator
Hi Guys,

Since more and more clients are asking me about Redundancy in combination with cPanel. I know more and more people are asking for it (), but no ETA or info from cPanel about it yet. So I have to create my own redundant setup.

My current situation is as follows, I have several servers running cPanel, E-mail and MySQL (MariaDB) locally.

For a few clients I build a setup to be redundant using:

  • 2 cPanel boxes for Web+E-mail, 1 master and 1 slave (in different datacenters). Rsync setup per user. Basic information has been copied using the transfertool.
  • 2 boxes (3 nodes is the minimum I know but due to costs 2 should be enough for a master-master config) for a MariaDB Cluster (also in different datacenters). For failover using a DNS name to connect.
  • 1 Box for ClusterControl by SeveralNines
I used the following tutorial: severalnines.com/blog/high-availability-mysql-cpanel-galera-cluster

Now I have setup all the boxes. Connected them using the MySQL Profiles and I thought it was running smoohtly but then I noticed the following:

When connected to the remote SQL Cluster phpMyAdmin asks a cPanel user for a login every time phpMyAdmin is clicked in cPanel. So there is an iFrame in the cPanel environment that asks for the username and password of the user, when I fill those in it connects phpMyAdmin to the remote cluster but the user cannot do anything here. No editing a database, import tables, just nothing... When you add a database in cPanel it appears on the SQL cluster as a new database and I cannot connect to it, with for example a wordpress installation. It gives me the error that the user doesn't have the rights...

Because the documentation made by cPanel is not that, let's say, extensive. I do not know what steps to take next to get this thing fixed.

So my problem is with the connectivity to the remote sql cluster and using phpMyAdmin.

Hope you guys can help me!
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,270
463
When connected to the remote SQL Cluster phpMyAdmin asks a cPanel user for a login every time phpMyAdmin is clicked in cPanel. So there is an iFrame in the cPanel environment that asks for the username and password of the user, when I fill those in it connects phpMyAdmin to the remote cluster but the user cannot do anything here. No editing a database, import tables, just nothing... When you add a database in cPanel it appears on the SQL cluster as a new database and I cannot connect to it, with for example a wordpress installation. It gives me the error that the user doesn't have the rights...
Hello,

Could you verify which version of cPanel is installed on an affected system? You can check with the following command:

Code:
cat /usr/local/cpanel/version
Also, could you confirm if the correct remote host is listed in the output from the command below? EX:

Code:
/usr/local/cpanel/base/3rdparty/phpMyAdmin/config.inc.php
Thank you.
 

Bananenbaas

Member
Dec 8, 2014
11
3
53
cPanel Access Level
Root Administrator
Hi Michael,

Could you verify which version of cPanel is installed on an affected system? You can check with the following command:

Code:
cat /usr/local/cpanel/version
Response:
Code:
[root@titan ~]# cat /usr/local/cpanel/version
11.64.0.12
Also, could you confirm if the correct remote host is listed in the output from the command below? EX:

Code:
/usr/local/cpanel/base/3rdparty/phpMyAdmin/config.inc.php
Thank you.
Unfortunately, I've been trying to setup another node and now access is denied to the entire SQL cluster... So I need to figure that out first to get it running again :) Will post an update here when I'm done with that!