XenAPI: support XenAPI in nova configuration

When using XenAPI as the virt driver, we need some XenAPI
specific configure options. This commit is to ensure nova's
configuration can be generated correctly for XenAPI. It
includes the folowing changes:
* Add XenAPI as one of the valid options for nova_compute_virt_type;
* Configure some options when XenAPI is chosen as the virt type.

This commit does NOT include the host and [vnc] configurations which
will be covered by a following commit.

References:
* XenServer (and other XAPI based Xen variants):
  https://docs.openstack.org/nova/pike/admin/configuration/hypervisor-xen-api.html
* XenCenter HIMN plugin (adding HIMN network which is used by XenAPI driver to
  communicate with XenServer):
  https://github.com/citrix-openstack/xencenter-himn-plugin
* nova configuration options:
  https://docs.openstack.org/nova/pike/configuration/config.html

Change-Id: Id34d247ab78976627f8e70685f27470b254cd418
blueprint: xenserver-support
This commit is contained in:
Jianghua Wang 2017-12-05 06:08:02 +00:00
parent 50a30f73c8
commit 0c8a033a03
4 changed files with 35 additions and 2 deletions

View File

@ -611,7 +611,7 @@ computes_need_external_bridge: "{{ enable_neutron_dvr | bool or enable_neutron_p
#######################
nova_backend_ceph: "{{ enable_ceph }}"
nova_backend: "{{ 'rbd' if nova_backend_ceph | bool else 'default' }}"
# Valid options are [ kvm, qemu, vmware ]
# Valid options are [ kvm, qemu, vmware, xenapi ]
nova_compute_virt_type: "kvm"
#######################
@ -706,3 +706,12 @@ enable_opendaylight_legacy_netvirt_conntrack: "no"
opendaylight_port_binding_type: "pseudo-agentdb-binding"
opendaylight_features: "odl-mdsal-apidocs,odl-netvirt-openstack"
opendaylight_allowed_network_types: '"flat", "vlan", "vxlan"'
#######################################
# XenAPI - Support XenAPI for XenServer
#######################################
# XenAPI driver use HIMN(Host Internal Management Network)
# to communicate with XenServer host.
xenserver_himn_ip: "169.254.0.1"
xenserver_username: "root"
xenserver_connect_protocol: "https"

View File

@ -33,6 +33,8 @@ host = {{ ansible_hostname }}_{{ service_name }}
compute_driver = fake.FakeDriver
{% elif nova_compute_virt_type == 'vmware' %}
compute_driver = vmwareapi.VMwareVCDriver
{% elif nova_compute_virt_type == 'xenapi' %}
compute_driver = xenapi.XenAPIDriver
{% else %}
compute_driver = libvirt.LibvirtDriver
{% endif %}
@ -262,3 +264,11 @@ connection_string = elasticsearch://{{ elasticsearch_address }}:{{ elasticsearch
[barbican]
auth_endpoint = {{ internal_protocol }}://{{ kolla_internal_fqdn }}:{{ keystone_public_port }}
{% endif %}
{% if nova_compute_virt_type == "xenapi" %}
[xenserver]
ovs_integration_bridge = br-int
connection_password = {{ xenserver_password }}
connection_username = {{ xenserver_username }}
connection_url = {{ xenserver_connect_protocol }}://{{ xenserver_himn_ip }}
{% endif %}

View File

@ -328,7 +328,7 @@ kolla_internal_vip_address: "10.10.10.254"
########################
#nova_backend_ceph: "{{ enable_ceph }}"
# Valid options are [ qemu, kvm, vmware ]
# Valid options are [ qemu, kvm, vmware, xenapi ]
#nova_compute_virt_type: "kvm"
# The number of fake driver per compute node
@ -401,3 +401,12 @@ tempest_floating_network_name:
#vmware_datastore_name:
#vmware_vcenter_name:
#vmware_vcenter_cluster_name:
#######################################
# XenAPI - Support XenAPI for XenServer
#######################################
# XenAPI driver use HIMN(Host Internal Management Network)
# to communicate with XenServer host.
#xenserver_himn_ip:
#xenserver_username:
#xenserver_connect_protocol:

View File

@ -221,3 +221,8 @@ etcd_cluster_token:
# redis options
####################
redis_master_password:
################
# XenAPI options
################
xenserver_password: