Jump to content
  • 0

Allowing incoming connections from website to vps.


Nipsino

Question


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

I was wondering if anybody has found a guide on how to allow incoming connections from the website to my VPS' mysql databases.

My VPS OS; Debian 6(64-bit)

*If anybody is wondering I'm trying to install FluxCP*

Link to comment
Share on other sites

21 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  224
  • Reputation:   22
  • Joined:  03/23/12
  • Last Seen:  

On a single host or...?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

On a single host or...?

What do you mean by single host?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  224
  • Reputation:   22
  • Joined:  03/23/12
  • Last Seen:  

I mean if you're using a different host for website and sql.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

Here's the error that keeps popping up. 28apd2d.png

I mean if you're using a different host for website and sql.

Yeah I'm using two different hosts. I've tried to configure mysql on the vps to be able to grant all access privileges to my webhosting ip.

Edited by Eden
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  224
  • Reputation:   22
  • Joined:  03/23/12
  • Last Seen:  

Made sure your servers.php configs are ok?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

Made sure your servers.php configs are ok?

I'm doing that right now. I'll send you a private message so it'll be easier to communicate there instead of here. Haha.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  51
  • Reputation:   0
  • Joined:  05/03/12
  • Last Seen:  

Currently in need of a solution for this as well. Could you kindly post if you were able to fix the problem?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  707
  • Reputation:   168
  • Joined:  01/26/12
  • Last Seen:  

Hi Eden,

Contact your webhost, ask them to whitelist your VPS IP.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

Hi Eden,

Contact your webhost, ask them to whitelist your VPS IP.

Would you mind helping me?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  707
  • Reputation:   168
  • Joined:  01/26/12
  • Last Seen:  

Would you mind helping me?

Hi Eden,

Only your web hoster has the ability to whitelist the IP's to allow those type of connections; you must submit a ticket to them and request them to whitelist your VPS IP.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

Would you mind helping me?

Hi Eden,

Only your web hoster has the ability to whitelist the IP's to allow those type of connections; you must submit a ticket to them and request them to whitelist your VPS IP.

I've whitelist my ip manually by going to CPanel> Database > Remote MySQL.

Alright so I've managed to get FluxCP installed on the webhost. The main problem for me is how would I be able to use rAthena and the webhost together. I've made an account on the FluxCP, tried to log into my RO server, it wouldn't let me.

I've followed Judas' Bible. :3

What I think is happening is that the conf/import/inter_conf.txt overwrites the original inter_conf. So I don't think I can use the webhost. I've also tried changing the database connections in conf/import/inter_conf.txt but it'll always give me an error like, "Can't get hostname for your server."

Oh yeah. Here's the actual FluxCP; cp.reunion-ro.net Even the server status isn't showing that my server is online when it is.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  707
  • Reputation:   168
  • Joined:  01/26/12
  • Last Seen:  

Hi Eden,

Are you sure it's actually whitelisted? The error you got, 'SQLSTATE[HY000] [2003]' is an error in which their Apache server disables PHP from establishing outgoing connections for security purposes.

http://www.filonov.com/blog/2009/08/07/sqlstatehy000-2003-cant-connect-to-mysql-server-on-xxx-xxx-xxx-xxx-13/

I would suggest that you reference that error to him, and provide the VPS IP for him to whitelist.

As for the inter_conf.txt; you can simply delete it from the import if you wish to use the inter_athena.conf's settings instead. These settings should not affect how your webhost performs, unless you are using your webhost's MySQL database for your RO database; which is highly NOT RECOMMENDED.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

I've finally fixed the problem! Thanks for all of the help. Haha.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  51
  • Reputation:   0
  • Joined:  05/03/12
  • Last Seen:  

How were you able to fix the problem? I am trying to solve the same problem too. But what I'm trying to do is making the host(cp) connect to the database on my pc at home. As of now I have no luck in doing so.

@Sir Asura, do you have an idea at what might have gone wrong? I get this error when I am trying to install my ceres cp.

Warning: mysqli_connect() [function.mysqli-connect]: (HY000/2003): Can't connect to MySQL server on '112.207.3.203' (110) in/home/content/16/8985816/html/evespiridion/cp/install/install.php on line 49

Can't connect to Ragnarok MySQL server. Press back and check your MySQL host, user, password.

Sorry to have barged in the thread, but this is exactly what I am trying to do this past few weeks.

Edited by evespiridion
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

How were you able to fix the problem? I am trying to solve the same problem too. But what I'm trying to do is making the host(cp) connect to the database on my pc at home. As of now I have no luck in doing so.

@Sir Asura, do you have an idea at what might have gone wrong? I get this error when I am trying to install my ceres cp.

Warning: mysqli_connect() [function.mysqli-connect]: (HY000/2003): Can't connect to MySQL server on '112.207.3.203' (110) in/home/content/16/8985816/html/evespiridion/cp/install/install.php on line 49

Can't connect to Ragnarok MySQL server. Press back and check your MySQL host, user, password.

Sorry to have barged in the thread, but this is exactly what I am trying to do this past few weeks.

I'm guessing you don't have your MySQL Server configured correctly. Uhmm. Are you sure you're using the correct MySQL Information?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  51
  • Reputation:   0
  • Joined:  05/03/12
  • Last Seen:  

Yes I am exactly sure about it. I'm just using root as my username and the password is also correct. I tried connecting to mySQL Query Browser using my ip address which is : 112.207.3.203 and I can connect without any problems. I even tried connecting through telnet by using open 112.207.3.203 3306. I can connect without any problems. I also forwarded port 3306 on my lan IP 192.168.1.104.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  218
  • Reputation:   16
  • Joined:  01/24/12
  • Last Seen:  

Yes I am exactly sure about it. I'm just using root as my username and the password is also correct. I tried connecting to mySQL Query Browser using my ip address which is : 112.207.3.203 and I can connect without any problems. I even tried connecting through telnet by using open 112.207.3.203 3306. I can connect without any problems. I also forwarded port 3306 on my lan IP 192.168.1.104.

Have you created a new mysql user under your websites IP? Make sure it has all access. Also if you're using debian. Put a # near bind-networking=127.0.0.1 in my.cnf

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  707
  • Reputation:   168
  • Joined:  01/26/12
  • Last Seen:  

Hi evespiridion,

If you tried Eden's suggestion with removing the bind from the MySQL configuration; and it did not work...

I would suggest that you look up your MySQL account info; see if it is locked onto '@localhost'. When this happens, it only allows your computer to connect to the SQL server on your computer. So in order for outside computers to connect, you must create a user account with '@%' or % (Any Host).

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  51
  • Reputation:   0
  • Joined:  05/03/12
  • Last Seen:  

Yes I have already commented out the bind-address line. I have also created a grant permission for the user on all databases by using the grant permission. When I issued it, I used the wildcard for users and as well as for IP addresses.

@Asura, how would I be able to check that info out? I mean in MySQL Admin?

Edited by evespiridion
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  707
  • Reputation:   168
  • Joined:  01/26/12
  • Last Seen:  

Hi evespiridion,

It would be safe to assume that your host is blocking the connection if everything is okay on your end. I would recommend sending in a ticket with the error message.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  51
  • Reputation:   0
  • Joined:  05/03/12
  • Last Seen:  

I don't know if that's the case. I tried putting the database on my host. I was able to connect to the database. But the only problem is that it makes the server somehow laggy because of the transfer time of data from the host to my PC and vice versa. I kinda wanted to let someone to actually remotely connect to my database using mysql. I'd gladly provide you the username and passwords for my database just to test out if it really is accessible.

Link to comment
Share on other sites

×
×
  • Create New...