Ask Your Question

Floating Loadbalancing IP

asked 2014-09-23 04:45:33 -0500

PatRock gravatar image

updated 2014-09-24 02:50:30 -0500

So this morning I finished my Loadbalancing Test Template. Everything went well and the stack was created completely, but unfortunately something does quite not work as expected.

1) I added a floating IP resource for my pool, but the floating IP-Adresses weren't created.

    type: OS::Neutron::Pool
      protocol: HTTP
      monitors: [{get_resource: monitor}]
      subnet_id: {get_param: subnet}
      lb_method: ROUND_ROBIN
        protocol_port: 80
    type: OS::Neutron::LoadBalancer
      protocol_port: 80
      pool_id: {get_resource: pool}

    type: OS::Neutron::FloatingIP
      floating_network_id: {get_param: public}
      port_id: {get_attr: [pool, vip, port_id]}

public = the ID of my external Network 10.0.x.x and the subnet = the Subnet ID of my internal Network 196.0.x.x

All my instances were created in the internal Network, but nothing has a external IP.

Do I have to create an extra port-resource for the pool?


Output of resource-show for the floating ip address:

| Property               | Value                                   ...|
| description            |                                         ...|
| links                  | http://controller:8004/v1/ad948ee0c33749...|
|                        | http://controller:8004/v1/ad948ee0c33749...|
| logical_resource_id    | lb_floating                             ...|
| physical_resource_id   | a3fd80f3-ec10-48fa-9d70-1c9f72bd0dcd    ...|
| required_by            |                                         ...|
| resource_name          | lb_floating                             ...|
| resource_status        | CREATE_COMPLETE                         ...|
| resource_status_reason | state changed                           ...|
| resource_type          | OS::Neutron::FloatingIP                 ...|

Output of neutron floatingip-list

| id                                   | fixed_ip_address| floating_ip_address | port_id |
| 0f4640f6-a307-4d81-8302-d244c26812ff |              ||                     |
| 19659c84-0362-4a9c-bd22-5790257d4c82 |              ||                     |
| 26d19489-2760-42bb-adfc-d906cf6f7eb1 |              ||                     |
| 31749b21-6ce6-4f16-ae73-21382d0a5f69 |              ||                     |
| 41bb0da2-f58d-4cb2-8852-94c3d42da255 |              ||                     |
| 7c802527-7d26-42bd-ad65-b62a83934876 |              ||                     |
| a3fd80f3-ec10-48fa-9d70-1c9f72bd0dcd | || 1d287d0c-3e7a-4afa- |
|                                      |              |            | b58a-e80fd61118ed   |
| ac101ef7-447f-4db2-bfd4-23e428dd6b01 |              ||                     |
| aed67890-321f-4dab-a31b-1517363c4b20 |              ||                     |
| be562ec7-6a60-4a80-8ee5-93fa3efbba48 |              ||                     |
| c2754b98-3781-4d88-a504-d841cb212efb |              ||                     |
| d6c6a48f-3040-48a7-8bfc-56b2721b6efd |              ||                     |
| f040c26e-91b9-451c-97e7-07f8818deba8 |              ||                     |
| fd3b847e-76f0-4a8a-bbe0-287d70e3c4fb |              ||                     |
edit retag flag offensive close merge delete


Does heat resource-list <stack_name> show the lb_floating resource? What does heat resource-show <stack_name> lb_floating look like?

larsks gravatar imagelarsks ( 2014-09-23 08:45:59 -0500 )edit

Also, I would consider splitting this into two separate questions. These two questions are largely unrelated, and someone may provide an answer to one and not the other. You want to be able to fairly "accept" a correct answer, which is hard to do in this case.

larsks gravatar imagelarsks ( 2014-09-23 08:46:46 -0500 )edit

It's better if you update your question with the new informatino (because your formatting options are a lot nicer, and it keeps this comment chain from being ridiculously long).

larsks gravatar imagelarsks ( 2014-09-23 09:58:03 -0500 )edit

It looks like the floating ip address was created correctly. Does neutron floatingip-list show it associated with a fixed address?

larsks gravatar imagelarsks ( 2014-09-23 10:10:49 -0500 )edit

Sry for the long break (Central Europe TimeZone) and thx for updating my question. I added the neutron floatingip-list is the IP adress of my Pool the others are just generated but not in use.

PatRock gravatar imagePatRock ( 2014-09-24 02:52:56 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2014-09-24 09:53:10 -0500

larsks gravatar image

I am converting some of our comment conversation into an answer.

You can see information about individual resources in your stack through the resource-list and resource-show commands. To see information about the floating ip created in your stack, you would run:

heat resource-show <stack_name> lb_floating

Which, per your information, shows that the floating ip address was created:

| Property               | Value                                   ...|
| description            |                                         ...|
| links                  | http://controller:8004/v1/ad948ee0c33749...|
|                        | http://controller:8004/v1/ad948ee0c33749...|
| logical_resource_id    | lb_floating                             ...|
| physical_resource_id   | a3fd80f3-ec10-48fa-9d70-1c9f72bd0dcd    ...|

Using the neutron floating-ip-list command, you can see with which fixed address this address is associated.

When you assign a floating ip address to a pool, all that does is map the floating ip to the fixed ip of the pool. It does not assign floating ips to instances that are members of the pool. Ideally, the pool members should not even require floating ip addresses -- all your access to the instances should be through the load balanacer. You can assign floating ips to the instances if you need to access them directly without going through the load balancer, or you could also run a "gateway" host -- this would only require a single additional floating ip, rather than one per instance. You would first log into the gateway host, and from there log in to your instances using their fixed address.

edit flag offensive delete link more


ok i understand i only need to connect to the Loadbalancer and not to the instances directly. I just thought i have to do it this way because i saw your Template ( ( ) where you made a IP for every instance

PatRock gravatar imagePatRock ( 2014-09-24 10:02:23 -0500 )edit

That's just because I wanted to be able to connect to them directly :). I hope you found that template otherwise useful...

larsks gravatar imagelarsks ( 2014-09-24 10:18:38 -0500 )edit

Yeah it helpes me a lot, I just have some other issues with the user_data. this gets only executed for the database server but not for the webserver. I tried to add the BashScript in the stacked template but this doesn't solve the problem :(

PatRock gravatar imagePatRock ( 2014-09-24 10:25:45 -0500 )edit

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

1 follower


Asked: 2014-09-23 04:45:33 -0500

Seen: 1,301 times

Last updated: Sep 24 '14