Linode Forum Index Linode Forum
Linode Community Forums
 


MySQL Standalone Server / Static IP question

Click here to go to the original topic

 
       Linode Forum Index -> General Discussion
Author Message
adergaard



Joined: 20 Oct 2009
Posts: 18

Posted: Sat Jan 14, 2012 1:15 pm    Post subject: MySQL Standalone Server / Static IP question  

EDIT
Never mind this one.
I found out for myself that it wasn't possible to access another "private ip" if I hadn't set it up for the other machines as well, which makes a lot of sense now in hindsight. :)


-----------------------------

I have 3 linodes.

1 for mysql
1 for cronjobs
1 for php-fpm/nginx

I'm accessing the mysql linode from the two others. never the other way around.
In the Db on the mysql linode I have granted access to the other two linodes using the hostname I have in the A-records on DNS for the other two linodes, to the tables I want the other two linodes to work with and be able to connect to remotely.
All linodes are in the same location (Newark).

If I configure a private IP for the mysql linode, is that enough or do I need to do that for the other two linodes as well?
If yes, please explain why.

I see it like so:

Since I have a private IP for the mysql server, I can access that by referring to it in the "db"-references I do from PHP and from the python cron jobs. So why would I need to fix the static IP for the other two who are never going to get accessed by eachother or the mysql linode. It's only the mysql linode that is going to be interally accessed by the other two.

The reason I'm asking is that in the walkthroughs found here in the library it said I should do that for all machines that were going to interact. Seems redundant to me.

Grateful for your input.

Also, do I need to "secure" the mysql linode in a special way? I use iptables for my php-fpm/nginx linode but since I have no web server on the mysql linode, do I need to bother any with a firewall on that one?

Thanks much!
Back to top  
glg



Joined: 09 Jan 2009
Posts: 505

Posted: Sat Jan 14, 2012 6:39 pm    Post subject: Re: MySQL Standalone Server / Static IP question  

adergaard wrote: If I configure a private IP for the mysql linode, is that enough or do I need to do that for the other two linodes as well?
If yes, please explain why.

If you don't configure a private IP for the other linodes, the private IP for the mysql linode will never be used.
Back to top  
hybinet



Joined: 02 May 2008
Posts: 1058

Posted: Sat Jan 14, 2012 6:52 pm    Post subject:  

You will also want to set up some firewall rules on your MySQL server, as well as any other server that has a private IP. Otherwise, anyone who has a private IP in Newark will be able to connect to your server(s). It's probably much less dangerous than leaving the public network open, but why take any risks?
Back to top  
adergaard



Joined: 20 Oct 2009
Posts: 18

Posted: Sun Jan 15, 2012 6:20 am    Post subject:  

OK. Thank you both for taking time with answering this.

Will be adding a firewall to the MySQL linode to only allow for traffic from the other two linodes. Thanks again.
Back to top  
 
       Linode Forum Index -> General Discussion
Page 1 of 1