Ask Your Question
1

Why floating IP?

asked 2013-12-14 19:34:29 -0500

yijian gravatar image

updated 2014-01-22 15:12:32 -0500

Evgeny gravatar image

In a conventional virtual machine system like VMware or VirtualBox, a network interfaces is either bridged or NATed. This is easy to understand. You IP is assigned by external DHCP server (bridging case) or VM software (NATting case). However, the situation for OpenStack is not so easy to follow - why a private IP (mine is 172.x.x.x) which is apparently assigned by OpenStack and then a floating IP? Why not straight forward NATting? What problem is this trying to solve? What is the benefit?

edit retag flag offensive close merge delete

4 answers

Sort by ยป oldest newest most voted
5

answered 2013-12-14 22:07:41 -0500

jtopjian gravatar image

While Floating IPs are indeed public IP addresses, that's not the entire point of them.

The IP address that each instance receives is known as a Fixed IP address. In the majority of OpenStack installations, the Fixed IP range is composed of a private IP range. But it doesn't have to be. In fact, your Fixed IP range _could_ be a public IP subnet if you so wished.

The problem is that most people don't have a large enough public IP range to make it worthwhile to use as their Fixed IP range. Let's say, for example, you have access to a /24 subnet (254 usable IPs) and you make that your Fixed IP range. You've just limited yourself to 254 instances in your cloud.

If you made your Fixed IP range something like 10.0.0.0/16, you can accommodate ~65,500 instances. Now your Fixed IP range is no longer your bottleneck.

But public IP address limitations still aren't the point of Floating IPs, even though Floating IPs inadvertently resolve that issue.

Floating IPs are to Fixed IPs as volume storage is to instance storage: one can be moved from instance to instance while the other is stuck on a single instance. A Floating IP can be thought of as the antithesis of a Fixed IP.

Modern design of infrastructure inside the cloud says that you should make everything as disposable as possible. If you lose an instance, just use your automation tools to fire a new one up. It's a great goal to work towards, but reality doesn't always work that way. Just as attaching and detaching volumes serve their purpose, so does attaching and detaching IPs. That's really the point of a Floating IP.

edit flag offensive delete link more

Comments

Where is there good documentation for maxing the fixed ip range the same as the public? I have a small setup where it would like to simplify the subnets. I am also looking to setup PXE/Kickstart for building images.

clemenko gravatar imageclemenko ( 2013-12-16 06:12:28 -0500 )edit
1

answered 2013-12-14 21:42:48 -0500

huwei-xtu gravatar image

It is not difficult to understand that a floating ip is needed in openstack or in some other cloud platform, just like amazon. Just think, how customers connect their vms from external network without floating ips ? How customers let their webapps can be visited without floating ips ? Just like the user in an internal network and connect external network by nat, but the user in external network can not connect the internal one if do not do the port mapping.

edit flag offensive delete link more
1

answered 2013-12-20 18:35:15 -0500

kfox1111 gravatar image

One use case it enables is rolling updates. You start with a floating ip on vm A. You create a new vm B, check it out and make sure it is doing what you want. You then pause vm A and move the floating ip and any other resources onto vm B. If everything works, you delete vm A. If it doesn't, you move stuff back to vm A and delete vm B.

As far as the user is concerned, they only ever have to know about the floating ip, which doesn't change.

edit flag offensive delete link more
0

answered 2013-12-21 23:25:49 -0500

DennyZhang gravatar image

Excellent question! I used to be bother by this, when I first know this.

In one word: floating ip is routable ip, but it's not necessarily public ip.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2013-12-14 19:34:29 -0500

Seen: 5,125 times

Last updated: Dec 21 '13