Skip to content

Commit

Permalink
Simplify NVP plugin configuration
Browse files Browse the repository at this point in the history
Fixes bug #1121605

This patch replacest the nvp_controller_connection configuration option
with a set of options more intutitive to user which also avoid
repetitions in ini files.

In order to simplify the configuration of the plugin, this patch also
removes named clusters. As the plugin supports a single cluster at
the moment, this can be simply specified in the [DEFAULT] configuration
section.

Also, this patch restrucures nvp_cluster.NvpCluster so that per-cluster
configuration options are not store anymore multiple times.

Change-Id: Id5f84220122d7c5f3239e3333cb772247d1ed05e
  • Loading branch information
armando-migliaccio committed Apr 25, 2013
1 parent 43d904b commit ea9aeb6
Show file tree
Hide file tree
Showing 15 changed files with 629 additions and 796 deletions.
146 changes: 83 additions & 63 deletions etc/quantum/plugins/nicira/nvp.ini
@@ -1,95 +1,115 @@
# #############################################################
# WARNINGS: The following deprecations have been made in the
# Havana release. Support for the options below will be removed
# in Ixxx.
#
# Section: [DEFAULT], Option: 'metadata_dhcp_host_route'
# Remarks: Use 'enable_isolated_metadata' in dhcp_agent.ini.
#
#
# Section: [CLUSTER:name], Option: 'nvp_controller_connection'
# Remarks: The configuration will allow the specification of
# a single cluster, therefore [CLUSTER:name] is no
# longer used. Use 'nvp_*', options, 'req_timeout',
# 'retries', etc. as indicated in the DEFAULT section.
# Support for multiple clusters will be added through
# an API extension.
# ##############################################################

[DEFAULT]
# User name for NVP controller
# nvp_user = admin

# Password for NVP controller
# nvp_password = admin

# Total time limit for a cluster request
# (including retries across different controllers)
# req_timeout = 30

# Time before aborting a request on an unresponsive controller
# http_timeout = 10

# Maximum number of times a particular request should be retried
# retries = 2

# Maximum number of times a redirect response should be followed
# redirects = 2

# Comma-separated list of NVP controller endpoints (<ip>:<port>). When port
# is omitted, 443 is assumed. This option MUST be specified, e.g.:
# nvp_controllers = xx.yy.zz.ww:443, aa.bb.cc.dd, ee.ff.gg.hh.ee:80

# UUID of the pre-existing default NVP Transport zone to be used for creating
# tunneled isolated "Quantum" networks. This option MUST be specified, e.g.:
# default_tz_uuid = 1e8e52cf-fa7f-46b0-a14a-f99835a9cb53

# (Optional) UUID of the cluster in NVP. It can be retrieved from NVP management
# console "admin" section.
# nvp_cluster_uuid = 615be8e4-82e9-4fd2-b4b3-fd141e51a5a7

# (Optional) UUID for the default l3 gateway service to use with this cluster.
# To be specified if planning to use logical routers with external gateways.
# default_l3_gw_service_uuid =

# (Optional) UUID for the default l2 gateway service to use with this cluster.
# To be specified for providing a predefined gateway tenant for connecting their networks.
# default_l2_gw_service_uuid =

# Name of the default interface name to be used on network-gateway. This value
# will be used for any device associated with a network gateway for which an
# interface name was not specified
# default_iface_name = breth0


[DATABASE]
# This line MUST be changed to actually run the plugin.
# Example:
# sql_connection = mysql://root:quantum@127.0.0.1:3306/nvp_quantum
# Replace 127.0.0.1 above with the IP address of the database used by the
# main quantum server. (Leave it as is if the database runs on this host.)
sql_connection = sqlite://
# Database reconnection retry times - in event connectivity is lost
# set to -1 implies an infinite retry count

# Number of reconnection attempts to the DB; Set to -1 to try indefinitely
# sql_max_retries = 10
# Database reconnection interval in seconds - if the initial connection to the
# database fails
reconnect_interval = 2

# Period between reconnection attempts to the DB
# reconnect_interval = 2

# Enable the use of eventlet's db_pool for MySQL. The flags sql_min_pool_size,
# sql_max_pool_size and sql_idle_timeout are relevant only if this is enabled.

# sql_dbpool_enable = False

# Minimum number of SQL connections to keep open in a pool
# sql_min_pool_size = 1

# Maximum number of SQL connections to keep open in a pool
# sql_max_pool_size = 5

# Timeout in seconds before idle sql connections are reaped
# sql_idle_timeout = 3600


[QUOTAS]
# number of network gateways allowed per tenant, -1 means unlimited
# quota_network_gateway = 5


[NVP]
# Maximum number of ports for each bridged logical switch
# max_lp_per_bridged_ls = 64

# Maximum number of ports for each overlay (stt, gre) logical switch
# max_lp_per_overlay_ls = 256

# Number of connects to each controller node.
# concurrent_connections = 3
# Name of the default cluster where requests should be sent if a nova zone id
# is not specified. If it is empty or reference a non-existent cluster
# the first cluster specified in this configuration file will be used
# default_cluster_name =
# If set to access_network this enables a dedicated connection to the
# metadata proxy for metadata server access via Quantum router. If set to
# dhcp_host_route this enables host route injection via the dhcp agent.

# Acceptable values for 'metadata_mode' are:
# - 'access_network': this enables a dedicated connection to the metadata
# proxy for metadata server access via Quantum router.
# - 'dhcp_host_route': this enables host route injection via the dhcp agent.
# This option is only useful if running on a host that does not support
# namespaces otherwise access_network should be used.
# metadata_mode = access_network

#[CLUSTER:example]
# This is uuid of the default NVP Transport zone that will be used for
# creating tunneled isolated "Quantum" networks. It needs to be created in
# NVP before starting Quantum with the nvp plugin.
# default_tz_uuid = 1e8e52cf-fa7f-46b0-a14a-f99835a9cb53

# Nova "zone" that maps to this NVP cluster. This should map to the
# node_availability_zone in your nova.conf for each nova cluster. Each nova
# cluster should have a unique node_availability_zone set.
# nova_zone_id = zone1 # (Optional)

# UUID of the cluster in NVP. This can be retrieved from NVP management
# console "admin" section.
# nvp_cluster_uuid = 615be8e4-82e9-4fd2-b4b3-fd141e51a5a7 # (Optional)

# UUID of the default layer 3 gateway service to use for this cluster
# This is optional, but should be filled if planning to use logical routers
# with external gateways
# default_l3_gw_service_uuid =

# UUID of the default layer 2 gateway service to use for this cluster
# This is optional. It should be filled for providing a predefined gateway
# tenant case use for connecting their networks.
# default_l2_gw_service_uuid =

# Name of the default interface name to be used on network-gateway.
# This value will be used for any device associated with a network
# gateway for which an interface name was not specified
# default_iface_name = breth0

# This parameter describes a connection to a single NVP controller. Format:
# <ip>:<port>:<user>:<pw>:<req_timeout>:<http_timeout>:<retries>:<redirects>
# <ip> is the ip address of the controller
# <port> is the port of the controller (default NVP port is 443)
# <user> is the user name for this controller
# <pw> is the user password.
# <req_timeout>: The total time limit on all operations for a controller
# request (including retries, redirects from unresponsive controllers).
# Default is 30.
# <http_timeout>: How long to wait before aborting an unresponsive controller
# (and allow for retries to another controller in the cluster).
# Default is 10.
# <retries>: the maximum number of times to retry a particular request
# Default is 2.
# <redirects>: the maximum number of times to follow a redirect response from a server.
# Default is 2.
# There must be at least one nvp_controller_connection per system or per cluster.
# nvp_controller_connection=10.0.1.2:443:admin:admin:30:10:2:2
# nvp_controller_connection=10.0.1.3:443:admin:admin:30:10:2:2
# nvp_controller_connection=10.0.1.4:443:admin:admin:30:10:2:2

0 comments on commit ea9aeb6

Please sign in to comment.