Ask Your Question
1

PackStack fails with "No tenant network is available for allocation"

asked 2014-09-28 05:23:01 -0500

david.ward gravatar image

updated 2014-09-28 08:08:28 -0500

Hey guys,

I'm having issues installing a simple 3 node openstack setup with packstack... During Installation using packstack with a pre-written answer file I get an error complaining about "Unable to create the network. No tenant network is available for allocation." The install dose however complete and I am able to see the users, tenants and endpoints but there are no networks available and I am unable to create any...

I have provided the error message, stack trace and info about my infrastructure with my answer file below in case anyone sees anything stupid...

Thank you

Error message

10.100.237.11_provision_demo.pp:                  [ ERROR ]                
Applying Puppet manifests                         [ ERROR ]

ERROR : Error appeared during Puppet run: 10.100.237.11_provision_demo.pp
Error: Execution of '/usr/bin/neutron net-create --format=shell --tenant_id=bc009dc96e2249bd974b553bf2d042af --router:external=True public' returned 1: 503-{u'NeutronError': {u'message': u'Unable to create the network. No tenant network is available for allocation.', u'type': u'NoNetworkAvailable', u'detail': u''}}
You will find full trace in log /var/tmp/packstack/20140927-153013-Iiltqc/manifests/10.100.237.11_provision_demo.pp.log
Please check log file /var/tmp/packstack/20140927-153013-Iiltqc/openstack-setup.log for more information

Stack Trace

Notice: Compiled catalog for uk00mpve00.lab.init-d.co.uk in environment production in 0.30 seconds
Notice: /Stage[main]/Main/Glance_image[cirros]/ensure: created
Error: Execution of '/usr/bin/neutron net-create --format=shell --tenant_id=bc009dc96e2249bd974b553bf2d042af --router:external=True public' returned 1: 503-{u'NeutronError': {u'message': u'Unable to create the network. No tenant network is available for allocation.', u'type': u'NoNetworkAvailable', u'detail': u''}}
Error: /Stage[main]/Main/Neutron_network[public]/ensure: change from absent to present failed: Execution of '/usr/bin/neutron net-create --format=shell --tenant_id=bc009dc96e2249bd974b553bf2d042af --router:external=True public' returned 1: 503-{u'NeutronError': {u'message': u'Unable to create the network. No tenant network is available for allocation.', u'type': u'NoNetworkAvailable', u'detail': u''}}
Notice: /Stage[main]/Main/Neutron_subnet[public_subnet]: Dependency Neutron_network[public] has failures: true
Warning: /Stage[main]/Main/Neutron_subnet[public_subnet]: Skipping because of failed dependencies
Notice: /Stage[main]/Main/Keystone_tenant[demo]/ensure: created
Notice: /Stage[main]/Main/Neutron_router[router1]: Dependency Neutron_network[public] has failures: true
Warning: /Stage[main]/Main/Neutron_router[router1]: Skipping because of failed dependencies
Error: Execution of '/usr/bin/neutron net-create --format=shell --tenant_id=cbd6b769052042c1aec67dfc7b34f307 private' returned 1: 503-{u'NeutronError': {u'message': u'Unable to create the network. No tenant network is available for allocation.', u'type': u'NoNetworkAvailable', u'detail': u''}}
Error: /Stage[main]/Main/Neutron_network[private]/ensure: change from absent to present failed: Execution of '/usr/bin/neutron net-create --format=shell --tenant_id=cbd6b769052042c1aec67dfc7b34f307 private' returned 1: 503-{u'NeutronError': {u'message': u'Unable to create the network. No tenant network is available for allocation.', u'type': u'NoNetworkAvailable', u'detail': u''}}
Notice: /Stage[main]/Main/Neutron_subnet[private_subnet]: Dependency Neutron_network[private] has failures: true
Warning: /Stage[main]/Main/Neutron_subnet[private_subnet]: Skipping because of failed dependencies
Notice: /Stage[main]/Main/Neutron_router_interface[router1:private_subnet]: Dependency Neutron_network[private] has failures: true
Notice: /Stage[main]/Main/Neutron_router_interface ...
(more)
edit retag flag offensive close merge delete

Comments

Please, post two files :-
lrwxrwxrwx. 1 root root 37 Jun 13 06:42 ml2_conf.ini -> /etc/neutron/plugins/ml2/ml2_conf.ini
lrwxrwxrwx. 1 root root 55 Jun 13 08:05 plugin.ini -> /etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini

dbaxps gravatar imagedbaxps ( 2014-09-28 07:57:09 -0500 )edit

Hey dbaxps,

I have posted the contents of "plugin.ini -> /etc/neutron/plugins/ml2/ml2_conf.ini"

in my /etc/neutron/ folder i do not have an ml2_conf.ini file but it seems the plugin.ini file links to the one you ml2_conf.ini links to. as for the ovs_neutron_plugin.ini dose not exist.

Thank you

david.ward gravatar imagedavid.ward ( 2014-09-28 08:11:27 -0500 )edit

I am curious if there are any errors in your neutron logs (/var/log/neutron/*.log) on your network host or on your controller relating to the failed net-create command.

larsks gravatar imagelarsks ( 2014-09-28 08:19:30 -0500 )edit

Hey Larsks, There is allot of noise due to the DEBUG flag being set but from a quick grep I cant see anything with net-create in it. I will search threw this more closely shortly. (currently reading links posted bellow)

david.ward gravatar imagedavid.ward ( 2014-09-28 08:38:08 -0500 )edit

2 answers

Sort by ยป oldest newest most voted
2

answered 2014-10-03 10:34:34 -0500

david.ward gravatar image

Made some progress thanks to information from dbaxps above... I'm putting this as an answer as it works but I still want to work out why it was not working with GRE...

This is by no means perfect but I ended up whipping the whole thing and re-creating the answer file from scratch. This time leaving it with the VXLAN method rather then the GRE... Im not sure what the benefits/limitations of this is but at least it works for now... The only change I had to make after installing from the answer file below was to add the external interface to the Open vSwitch:

# ovs-vsctl add-port br-ex INTERFACE_NAME

The working answer file

[general]

# Path to a Public key to install on servers. If a usable key has not
# been installed on the remote servers the user will be prompted for a
# password and this key will be installed so the password will not be
# required again
CONFIG_SSH_KEY=/root/.ssh/id_rsa.pub

# Set to 'y' if you would like Packstack to install MySQL
CONFIG_MYSQL_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack Image
# Service (Glance)
CONFIG_GLANCE_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack Block
# Storage (Cinder)
CONFIG_CINDER_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack Compute
# (Nova)
CONFIG_NOVA_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack
# Networking (Neutron). Otherwise Nova Network will be used.
CONFIG_NEUTRON_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack
# Dashboard (Horizon)
CONFIG_HORIZON_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack Object
# Storage (Swift)
CONFIG_SWIFT_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack
# Metering (Ceilometer)
CONFIG_CEILOMETER_INSTALL=y

# Set to 'y' if you would like Packstack to install OpenStack
# Orchestration (Heat)
CONFIG_HEAT_INSTALL=n

# Set to 'y' if you would like Packstack to install the OpenStack
# Client packages. An admin "rc" file will also be installed
CONFIG_CLIENT_INSTALL=y

# Comma separated list of NTP servers. Leave plain if Packstack
# should not install ntpd on instances.
CONFIG_NTP_SERVERS=

# Set to 'y' if you would like Packstack to install Nagios to monitor
# OpenStack hosts
CONFIG_NAGIOS_INSTALL=n

# Comma separated list of servers to be excluded from installation in
# case you are running Packstack the second time with the same answer
# file and don't want Packstack to touch these servers. Leave plain if
# you don't need to exclude any server.
EXCLUDE_SERVERS=

# Set to 'y' if you want to run OpenStack services in debug mode.
# Otherwise set to 'n'.
CONFIG_DEBUG_MODE=y

# The IP address of the server on which to install OpenStack services
# specific to controller role such as API servers, Horizon, etc.
CONFIG_CONTROLLER_HOST=10.100.237.11

# The list of IP addresses of the server on which to install the Nova
# compute service
CONFIG_COMPUTE_HOSTS=10.100.237.31

# The list of IP addresses of the server on which to install the
# network service such as Nova network or Neutron
CONFIG_NETWORK_HOSTS=10.100 ...
(more)
edit flag offensive delete link more

Comments

1

Congratulations ! Just for fun try it (VXLAN) on CentOS 7, you will be surprised.
View also VXLAN advantages http://whatis.techtarget.com/definiti...
How GRE works ? https://www.hastexo.com/system/files/...

dbaxps gravatar imagedbaxps ( 2014-10-03 11:22:24 -0500 )edit

I'll give it a go! I'm going to be testing this config several times with different number/specs of nodes so will see what CentOS7 dose as well. Thank you for your help!! I will read up on this VXLAN stuff (thanks for the link) as well as work out why GRE failed! its bugging me! will report back

david.ward gravatar imagedavid.ward ( 2014-10-03 11:58:20 -0500 )edit
1

answered 2014-09-28 08:10:45 -0500

dbaxps gravatar image

updated 2014-09-30 11:23:42 -0500

Answer file is incorrect . Please view
1. http://bderzhavets.blogspot.com/2014/...
2. https://kashyapc.fedorapeople.org/vir...

CONFIG_NEUTRON_L2_PLUGIN=ml2
CONFIG_NEUTRON_METADATA_HOSTS=192.168.1.127
CONFIG_NEUTRON_METADATA_PW=227f7bbc8b6f4f74
############################################
CONFIG_NEUTRON_ML2_TYPE_DRIVERS=gre
CONFIG_NEUTRON_ML2_TENANT_NETWORK_TYPES=gre
############################################
CONFIG_NEUTRON_ML2_MECHANISM_DRIVERS=openvswitch
CONFIG_NEUTRON_ML2_FLAT_NETWORKS=*
CONFIG_NEUTRON_ML2_VLAN_RANGES=
CONFIG_NEUTRON_ML2_TUNNEL_ID_RANGES=
CONFIG_NEUTRON_ML2_VXLAN_GROUP=
CONFIG_NEUTRON_ML2_VNI_RANGES=
CONFIG_NEUTRON_L2_AGENT=openvswitch
CONFIG_NEUTRON_LB_TENANT_NETWORK_TYPE=local
CONFIG_NEUTRON_LB_VLAN_RANGES=
CONFIG_NEUTRON_LB_INTERFACE_MAPPINGS=
#########################################
CONFIG_NEUTRON_OVS_TENANT_NETWORK_TYPE=gre
CONFIG_NEUTRON_OVS_VLAN_RANGES=physnet1
CONFIG_NEUTRON_OVS_BRIDGE_MAPPINGS=
CONFIG_NEUTRON_OVS_BRIDGE_IFACES=
CONFIG_NEUTRON_OVS_TUNNEL_RANGES=1:1000
CONFIG_NEUTRON_OVS_TUNNEL_IF=p4p1
########################################

2. Plugin.ini and ml2_conf.ini are similar

[root@icehouse1 neutron(keystone_admin)]# ls -l
total 108
-rw-r--r--. 1 root root      193 Jun 13 05:19 api-paste.ini
-rw-r-----. 1 root neutron  3902 Jun 13 08:31 dhcp_agent.ini
-rw-r--r--. 1 root root       73 Jun 13 08:32 dnsmasq.conf
-rw-r-----. 1 root neutron   109 Aug  8 02:55 fwaas_driver.ini
-rw-r-----. 1 root neutron  3431 Jun 13 05:19 l3_agent.ini
-rw-r-----. 1 root neutron  1400 Aug  8 02:56 lbaas_agent.ini
-rw-r-----. 1 root neutron  1481 Jun 13 07:52 metadata_agent.ini
-rw-r-----. 1 root neutron  1693 Aug  8 02:56 metadata_agent.ini.rpmnew
-rw-r--r--. 1 root root      324 Jun 13 05:36 metadata_agent.out
lrwxrwxrwx. 1 root root       37 Jun 13 06:42 ml2_conf.ini -> /etc/neutron/plugins/ml2/ml2_conf.ini
-rw-r-----. 1 root neutron 19089 Jun 13 06:03 neutron.conf
-rw-r-----. 1 root neutron 17513 Jul  2 15:05 neutron.conf.rpmnew
-rw-r--r--. 1 root root     1675 Jun 14 20:04 neutron.sample
lrwxrwxrwx. 1 root root       55 Jun 13 08:05 plugin.ini -> /etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini
drwxr-xr-x. 4 root root     4096 Aug 11 15:27 plugins
-rw-r--r--. 1 root root      437 Jun 14 20:04 plugin.sample
-rw-r-----. 1 root neutron  6148 Aug  8 02:56 policy.json
-rw-r--r--. 1 root root       79 Aug 11 15:27 release
-rw-r--r--. 1 root root     1216 Aug  8 02:56 rootwrap.conf

[root@icehouse1 neutron(keystone_admin)]# cat ml2_conf.ini | grep -v ^# | grep -v ^#
[ml2]
type_drivers = gre
tenant_network_types = gre
mechanism_drivers = openvswitch
[ml2_type_flat]
[ml2_type_vlan]
[ml2_type_gre]
tunnel_id_ranges = 1:1000
[ml2_type_vxlan]
[securitygroup]
firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver
enable_security_group = True
[ovs]
local_ip = 192.168.1.127
[agent]
tunnel_types = gre
root_helper = sudo /usr/bin/neutron-rootwrap /etc/neutron/rootwrap.conf

[root@icehouse1 neutron(keystone_admin)]# cat plugin.ini | grep -v ^# | grep -v ^#
[ml2]
type_drivers = gre
tenant_network_types = gre
mechanism_drivers = openvswitch
[ml2_type_flat]
[ml2_type_vlan]
[ml2_type_gre]
tunnel_id_ranges = 1:1000
[ml2_type_vxlan]
[securitygroup]
firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver
enable_security_group = True
[ovs]
local_ip = 192.168.1.127
[agent]
tunnel_types = gre
root_helper = sudo /usr/bin/neutron-rootwrap /etc/neutron/rootwrap.conf

Reproduced just now with the same error at the end packstack running. Workaround with ml2_conf && plugin.ini still works as 3 months ago. I also had to update table ml2_gre_endpoints to place there correct IP addresses. Packstack doesn't generate correct plugin.ini

[root@icehouse1 ~(keystone_admin)]# openstack-status
== Nova services ==
openstack-nova-api:                     active
openstack-nova-cert:                    active
openstack-nova-compute:                 inactive  (disabled on boot)
openstack-nova-network:                 inactive  (disabled on boot)
openstack-nova-scheduler:               active
openstack-nova-volume:                  inactive  (disabled on boot)
openstack-nova-conductor:               active
== Glance services ==
openstack-glance-api:                   active
openstack-glance-registry:              active
== Keystone service ==
openstack-keystone:                     active
== Horizon service ==
openstack-dashboard:                    active
== neutron services ==
neutron-server:                         active
neutron-dhcp-agent:                     active
neutron-l3-agent:                       active
neutron-metadata-agent:                 active
neutron-lbaas-agent:                    inactive  (disabled on boot)
neutron-openvswitch-agent:              active
neutron-linuxbridge-agent ...
(more)
edit flag offensive delete link more

Comments

I have corrected my answers file in relation to what you have posted and will run it on a fresh install shortly.

I will post back with my results

david.ward gravatar imagedavid.ward ( 2014-09-28 09:58:40 -0500 )edit

Hey guys, I have the same response after changes...

I adjusted the below, please let me know if i completely missed what you were trying to tell me...

CONFIG_NEUTRON_OVS_VLAN_RANGES=physnet1 CONFIG_NOVA_NETWORK_VLAN_START=100 CONFIG_NEUTRON_OVS_TUNNEL_RANGES=1:1000

david.ward gravatar imagedavid.ward ( 2014-09-28 23:34:00 -0500 )edit

I also changed these IP ranges due to the links you showed leaving them as default as well... < CONFIG_PROVISION_DEMO_FLOATRANGE=10.100.138.0/24

CONFIG_PROVISION_DEMO_FLOATRANGE=172.24.4.224/28 < CONFIG_NOVA_NETWORK_FLOATRANGE=10.100.138.0/24 CONFIG_NOVA_NETWORK_FLOATRANGE=10.3.4.0/22

david.ward gravatar imagedavid.ward ( 2014-09-28 23:35:54 -0500 )edit

Please, try to add plugin.ini and ml2_conf.ini on Neutron node && Compute as advised . Restart boxes and see would you able to work or no. Setup has been tested on Two Node Clusters several times OK, in particular, by Kashyap Chamarthy ( RH Software ingineer).

dbaxps gravatar imagedbaxps ( 2014-09-29 04:01:54 -0500 )edit

You might get this error during packstack, because plugin.ini -> /etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini has been created manually exactly the same as ml2_conf.ini after packstack completion.

dbaxps gravatar imagedbaxps ( 2014-09-29 05:08:58 -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

Stats

Asked: 2014-09-28 05:23:01 -0500

Seen: 4,751 times

Last updated: Oct 03 '14