OpenStack Controller HA test environment build record (11)--Configure Neutron (network node)

Source: Internet
Author: User
Tags openvswitch

Configure kernel Parameters on network nodes:
Vi/etc/sysctl.conf
Net.ipv4.ip_forward=1
Net.ipv4.conf.all.rp_filter=0
Net.ipv4.conf.default.rp_filter=0

The kernel parameter takes effect immediately on the network node:
Sysctl-p


Install the software on the network node:
Yum install-y Openstack-neutron openstack-neutron-ml2 openstack-neutron-openvswitch


To modify a configuration file on a network node:
Openstack-config--set/etc/neutron/neutron.conf DEFAULT rpc_backend Rabbit
Openstack-config--set/etc/neutron/neutron.conf DEFAULT Rabbit_password 123456
Openstack-config--set/etc/neutron/neutron.conf DEFAULT rabbit_hosts Controller1:5672,controller2:5672,controller3 : 5672
Openstack-config--set/etc/neutron/neutron.conf DEFAULT rabbit_retry_interval 1
Openstack-config--set/etc/neutron/neutron.conf DEFAULT Rabbit_retry_backoff 2
Openstack-config--set/etc/neutron/neutron.conf DEFAULT rabbit_max_retries 0
Openstack-config--set/etc/neutron/neutron.conf DEFAULT rabbit_durable_queues True
Openstack-config--set/etc/neutron/neutron.conf DEFAULT rabbit_ha_queues True

Openstack-config--set/etc/neutron/neutron.conf DEFAULT auth_strategy Keystone
Openstack-config--set/etc/neutron/neutron.conf Keystone_authtoken Auth_uri http://myvip:5000/v2.0
Openstack-config--set/etc/neutron/neutron.conf Keystone_authtoken Identity_uri http://myvip:35357
Openstack-config--set/etc/neutron/neutron.conf keystone_authtoken Admin_user Neutron
Openstack-config--set/etc/neutron/neutron.conf keystone_authtoken admin_tenant_name Service
Openstack-config--set/etc/neutron/neutron.conf Keystone_authtoken Admin_password 123456
Openstack-config--set/etc/neutron/neutron.conf DEFAULT Core_plugin ML2
Openstack-config--set/etc/neutron/neutron.conf DEFAULT service_plugins Router
Openstack-config--set/etc/neutron/neutron.conf DEFAULT allow_overlapping_ips True
Openstack-config--set/etc/neutron/neutron.conf DEFAULT verbose True

Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini ML2 type_drivers flat,gre
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini ML2 tenant_network_types GRE
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini ML2 mechanism_drivers openvswitch
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini Ml2_type_flat flat_networks = External
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini Ml2_type_gre tunnel_id_ranges 1:1000
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini securitygroup Enable_security_group True
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini securitygroup Enable_ipset True
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini Securitygroup Firewall_driver Neutron.agent.linux.iptables_firewall. Ovshybridiptablesfirewalldriver
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini OvS Local_ip10.0.0.21
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini OvS bridge_mappings External:br-ex
Openstack-config--set/etc/neutron/plugins/ml2/ml2_conf.ini Agent Tunnel_types GRE

Openstack-config--set/etc/neutron/l3_agent.ini DEFAULT Interface_driver Neutron.agent.linux.interface.OVSInterfaceDriver
Openstack-config--set/etc/neutron/l3_agent.ini DEFAULT use_namespaces True
Openstack-config--set/etc/neutron/l3_agent.ini DEFAULT External_network_bridge Br-ex
Openstack-config--set/etc/neutron/l3_agent.ini DEFAULT router_delete_namespaces True
Openstack-config--set/etc/neutron/l3_agent.ini DEFAULT verbose True

Openstack-config--set/etc/neutron/dhcp_agent.ini DEFAULT interface_driver = Neutron.agent.linux.interface.OVSInterfaceDriver
Openstack-config--set/etc/neutron/dhcp_agent.ini DEFAULT dhcp_driver neutron.agent.linux.dhcp.Dnsmasq
Openstack-config--set/etc/neutron/dhcp_agent.ini DEFAULT dhcp_delete_namespaces True
Openstack-config--set/etc/neutron/dhcp_agent.ini DEFAULT use_namespaces True
Openstack-config--set/etc/neutron/dhcp_agent.ini DEFAULT verbose True


Openstack-config--set/etc/neutron/dhcp_agent.ini DEFAULT dnsmasq_config_file/etc/neutron/dnsmasq-neutron.conf
Vi/etc/neutron/dnsmasq-neutron.conf
dhcp-option-force=26,1454
Pkill DNSMASQ


Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT Auth_url http://myvip:5000/v2.0
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT auth_region = Regionone
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT Project_Name service
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT Username Neutron
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT Password 123456
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT nova_metadata_ip MYVIP
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT Metadata_proxy_shared_secret METADATA_SECRET
Openstack-config--set/etc/neutron/metadata_agent.ini DEFAULT verbose True


Modify the configuration file in the control node:
Openstack-config--set/etc/nova/nova.conf Neutronservice_metadata_proxy True
Openstack-config--set/etc/nova/nova.conf Neutronmetadata_proxy_shared_secret METADATA_SECRET

Restart the Control node Nova service:
Systemctl Restart Openstack-nova-api.service


On the network node:
Systemctl Enable Openvswitch.service
Systemctl Start Openvswitch.service


Ovs-vsctl ADD-BR Br-ex
Ovs-vsctl Add-port Br-ex interface_name
Ethtool-k Interface_name Gro off


Ln-s/etc/neutron/plugins/ml2/ml2_conf.ini/etc/neutron/plugin.ini
Cp/usr/lib/systemd/system/neutron-openvswitch-agent.service \
/usr/lib/systemd/system/neutron-openvswitch-agent.service.orig
Sed-i ' S,plugins/openvswitch/ovs_neutron_plugin.ini,plugin.ini,g ' \
/usr/lib/systemd/system/neutron-openvswitch-agent.service

Systemctl Enable Neutron-openvswitch-agent.service Neutron-l3-agent.service Neutron-dhcp-agent.service Neutron-metadata-agent.service Neutron-ovs-cleanup.service
Systemctl Start Neutron-openvswitch-agent.service neutron-l3-agent.service neutron-dhcp-agent.service Neutron-metadata-agent.service


Verify:
SOURCE admin-openrc.sh
Neutron agent-list

OpenStack Controller HA test environment build record (11)--Configure Neutron (network node)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.