Hi Udara,

You can use Neutron to list existing ports and then get their uuids (it should 
be the port id).

PortApi api = neutronApi.getPortApi("region");
List<Port> ports = api.list().concat().toList();
ports.get(0).getId(); // Returns the uuid of the first port.

Let me know if this helps. Thanks!

________________________________
From: Udara Liyanage [[email protected]]
Sent: Friday, August 08, 2014 5:47 AM
To: [email protected]
Subject: Specify a network interface when assigning floating IP

Hi,

I was able to create an instance in Openstack specifying multiple networks. 
Instance has two network interfaces and each is assigned a private IP as  
expected. Additionally I was able to assign a floating IP successfully.
The floating IP is always assigned to the first interface eth0. What I want to 
know is how to specify a a network interface of my choice to which the floating 
IP is assigned.

I noticed that portUuid can be specified in nova NetworkInterface. But my issue 
is how to get the portUuId of the network interface I want?

Any help is appreciated.

--

Udara Liyanage
Software Engineer
WSO2, Inc.: http://wso2.com<http://wso2.com/>
lean. enterprise. middleware

web: http://udaraliyanage.wordpress.com
phone: +94 71 443 6897

Reply via email to