How to connect devstack with opendaylight private network to physical network with floating ips?
I have an AWS EC2 instance running on over a VPC subnet: 172.31.0.0/20 with Gateway at 172.31.0.1 which is relatively like a physical network inside the the EC2 instance.
I want to set up devstack such that after stacking with "networking-odl", I should be able to create VMs on ODL network and provide Floating IPs from my physical network directly.
That means, I would need to create 2 external networks: 1 for ODL, 1 for the physical network (this will also provide the Floating IPs).
Plus I should be able to create a router on openstack that can help me route traffic between the networks.
Assume that I want the ODL external network to be 172.24.5.0/24 with gateway at 172.24.5.0/24
Let FIXED network be 10.1.0.0/20
My current devstack local.conf:
[[local|localrc]]
# This will fetch the latest ODL snapshot
ODL_RELEASE=latest-snapshot
# Default is V2 driver, uncomment below line to use V1
#ODL_V2DRIVER=False
# Default is psuedo-port-binding-controller
#ODL_PORT_BINDING_CONTROLLER=
# Set here which ODL openstack service provider to use
# These are core ODL features
ODL_NETVIRT_KARAF_FEATURE=odl-neutron-service,odl-restconf-all,odl-aaa-authn,odl-dlux-core,odl-mdsal-apidocs
# Set DLUX Karaf features needed for the ODL GUI at http://<ODL_IP>:8181/index.html
ODL_NETVIRT_KARAF_FEATURE+=,odl-dluxapps-nodes,odl-dluxapps-topology,odl-dluxapps-yangui,odl-dluxapps-yangvisualizer
# Set L2 Karaf features needed for the ODL GUI at http://<ODL_IP>:8181/index.html
ODL_NETVIRT_KARAF_FEATURE+=,odl-l2switch-switch,odl-l2switch-switch-ui,odl-ovsdb-hwvtepsouthbound-ui,odl-ovsdb-southbound-impl-ui,odl-netvirt-ui
# Set OpenFlow Karaf features needed for the ODL GUI at http://<ODL_IP>:8181/index.html
ODL_NETVIRT_KARAF_FEATURE+=,odl-openflowplugin-flow-services-ui
# odl-netvirt-openstack is used for new netvirt
ODL_NETVIRT_KARAF_FEATURE+=,odl-netvirt-openstack
# optional feature neutron-logger to log changes of neutron yang models
ODL_NETVIRT_KARAF_FEATURE+=,odl-neutron-logger
# Switch to using the ODL's L3 implementation
ODL_L3=True
# Set Host IP here. It is externally reachable network, set
# below param to use ip from a different network
HOST_IP=$(ip route get 8.8.8.8 | awk '{print $NF; exit}')
# public network connectivity
Q_USE_PUBLIC_VETH=True
Q_PUBLIC_VETH_EX=veth-pub-ex
Q_PUBLIC_VETH_INT=veth-pub-int
ODL_PROVIDER_MAPPINGS=public:${Q_PUBLIC_VETH_INT}
# Enable debug logs for odl ovsdb
ODL_NETVIRT_DEBUG_LOGS=True
#Q_USE_DEBUG_COMMAND=True
DEST=/opt/stack/
# move DATA_DIR outside of DEST to keep DEST a bit cleaner
DATA_DIR=/opt/stack/data
ADMIN_PASSWORD=protected
MYSQL_PASSWORD=${ADMIN_PASSWORD}
RABBIT_PASSWORD=${ADMIN_PASSWORD}
SERVICE_PASSWORD=${ADMIN_PASSWORD}
SERVICE_TOKEN=supersecrettoken
enable_service dstat
enable_service g-api
enable_service g-reg
enable_service key
enable_service mysql
enable_service n-api
enable_service n-cond
enable_service n-cpu
enable_service n-crt
enable_service n-novnc
enable_service n-sch
enable_service placement-api
enable_service placement-client
enable_service q-dhcp
enable_service q-meta
enable_service q-svc
enable_service rabbit
enable_service tempest
# These can be enabled if storage is needed to do
# any feature or testing for integration
disable_service c-api
disable_service c-vol
disable_service c-sch
SKIP_EXERCISES=boot_from_volume,bundle,client-env,euca
# Screen console logs will capture service logs.
SYSLOG=False
LOGFILE=/opt/stack/new/devstacklog.txt
VERBOSE=True
FIXED_RANGE=10.1.0.0/20
FLOATING_RANGE=172.24.5.0/24
PUBLIC_NETWORK_GATEWAY=172.24.5.1
FIXED_NETWORK_SIZE=4096
VIRT_DRIVER=libvirt
export OS_NO_CACHE=1
# Additional repositories need to be cloned can be added here.
#LIBS_FROM_GIT=
# Enable MySql Logging
DATABASE_QUERY_LOGGING=True
# set this until all testing platforms have libvirt >= 1.2.11
# see bug #1501558
EBTABLES_RACE_FIX ...