2 Instances | 1 Static IP | Help With College Project

45 views
Skip to first unread message

Colm Reilly

unread,
Feb 13, 2018, 8:59:56 AM2/13/18
to Google App Engine
Hi there,

I am studying computer science as a complete newbie and I am using Google cloud to help with creating virtual machines. 

I have to create two virtual machines and have them talk to each other. As I'm a newbie here I have some problems. 

So I assume on my starter package that I can only assign one static IP. Am I right? Is there a way for me to use the same static address for two instances or what would people suggest. 

This is just a college project that i am working on so I don't want to upgrade my account at present. 






Barry Hunter

unread,
Feb 13, 2018, 9:12:27 AM2/13/18
to google-appengine

So I assume on my starter package that I can only assign one static IP. Am I right?

dont know that. Not sure what starter package refering to. 

 
Is there a way for me to use the same static address for two instances or what would people suggest. 

No. A IP would refer to a single instance. If there was a way, how would know what instance to use when try to cotnact the IP? 


Maybe use some sort of 'dynamic dns' system, for the VMS to register their current IP with some sort of registry. So other instances can contact them. 

... or just use the one that Google provides. 

(ie use hostnames, NOT IP addresses directly. ) 



Dinçer Kavraal

unread,
Feb 13, 2018, 9:53:08 AM2/13/18
to Google App Engine
Hi,

1) I understand "free tier" as starter package. If so, no you don't have that limit. Your limits are at All Quotas page at the cloud console.
As far as I know, you have more than 2 IP's, because each instance (VM) will be created with its own public IP. You can convert an IP into static after the machine is created (also you can do that before creating)
I suggest you to create an ordinary instance (as your second VM) and then convert that IP into static.
You can update the topic if that doesn't work.

2) Onto the other question, once I was looking for a solution for 1 IP per multi instance. But it seems not possible in terms of your need. But you can use
a) individual IPs per VM to solve your problem
b) run docker inside your one instance (two or more dockers will be running on 1 instance with 1 public/static IP)
c) you can aggregate two different instances through a custom load balancer. But you can't know which one will reply. So this is not a solution I believe.

Best

Carlos (Cloud Platform Support)

unread,
Feb 13, 2018, 3:11:07 PM2/13/18
to Google App Engine
For additional information on Free Tier you can visit this article. You will not be able to request additional quota while using this tier.  

As previously stated, you can always check the resource quota to fully understand what are your limitations. You certainly cannot assign the same IP to different VMs. 

If you are actually limited to one external IP (which is different from using an static IP), you could use a bastion host to connect to other instances that do not have external IP. Communication between instances via internal IP is certainly feasible.

Colm Reilly

unread,
Feb 16, 2018, 7:09:12 AM2/16/18
to Google App Engine
Cheers everyone! Some great suggestions. I'll be back once I try them. 
Reply all
Reply to author
Forward
0 new messages