Installing and Configuring network nodes
Vim/etc/sysctl.conf
Net.ipv4.ip_forward=1
Net.ipv4.conf.all.rp_filter=0
Net.ipv4.conf.default.rp_filter=0
Sysctl-p
Yum-y Install Openstack-neutron openstack-neutron-ml2 openstack-neutron-openvswitch
Vim/etc/neutron/neutron.conf
[DEFAULT]
...
Rpc_backend = Rabbit
Rabbit_host = 192.168.5.1
Rabbit_password = 666666
Auth_strategy = Keystone
Core_plugin = ML2
Service_plugins = Router
Allow_overlapping_ips = True
verbose = True
[Keystone_authtoken]
...
Auth_uri = http://192.168.5.1:5000/v2.0
Identity_uri = http://192.168.5.1:35357
Admin_tenant_name = Service
Admin_user = Neutron
Admin_password = 666666
Vim/etc/neutron/plugins/ml2/ml2_conf.ini
[ML2]
...
Type_drivers = Flat,gre
Tenant_network_types = GRE
Mechanism_drivers = Openvswitch
[Ml2_type_flat]
...
Flat_networks = External
[Ml2_type_gre]
...
Tunnel_id_ranges = 1:1000
[Securitygroup]
...
Enable_security_group = True
Enable_ipset = True
Firewall_driver = Neutron.agent.linux.iptables_firewall. Ovshybridiptablesfirewalldriver
[OvS]
...
LOCAL_IP = 192.168.8.1
enable_tunneling = True
Bridge_mappings = External:br-ex
[Agent]
...
Tunnel_types = GRE
Vim/etc/neutron/l3_agent.ini
[DEFAULT]
...
Interface_driver = Neutron.agent.linux.interface.OVSInterfaceDriver
Use_namespaces = True
External_network_bridge = Br-ex
Router_delete_namespaces = True
verbose = True
Vim/etc/neutron/dhcp_agent.ini
[DEFAULT]
...
Interface_driver = Neutron.agent.linux.interface.OVSInterfaceDriver
Dhcp_driver = NEUTRON.AGENT.LINUX.DHCP.DNSMASQ
Use_namespaces = True
Dhcp_delete_namespaces = True
verbose = True
Vim/etc/neutron/dhcp_agent.ini
[DEFAULT]
...
Dnsmasq_config_file =/etc/neutron/dnsmasq-neutron.conf
Vim/etc/neutron/dnsmasq-neutron.conf
dhcp-option-force=26,1454
Pkill DNSMASQ
Vim/etc/neutron/metadata_agent.ini
[DEFAULT]
...
Auth_url = http://192.168.5.1:5000/v2.0
Auth_region = Regionone
Admin_tenant_name = Service
Admin_user = Neutron
Admin_password = 666666
NOVA_METADATA_IP = 192.168.5.1
Metadata_proxy_shared_secret = Metadata_secret
verbose = True
operation on the control node
Vim/etc/nova/nova.conf
[Neutron]
...
Service_metadata_proxy = True
Metadata_proxy_shared_secret = Metadata_secret
Systemctl Restart Openstack-nova-api.service
Operating on a network node
Systemctl Enable Openvswitch.service
Systemctl Start Openvswitch.service
Ovs-vsctl ADD-BR Br-ex # # # #http://blog.csdn.net/signmem/article/details/19419517
# # # #http://www.aboutyun.com/thread-11777-1-1.html
Ovs-vsctl Add-port Br-ex Ext8
Ethtool-k Ext8 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
In the Control node installation
SOURCE admin-openrc.sh
Neutron agent-list
Operating on a compute node
Vim/etc/sysctl.conf
Net.ipv4.conf.all.rp_filter=0
Net.ipv4.conf.default.rp_filter=0
Sysctl-p
Yum-y Install OPENSTACK-NEUTRON-ML2 Openstack-neutron-openvswitch
Vim/etc/neutron/neutron.conf
Logout connection in [database]
[DEFAULT]
...
Rpc_backend = Rabbit
Rabbit_host = 192.168.5.1
Rabbit_password = 666666
Auth_strategy = Keystone
Core_plugin = ML2
Service_plugins = Router
Allow_overlapping_ips = True
verbose = True
[Keystone_authtoken]
...
Auth_uri = http://192.168.5.1:5000/v2.0
Identity_uri = http://192.168.5.1:35357
Admin_tenant_name = Service
Admin_user = Neutron
Admin_password = 666666
Vim/etc/neutron/plugins/ml2/ml2_conf.ini
[ML2]
...
Type_drivers = Flat,gre
Tenant_network_types = GRE
Mechanism_drivers = Openvswitch
[Ml2_type_gre]
...
Tunnel_id_ranges = 1:1000
[Securitygroup]
...
Enable_security_group = True
Enable_ipset = True
Firewall_driver = Neutron.agent.linux.iptables_firewall. Ovshybridiptablesfirewalldriver
[OvS]
...
Local_ip = 192.168.5.2 # # #计算节点ip
enable_tunneling = True
[Agent]
...
Tunnel_types = GRE
Systemctl Enable Openvswitch.service
Systemctl Start Openvswitch.service
Vim/etc/nova/nova.conf
[DEFAULT]
...
Network_api_class = Nova.network.neutronv2.api.API
Security_group_api = Neutron
Linuxnet_interface_driver = Nova.network.linux_net.LinuxOVSInterfaceDriver
Firewall_driver = Nova.virt.firewall.NoopFirewallDriver
[Neutron]
...
URL = http://192.168.5.1:9696
Auth_strategy = Keystone
Admin_auth_url = http://192.168.5.1:35357/v2.0
Admin_tenant_name = Service
Admin_username = Neutron
Admin_password = 666666
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 Restart Openstack-nova-compute.service
Systemctl Enable Neutron-openvswitch-agent.service
Systemctl Restart Neutron-openvswitch-agent.service
operation on the control node
SOURCE admin-openrc.sh
Neutron agent-list
SOURCE admin-openrc.sh
Neutron net-create ext-net--router:external True--provider:physical_network external--provider:network_type flat
Neutron subnet-create ext-net--name ext-subnet--allocation-pool start=floating_ip_start,end=floating_ip_end-- Disable-dhcp--gateway External_network_gateway External_network_cidr
Neutron subnet-create ext-net--name ext-subnet--allocation-pool start=172.16.1.100,end=172.16.1.200--disable-dhcp- -gateway 172.16.1.1 172.16.0.0/16
SOURCE demo-openrc.sh
Neutron net-create demo-net
Neutron subnet-create demo-net--name demo-subnet--gateway tenant_network_gateway TENANT_NETWORK_CIDR
Neutron subnet-create demo-net--name demo-subnet--gateway 192.168.2.1 192.168.2.0/24
Neutron router-create Demo-router
Neutron Router-interface-add demo-router demo-subnet
Added interface b1a894fd-aee8-475c-9262-4342afdc1b58 to Router Demo-router
Neutron Router-gateway-set demo-router ext-net
Set Gateway for Router Demo-router
Vim/etc/nova/nova.conf
[DEFAULT]
...
Network_api_class = Nova.network.api.API
Security_group_api = Nova
Systemctl Restart Openstack-nova-api.service openstack-nova-scheduler.service openstack-nova-conductor.service
In the COMPUTE node operation
Yum-y Install Openstack-nova-network Openstack-nova-api
Vim/etc/nova/nova.conf
[DEFAULT]
...
Network_api_class = Nova.network.api.API
Security_group_api = Nova
Firewall_driver = Nova.virt.libvirt.firewall.IptablesFirewallDriver
Network_manager = Nova.network.manager.FlatDHCPManager
Network_size = 254
Allow_same_net_traffic = False
Multi_host = True
Send_arp_for_ha = True
Share_dhcp_address = True
Force_dhcp_release = True
Flat_network_bridge = br100
Flat_interface = interface_name # # # #
Public_interface = interface_name # # # #
Systemctl Enable Openstack-nova-network.service Openstack-nova-metadata-api.service
Systemctl Start Openstack-nova-network.service Openstack-nova-metadata-api.service
operation on the control node
SOURCE admin-openrc.sh
Nova network-create demo-net--bridge br100--multi-host T--fixed-range-v4 NETWORK_CIDR
Nova network-create demo-net--bridge br100--multi-host T--fixed-range-v4 203.0.113.24/29
Nova Net-list
Add a Dashboard
operation on the control node
Yum-y Install Openstack-dashboard httpd mod_wsgi memcached python-memcached
Vim/etc/openstack-dashboard/local_settings
Openstack_host = "192.168.5.1"
allowed_hosts = [' * ']
CACHES = {
' Default ': {
' Backend ': ' Django.core.cache.backends.memcached.MemcachedCache ',
' Location ': ' 127.0.0.1:11211 ',
}
}
Time_zone = "Asia/shanghai"
Setsebool-p Httpd_can_network_connect on
Chown-r apache:apache/usr/share/openstack-dashboard/static
Systemctl Enable Httpd.service Memcached.service
Systemctl Start Httpd.service Memcached.service
Visit Http://192.168.5.1/dashboard
OpenStack Build Configurations