Floating IP: what it is, how to get it and assign to instance

Floating IP is a public, static IP address for instances created only in a private subnet (that is, without a public network interface). Using floating IP, such an instance will be able to accept incoming connections from the Internet.

Please note: the private subnet of the instance must be routable. Routing can be enabled in the subnet settings.

What it is used for
How it works
How it is charged
How to check if your subnet is routable
How to reserve a floating IP
     • From the menu
     • When creating an instance
How to assign a floating IP to an instance
How to detach a floating IP from the instance
How to delete a floating IP

What it is used for

Using a floating IP, you can rapidly provide access from an external network to the instance with no public network interface. Assign the address to the instance, and you will be able to connect to it.

Access can be organized in another way — by creating a public interface for the device. But in that case, public and private routed interfaces will have conflict because both are routes for accessing the Internet. You will have to manually configure the routing. If you need access to an external network only for a while, or you just don't want to deal with routing configuring, floating IP is the perfect solution.

How it works

You reserve a floating IP and assign it to the instance. When packets for this IP come to the router, it gives them to your device. When packets come back from the instance, the router sends them on behalf of the floating IP.

How it is charged

The IP price per month is displayed in the order window. You pay only for the time from creating an IP to deleting it: for example, if you had created an IP and then deleted it after an hour, you will be charged only for an hour of use. The price doesn’t depend on whether the address is assigned to the instance or not.


How to check if your subnet is routable

Open the "Networking" section, select the required network and go to the settings of the subnet your equipment is included in. The "Enable router gateway" slider must be enabled — it makes the subnet routable (servers inside such a subnet can access the Internet and receive incoming connections).



How to reserve a floating IP from the menu

Floating IP is issued at the specific data center, the address is linked to its location and can be assigned only to an instance in the same location. Select the region where your machine is located and go to the "Networking" section.

mceclip2.pngOpen the “Floating IPs” section. You can create an IP without assigning it to the machine. To do this, simply click on "Create Floating IP".

mceclip3.pngAlso, you can create an IP and immediately assign it to a specific instance. To do this, enable the “Assign to existed instance” slider, select the machine and interface, and click “Create a new floating IP”.


How to reserve a floating IP when creating an instance

When creating an instance, in the "Network settings" section, select the "Private" network type. Specify network and subnet of the interface you want to assign floating IP to. Enable the “Use floating IP” slider, click “Create a new floating IP” and save the settings using the “Add Interface” button.


The instance will be created with a private interface and a new floating IP assigned to it.

How to assign a floating IP to an instance

Next to the free IP, click "Assign to instance" or select this option from the selector on the right.

9.pngIn the pop-up window, select the instance and the network interface this floating IP will be assigned to. Click "Assign floating IP".


How to detach a floating IP from the instance

You can detach IP in the "Floating IPs" section or in the instance menu.

In the "Floating IP" section, click the selector next to the address and select "Detach from Instance". The IP will no longer be assigned to this machine.

mceclip4.pngIn the instance menu, open the "Networking" tab and select the private interface. Open the selector and click "Detach Subnetwork". The IP will no longer be assigned to this machine.


How to delete a floating IP

In the "Floating IPs" section, click the selector next to the desired address and select "Delete". The IP will be removed and no longer charged.




Was this article helpful?
Recently viewed articles