I can't connect Joomla! remotely with MySQL

Joomla versions 2.5, 1.7 and 1.6 are all end-of-life since December 31st 2014 and are no longer supported. Please use Joomla 3.x instead.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Locked
Abdusalam
Joomla! Apprentice
Joomla! Apprentice
Posts: 17
Joined: Tue Jul 22, 2008 7:17 pm
Location: Benghazi - Libya
Contact:

I can't connect Joomla! remotely with MySQL

Post by Abdusalam » Wed Mar 19, 2014 12:31 pm

I have two hosting (1 and 2), and I have Joomla website files on hosting 1, Joomla mysql database on hosting 2, both hosting 1 and 2 have Cpanel administration. I want run Joomla website on host1 by linked it remotely to mysql database on host 2

Steps that I made:

- In hosting 2 added IP address for hosting 1 in (Remote MySQL).
- In Joomla configuration.php file I have changed database section like:

var $host = '74.116.84.169';
var $user = 'artjour';
var $password = 'abc@123';
var $db = 'apuser';

- I also have changed the host name by server name like:

var $host = 'servername.mydomainname.com';

But unfortunately :( , Could not connect to MySQL, please it's very important for me to know what's my wrong here.

Thanks in advance.
Thanks & Best Regards

sander_v_bergen
Joomla! Guru
Joomla! Guru
Posts: 529
Joined: Fri Oct 21, 2011 2:04 pm

Re: I can't connect Joomla! remotely with MySQL

Post by sander_v_bergen » Wed Mar 19, 2014 12:45 pm

In Cpanel, did you add the correct address under Remote MySQL? Try adding % (=wildcard) and see if that helps.
If so, change % to the correct address.

User avatar
Tonie
Joomla! Master
Joomla! Master
Posts: 16553
Joined: Thu Aug 18, 2005 7:13 am

Re: I can't connect Joomla! remotely with MySQL

Post by Tonie » Wed Mar 19, 2014 12:54 pm

Is the mysql user allowed to connect to the database on a remote server? Often, it's only allowed to connect to the server the database is running on.


Locked

Return to “Installation Joomla! 2.5”