2 Replies - 1611 Views - Last Post: 06 September 2012 - 04:53 AM

#1 lucky3  Icon User is offline

  • Friend lucky3 As IHelpable
  • member icon

Reputation: 231
  • View blog
  • Posts: 765
  • Joined: 19-October 11

Hosting provider doesn't allow external connections to MySQL DB?&#

Posted 06 September 2012 - 02:04 AM

Hi. I programmed a Windows application, that connects to Wordpress database, and adds/updates posts and so on. I tested it on my localhost MySQL, and everything works fine.

Then I wanted to test it on my remote live site, that is hosted by some provider. This remote Wordpress site is live for several years now, and I have FTP access, access to phpMyAdmin, I create databases and DB users in Plesk... When I asked them for address and port, so I could connect with my username and password, they replied that it is not allowed to connect to mysql remotely, because of security reasons.

Such answer seems unreasonable to me. What security issues there could be, if I can do the same with phpMyAdmin? It just means that I must do some extra unconfortable work through my application. Is their argument reasonable? Does most of other hosting providers also block remote database access? Can I find out IP and port of "my" remote database I want to connect with username/password?

Thanks for reading.

Is This A Good Question/Topic? 0
  • +

Replies To: Hosting provider doesn't allow external connections to MySQL DB?&#

#2 Ryano121  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1362
  • Posts: 3,002
  • Joined: 30-January 11

Re: Hosting provider doesn't allow external connections to MySQL DB?&#

Posted 06 September 2012 - 03:07 AM

Seems a bit weird to me but you can kind of see where they are coming from. I do however know that with my host (I'm with Hostgator) you have to explicitly tell them what Ip addresses you will be connecting from for it to work. But it does however still work perfectly well once you've done this so it certainly can be done.

I suppose it's just up to your hosting provider.
Was This Post Helpful? 1
  • +
  • -

#3 lucky3  Icon User is offline

  • Friend lucky3 As IHelpable
  • member icon

Reputation: 231
  • View blog
  • Posts: 765
  • Joined: 19-October 11

Re: Hosting provider doesn't allow external connections to MySQL DB?&#

Posted 06 September 2012 - 04:53 AM

Thanks Ryano121, you helped me. I checked with HostGator and several others, and there's no problem at all. Here's their info, and as I have dynamic IP adress, I was really happy when I read this:

Quote

Wait a minute, my IP constantly changes.

Okay, you have a dynamic IP address. Therefore, every time you go online, or every once in awhile, your IP changes. You have a few options here. The most secure, would be to update your IP in Remote MySQL every time your IP changes. However, you do have other options available. You could simply enter % (a percentage sign) in the Add Access Hosts text field. This will allow any IP to remotely connect to your databases. Another option: Lets say the first two parts of your IP never change. Then, you could enter 93.138.%.% , where the first two parts are your actual IP address numbers.

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1