How to manage remote Mysql database with PhpMyAdmin
Here's the scenario:
The Mysql Database resides on a different server and connections can only be made via the web server.
The web server have PhpMyAdmin installed and now the requirement is to access the Mysql database from the internet (from specified IP addresses only)
Here's the web server setup:
Ubuntu Core with Apache, PHP and PhpMyadmin.
And here's what needs to be changed to ensure that the Mysql database can be access from these IP addresses:
change to user root
make changes to the config.inc.php file
if (empty($dbserver)) $dbserver= 'add your server ip or hostname here'
Replace the 'add your server ip or hostname here' with relevant server value and save the file
Edit the phpmyadmin.conf file
Comment the line:
Alias /phpmyadmin /usr/share/phpmyadmin
Add the following lines after DirectoryIndex index.php
All from 'your public ip address'
Replace the 'your public ip address' with relevant ip address and save the file
restart Apache service
service apache2 restart