在ubuntu14.04上安装openstack mitaka
最近在工作环境安装部署了juno版本,在GE口测试网络性能不太满意,发现mitaka版本支持ovs-dpdk,于是抽时间安装实验一番。
参考官网的安装文档,先准备将mitaka版本安装好再配置ovs。
实验环境:
1、vmware 12
2、controller节点:2vcpus,1G ram,20G disk,2 网卡
compute1节点:4vcpus,2G ram,20G disk,2 网卡
简便快速方式:在vm安装一个ubuntu14.04的server版本的虚拟机,配置好ssh,然后克隆出控制节点和计算节点。
网络布局:
存储节点暂时不安装,等需要研究需要再安装。
管理网络:
controller eth1配置10.0.0.11,compute1 eth1 配置10.0.0.21
提供外部网络的网卡配置,都如下:
在/etc/network/interfaces下添加
auto eth2
iface eth2 inet manual
up ip link set dev $IFACE up
down ip link set dev $IFACE down
每个节点都执行如下操作:
安装ntp:
apt-get install chrony
更新源
apt-get install software-properties-common
add-apt-repository cloud-archive:mitaka
apt-get update && apt-get dist-upgrade
apt-get install python-openstackclient
在控制节点:
1.安装数据库
apt-get install mariadb-server python-pymysql
/etc/mysql/conf.d/openstack.cnf
[mysqld]
bind-address = 10.0.0.11
default-storage-engine = innodb
innodb_file_per_table
max_connections = 4096
collation-server = utf8_general_ci
character-set-server = utf8
service mysql restart
mysql_secure_installation
2.安装消息队列
apt-get install rabbitmq-server
rabbitmqctl add_user openstack 123456
rabbitmqctl set_permissions openstack ".*" ".*" ".*"
3.安装memcache
apt-get install memcached python-memcache
/etc/memcached.conf
-l 10.0.0.11
service memcached restart
接下来安装keystone:
控制节点:
mysql -u root -p
CREATE DATABASE keystone;
GRANT ALL PRIVILEGES ON keystone.* TO 'keystone'@'localhost' \
IDENTIFIED BY '123456';
GRANT ALL PRIVILEGES ON keystone.* TO 'keystone'@'%' \
IDENTIFIED BY '123456';
trait@controller:~$ openssl rand -hex 10
4200b5b54aa051fd9234
echo "manual" > /etc/init/keystone.override
apt-get install keystone apache2 libapache2-mod-wsgi
vim /etc/keystone/keystone.conf
[DEFAULT]
admin_token = 4200b5b54aa051fd9234
[database]
connection = mysql+pymysql://keystone:123456@controller/keystone
[token]
provider = fernet
su -s /bin/sh -c "keystone-manage db_sync" keystone
keystone-manage fernet_setup --keystone-user keystone --keystone-group keystone
vim /etc/apache2/apache2.conf 添加如下内容:
ServerName controller
vim /etc/apache2/sites-available/wsgi-keystone.conf 添加如下内容:
Listen 5000
Listen 35357
<VirtualHost *:5000>
WSGIDaemonProcess keystone-public processes=5 threads=1 user=keystone group=keystone display-name=%{GROUP}
WSGIProcessGroup keystone-public
WSGIScriptAlias / /usr/bin/keystone-wsgi-public
WSGIApplicationGroup %{GLOBAL}
WSGIPassAuthorization On
ErrorLogFormat "%{cu}t %M"
ErrorLog /var/log/apache2/keystone.log
CustomLog /var/log/apache2/keystone_access.log combined
<Directory /usr/bin>
Require all granted
</Directory>
</VirtualHost>
<VirtualHost *:35357>
WSGIDaemonProcess keystone-admin processes=5 threads=1 user=keystone group=keystone display-name=%{GROUP}
WSGIProcessGroup keystone-admin
WSGIScriptAlias / /usr/bin/keystone-wsgi-admin
WSGIApplicationGroup %{GLOBAL}
WSGIPassAuthorization On
ErrorLogFormat "%{cu}t %M"
ErrorLog /var/log/apache2/keystone.log
CustomLog /var/log/apache2/keystone_access.log combined
<Directory /usr/bin>
Require all granted
</Directory>
</VirtualHost>
ln -s /etc/apache2/sites-available/wsgi-keystone.conf /etc/apache2/sites-enabled
service apache2 restart
rm -f /var/lib/keystone/keystone.db
创建服务:
trait@controller:~$ export OS_TOKEN=4200b5b54aa051fd9234
trait@controller:~$ export OS_URL=http://controller:35357/v3
trait@controller:~$ export OS_IDENTITY_API_VERSION=3
trait@controller:~$ openstack service create --name keystone --description "OpenStack Identity" identity
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | OpenStack Identity |
| enabled | True |
| id | 370765e770414ccbafa044d67e6b2997 |
| name | keystone |
| type | identity |
+-------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne identity public http://controller:5000/v3
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | b56b1648d5974882b7a2d06469a89d1c |
| interface | public |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 370765e770414ccbafa044d67e6b2997 |
| service_name | keystone |
| service_type | identity |
| url | http://controller:5000/v3 |
+--------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne identity admin http://controller:35357/v3
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | 90e1e646f9114534bfee2049410065f7 |
| interface | admin |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 370765e770414ccbafa044d67e6b2997 |
| service_name | keystone |
| service_type | identity |
| url | http://controller:35357/v3 |
+--------------+----------------------------------+
创建域,项目,用户
trait@controller:~$ openstack domain create --description "Default Domain" default
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | Default Domain |
| enabled | True |
| id | ba70a48abe5941179904fee58d20ab66 |
| name | default |
+-------------+----------------------------------+
trait@controller:~$ openstack project create --domain default --description "Admin Project" admin
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | Admin Project |
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | 5648f07e1ded400caba4e0ff25f9e2a8 |
| is_domain | False |
| name | admin |
| parent_id | ba70a48abe5941179904fee58d20ab66 |
+-------------+----------------------------------+
trait@controller:~$ openstack user create --domain default --password-prompt admin
User Password:
Repeat User Password:
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | 4b370d2454d5461b8cbe2fea56096b5a |
| name | admin |
+-----------+----------------------------------+
trait@controller:~$ openstack role create admin
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | None |
| id | 7e9491f8a9f2438fbc60f7f58ef6c100 |
| name | admin |
+-----------+----------------------------------+
trait@controller:~$ openstack role add --project admin --user admin admin
trait@controller:~$
trait@controller:~$ openstack project create --domain default --description "Service Project" service
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | Service Project |
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | 8042914fb1ee454db0d7701c408820cf |
| is_domain | False |
| name | service |
| parent_id | ba70a48abe5941179904fee58d20ab66 |
+-------------+----------------------------------+
trait@controller:~$ openstack project create --domain default --description "Demo Project" demo
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | Demo Project |
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | 1ac8bc179dd54ef8b7d8213174dee9aa |
| is_domain | False |
| name | demo |
| parent_id | ba70a48abe5941179904fee58d20ab66 |
+-------------+----------------------------------+
trait@controller:~$ openstack user create --domain default --password-prompt demo
User Password:
Repeat User Password:
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | 23c004d3fe2942c4922d7c27dc71c7a8 |
| name | demo |
+-----------+----------------------------------+
trait@controller:~$ openstack role create user
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | None |
| id | c714aa17116b4e7985b15518f81127b9 |
| name | user |
+-----------+----------------------------------+
trait@controller:~$ openstack role add --project demo --user demo user
trait@controller:~$
OK 到这里keystone安装完成,第一次安装的话,可以按照官网的验证方法验证一下。
创建admin-openrc脚本:
export OS_PROJECT_DOMAIN_NAME=default
export OS_USER_DOMAIN_NAME=default
export OS_PROJECT_NAME=admin
export OS_USERNAME=admin
export OS_PASSWORD=123456
export OS_AUTH_URL=http://controller:35357/v3
export OS_IDENTITY_API_VERSION=3
export OS_IMAGE_API_VERSION=2
export OS_PROJECT_DOMAIN_NAME=default
export OS_USER_DOMAIN_NAME=default
export OS_PROJECT_NAME=demo
export OS_USERNAME=demo
export OS_PASSWORD=123456
export OS_AUTH_URL=http://controller:5000/v3
export OS_IDENTITY_API_VERSION=3
export OS_IMAGE_API_VERSION=2
创建demo-openrc脚本:
接下来,开始安装glance:
mysql -u root -p
CREATE DATABASE glance;
GRANT ALL PRIVILEGES ON glance.* TO 'glance'@'localhost' \
IDENTIFIED BY '123456';
GRANT ALL PRIVILEGES ON glance.* TO 'glance'@'%' \
IDENTIFIED BY '123456';
trait@controller:~$ . admin-openrc
trait@controller:~$ openstack user create --domain default --password-prompt glance
User Password:
Repeat User Password:
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | e635a5acc68a4a0e966ecdb6509b07a9 |
| name | glance |
+-----------+----------------------------------+
trait@controller:~$ openstack role add --project service --user glance admin
trait@controller:~$ openstack service create --name glance --description "OpenStack Image" image
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | OpenStack Image |
| enabled | True |
| id | 29dc2fd78f5b41d79ef7738f9e5530c1 |
| name | glance |
| type | image |
+-------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne image public http://controller:9292
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | 3d07b7ee32b543868c049ecf6ff5b82b |
| interface | public |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 29dc2fd78f5b41d79ef7738f9e5530c1 |
| service_name | glance |
| service_type | image |
| url | http://controller:9292 |
+--------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne image internal http://controller:9292
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | 98ee7d04e288469d80762f6e2860920e |
| interface | internal |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 29dc2fd78f5b41d79ef7738f9e5530c1 |
| service_name | glance |
| service_type | image |
| url | http://controller:9292 |
+--------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne image admin http://controller:9292
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | 33d3f1bc8cad44b69c846026e2ed0fdb |
| interface | admin |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 29dc2fd78f5b41d79ef7738f9e5530c1 |
| service_name | glance |
| service_type | image |
| url | http://controller:9292 |
+--------------+----------------------------------+
apt-get install glance
在/etc/glance/glance-api.conf下添加,keystone_authtoken里只使用如下的内容。
[database]
connection = mysql+pymysql://glance:123456@controller/glance
[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = glance
password = 123456
[paste_deploy]
flavor = keystone
[glance_store]
stores = file,http
default_store = file
filesystem_store_datadir = /var/lib/glance/images/
在/etc/glance/glance-registry.conf添加如下内容:
[database]
connection = mysql+pymysql://glance:123456@controller/glance
[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = glance
password = 123456
[paste_deploy]
flavor = keystone
OK 可以 grep -v "^#" /etc/glance/glance-api.conf | grep -v "^$" 和 grep -v "^#" /etc/glance/glance-registry.conf | grep -v "^$" 检查一下是否正确。
su -s /bin/sh -c "glance-manage db_sync" glance
service glance-registry restart
service glance-api restart
glance 安装完成,可以上传cirros-0.3.4-x86_64-disk.img也可以自己制作镜像,后面我会再写一篇博客介绍一种比较方便的制作openstack镜像的方法。
开始安装nova:控制节点:
mysql -u root -p
CREATE DATABASE nova_api;
CREATE DATABASE nova;
GRANT ALL PRIVILEGES ON nova_api.* TO 'nova'@'localhost' \
IDENTIFIED BY '123456';
GRANT ALL PRIVILEGES ON nova_api.* TO 'nova'@'%' \
IDENTIFIED BY '123456';
GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'localhost' \
IDENTIFIED BY '123456';
GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'%' \
IDENTIFIED BY '123456';
trait@controller:~$ . admin-openrc
trait@controller:~$ openstack user create --domain default --password-prompt nova
User Password:
Repeat User Password:
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | 8b35eaf6aa47472f84f2001ed132f668 |
| name | nova |
+-----------+----------------------------------+
trait@controller:~$ openstack role add --project service --user nova admin
trait@controller:~$
trait@controller:~$ openstack service create --name nova --description "OpenStack Compute" compute
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | OpenStack Compute |
| enabled | True |
| id | 633998d68bb3418095453d7b3d337764 |
| name | nova |
| type | compute |
+-------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne compute public http://controller:8774/v2.1/%\(tenant_id\)s
+--------------+-------------------------------------------+
| Field | Value |
+--------------+-------------------------------------------+
| enabled | True |
| id | a26320f613c847d88efac47b1306a786 |
| interface | public |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 633998d68bb3418095453d7b3d337764 |
| service_name | nova |
| service_type | compute |
| url | http://controller:8774/v2.1/%(tenant_id)s |
+--------------+-------------------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne compute internal http://controller:8774/v2.1/%\(tenant_id\)s
+--------------+-------------------------------------------+
| Field | Value |
+--------------+-------------------------------------------+
| enabled | True |
| id | 73a3f4a2b2e2442cb368d54c381988d1 |
| interface | internal |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 633998d68bb3418095453d7b3d337764 |
| service_name | nova |
| service_type | compute |
| url | http://controller:8774/v2.1/%(tenant_id)s |
+--------------+-------------------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne compute admin http://controller:8774/v2.1/%\(tenant_id\)s
+--------------+-------------------------------------------+
| Field | Value |
+--------------+-------------------------------------------+
| enabled | True |
| id | bffb5359cc324325a77a94f5b4576071 |
| interface | admin |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 633998d68bb3418095453d7b3d337764 |
| service_name | nova |
| service_type | compute |
| url | http://controller:8774/v2.1/%(tenant_id)s |
+--------------+-------------------------------------------+
apt-get install nova-api nova-conductor nova-consoleauth nova-novncproxy nova-scheduler
在 /etc/nova/nova.conf 添加如下内容:
[api_database]
connection = mysql+pymysql://nova:123456@controller/nova_api
[database]
connection = mysql+pymysql://nova:123456@controller/nova
[DEFAULT]
enabled_apis = osapi_compute,metadata
rpc_backend = rabbit
my_ip = 10.0.0.11
use_neutron = True
firewall_driver = nova.virt.firewall.NoopFirewallDriver
auth_strategy = keystone
[vnc]
vncserver_listen = $my_ip
vncserver_proxyclient_address = $my_ip
[glance]
api_servers = http://controller:9292
[oslo_concurrency]
lock_path = /var/lib/nova/tmp
[oslo_messaging_rabbit]
rabbit_host = controller
rabbit_userid = openstack
rabbit_password = 123456
[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = nova
password = 123456
在计算节点:
apt-get install nova-compute
在/etc/nova/nova.conf
[DEFAULT]
rpc_backend = rabbit
auth_strategy = keystone
my_ip = 10.0.0.21
use_neutron = True
firewall_driver = nova.virt.firewall.NoopFirewallDriver
[oslo_messaging_rabbit]
rabbit_host = controller
rabbit_userid = openstack
rabbit_password = 123456
[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = nova
password = 123456
[vnc]
enabled = True
vncserver_listen = 0.0.0.0
vncserver_proxyclient_address = $my_ip
novncproxy_base_url = http://controller:6080/vnc_auto.html
[glance]
api_servers = http://controller:9292
[oslo_concurrency]
lock_path = /var/lib/nova/tmp
root@compute1:~# egrep -c '(vmx|svm)' /proc/cpuinfo
4
root@compute1:~#
如上的话就不用修改nova-compute.conf了。如果你的返回是0,那么如下修改:
[libvirt]
virt_type = qemu
OK,下面开始安装neutron:
在控制节点:
mysql -u root -p
CREATE DATABASE neutron;
GRANT ALL PRIVILEGES ON neutron.* TO 'neutron'@'localhost' \
IDENTIFIED BY '123456';
GRANT ALL PRIVILEGES ON neutron.* TO 'neutron'@'%' \
IDENTIFIED BY '123456';
trait@controller:~$ . admin-openrc
trait@controller:~$ openstack user create --domain default --password-prompt neutron
User Password:
Repeat User Password:
+-----------+----------------------------------+
| Field | Value |
+-----------+----------------------------------+
| domain_id | ba70a48abe5941179904fee58d20ab66 |
| enabled | True |
| id | fceb7cf67b984803819f01b88e99c42d |
| name | neutron |
+-----------+----------------------------------+
trait@controller:~$ openstack role add --project service --user neutron admin
trait@controller:~$
trait@controller:~$ openstack service create --name neutron --description "OpenStack Networking" network
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | OpenStack Networking |
| enabled | True |
| id | 361a7983524c4ff6be00765bf2bbd03b |
| name | neutron |
| type | network |
+-------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne network public http://controller:9696
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | 1bf3dc5f15ba4bb79fbbc5c478a9f7aa |
| interface | public |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 361a7983524c4ff6be00765bf2bbd03b |
| service_name | neutron |
| service_type | network |
| url | http://controller:9696 |
+--------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne network internal http://controller:9696
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | 52341779fb3344b5bbcd6d6397a4a4af |
| interface | internal |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 361a7983524c4ff6be00765bf2bbd03b |
| service_name | neutron |
| service_type | network |
| url | http://controller:9696 |
+--------------+----------------------------------+
trait@controller:~$ openstack endpoint create --region RegionOne network admin http://controller:9696
+--------------+----------------------------------+
| Field | Value |
+--------------+----------------------------------+
| enabled | True |
| id | fabf84db1fdf4be0a774e0d1e36bc3c8 |
| interface | admin |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 361a7983524c4ff6be00765bf2bbd03b |
| service_name | neutron |
| service_type | network |
| url | http://controller:9696 |
+--------------+----------------------------------+
安装L3代理的网络:
apt-get install neutron-server neutron-plugin-ml2 \
neutron-linuxbridge-agent neutron-l3-agent neutron-dhcp-agent \
neutron-metadata-agent
在/etc/neutron/neutron.conf 添加:
[database]
connection = mysql+pymysql://neutron:123456@controller/neutron
[DEFAULT]
core_plugin = ml2
service_plugins = router
allow_overlapping_ips = True
rpc_backend = rabbit
notify_nova_on_port_status_changes = True
notify_nova_on_port_data_changes = True
auth_strategy = keystone
[oslo_messaging_rabbit]
rabbit_host = controller
rabbit_userid = openstack
rabbit_password = 123456
[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = neutron
password = 123456
[nova]
auth_url = http://controller:35357
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = nova
password = 123456
/etc/neutron/plugins/ml2/ml2_conf.ini
[ml2]
type_drivers = flat,vlan,vxlan
tenant_network_types = vxlan
mechanism_drivers = linuxbridge,l2population
extension_drivers = port_security
[ml2_type_flat]
flat_networks = provider
[ml2_type_vxlan]
vni_ranges = 1:1000
[securitygroup]
enable_ipset = True
/etc/neutron/plugins/ml2/linuxbridge_agent.ini
[linux_bridge]
physical_interface_mappings = provider:eth2
[vxlan]
enable_vxlan = True
local_ip = 10.0.0.11
l2_population = True
[securitygroup]
enable_security_group = True
firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver
/etc/neutron/l3_agent.ini
[DEFAULT]
interface_driver = neutron.agent.linux.interface.BridgeInterfaceDriver
external_network_bridge =
/etc/neutron/dhcp_agent.ini
[DEFAULT]
interface_driver = neutron.agent.linux.interface.BridgeInterfaceDriver
dhcp_driver = neutron.agent.linux.dhcp.Dnsmasq
enable_isolated_metadata = True
/etc/neutron/metadata_agent.ini
[DEFAULT]
nova_metadata_ip = controller
metadata_proxy_shared_secret = 123456
/etc/nova/nova.conf
[neutron]
url = http://controller:9696
auth_url = http://controller:35357
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = neutron
password = 123456
service_metadata_proxy = True
metadata_proxy_shared_secret = 123456
su -s /bin/sh -c "neutron-db-manage --config-file /etc/neutron/neutron.conf \
--config-file /etc/neutron/plugins/ml2/ml2_conf.ini upgrade head" neutron
service nova-api restart
service neutron-server restart
service neutron-linuxbridge-agent restart
service neutron-dhcp-agent restart
service neutron-metadata-agent restart
service neutron-l3-agent restart
在计算节点:
apt-get install neutron-linuxbridge-agent
/etc/neutron/neutron.conf
在[database]这节 , 注释 connection 选项。because compute nodes do not directly access the database.
[DEFAULT]
rpc_backend = rabbit
auth_strategy = keystone
[oslo_messaging_rabbit]
rabbit_host = controller
rabbit_userid = openstack
rabbit_password = 123456
[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = neutron
password = 123456
/etc/neutron/plugins/ml2/linuxbridge_agent.ini
[linux_bridge]
physical_interface_mappings = provider:eth2
[vxlan]
enable_vxlan = True
local_ip = 10.0.0.21
l2_population = True
[securitygroup]
enable_security_group = True
firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver
/etc/nova/nova.conf
[neutron]
url = http://controller:9696
auth_url = http://controller:35357
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = neutron
password = 123456
service nova-compute restart
service neutron-linuxbridge-agent restart
trait@controller:~$ . admin-openrc
trait@controller:~$ neutron ext-list
+---------------------------+-----------------------------------------------+
| alias | name |
+---------------------------+-----------------------------------------------+
| default-subnetpools | Default Subnetpools |
| network-ip-availability | Network IP Availability |
| network_availability_zone | Network Availability Zone |
| auto-allocated-topology | Auto Allocated Topology Services |
| ext-gw-mode | Neutron L3 Configurable external gateway mode |
| binding | Port Binding |
| agent | agent |
| subnet_allocation | Subnet Allocation |
| l3_agent_scheduler | L3 Agent Scheduler |
| tag | Tag support |
| external-net | Neutron external network |
| net-mtu | Network MTU |
| availability_zone | Availability Zone |
| quotas | Quota management support |
| l3-ha | HA Router extension |
| provider | Provider Network |
| multi-provider | Multi Provider Network |
| address-scope | Address scope |
| extraroute | Neutron Extra Route |
| timestamp_core | Time Stamp Fields addition for core resources |
| router | Neutron L3 Router |
| extra_dhcp_opt | Neutron Extra DHCP opts |
| security-group | security-group |
| dhcp_agent_scheduler | DHCP Agent Scheduler |
| router_availability_zone | Router Availability Zone |
| rbac-policies | RBAC Policies |
| standard-attr-description | standard-attr-description |
| port-security | Port Security |
| allowed-address-pairs | Allowed Address Pairs |
| dvr | Distributed Virtual Router |
+---------------------------+-----------------------------------------------+
trait@controller:~$ neutron agent-list
+--------------------------------------+--------------------+------------+-------------------+-------+----------------+---------------------------+
| id | agent_type | host | availability_zone | alive | admin_state_up | binary |
+--------------------------------------+--------------------+------------+-------------------+-------+----------------+---------------------------+
| 4e0b9ef6-f1af-40fa-8e12-71dbea095bc1 | L3 agent | controller | nova | :-) | True | neutron-l3-agent |
| 705d2004-8b9b-46e1-b583-53372cf4b857 | Linux bridge agent | controller | | :-) | True | neutron-linuxbridge-agent |
| 75436579-b6c3-4a4d-a1f4-8bbf9e84e895 | Metadata agent | controller | | :-) | True | neutron-metadata-agent |
| 9b2ac64b-3c8c-4499-a063-e0515360827b | Linux bridge agent | compute1 | | :-) | True | neutron-linuxbridge-agent |
| ed38d626-c322-45bd-9c4e-7766d8654c35 | DHCP agent | controller | nova | :-) | True | neutron-dhcp-agent |
+--------------------------------------+--------------------+------------+-------------------+-------+----------------+---------------------------+
OK
neutron安装完成。
在ubuntu14.04上安装openstack mitaka的更多相关文章
- [译]How to Install Node.js on Ubuntu 14.04 如何在ubuntu14.04上安装node.js
原文链接为 http://www.hostingadvice.com/how-to/install-nodejs-ubuntu-14-04/ 由作者Jacob Nicholson 发表于October ...
- Ubuntu14.04上安装pip的方法
在Ubuntu14.04上,建议通过下面的方法安装,这是一种通用的方法,也适用于Windows,当然在Windows下 手动下载下来就行了 wget https://bootstrap.pypa.io ...
- Caffe初学者第一部:Ubuntu14.04上安装caffe(CPU)+Python的详细过程 (亲测成功, 20180524更新)
前言: 最近在学习深度学习,最先要解决的当然是开源框架的环境安装了.之前一直在学习谷歌的Tensorflow开源框架,最近实验中需要跟别人的算法比较,下载的别人的代码很多都是Caffe的,所以想着搭建 ...
- AWS ec2的ubuntu14.04上安装git服务
http://imerc.xyz/2015/11/13/Ubuntu-14-04%E4%B8%8AGit%E6%9C%8D%E5%8A%A1%E5%99%A8%E7%9A%84%E6%90%AD%E5 ...
- 在Ubuntu14.04上安装WordPress4搭建技术博客
1.安装LAMP环境 1.1 安装Apache2 1.2 安装MySQL5 1.3 安装PHP5 1.4 安装phpMyAdmin 2.初始化数据库 3.下载并配置WordPress 4.配置Apac ...
- [原创]在Linux系统Ubuntu14.04上安装部署docker。
Docker 是一个开源的应用容器引擎,让开发者可以打包他们的应用以及依赖包到一个可移植的容器中,然后发布到任何流行的 Linux 机器上,也可以实现虚拟化.容器是完全使用沙箱机制,相互之间不会有任何 ...
- ubuntu14.04上安装Mysql-5.7.11
先安装好操作系统 在Mysql官网上下载最新版的Ubuntu Linux专用的Mysql.我这里下载的是:mysql-server_5.7.11-1ubuntu14.04_amd64.deb-bu ...
- 在ubuntu14.04上安装mono4.4 + jexus + mvc6
0.准备工作 在/usr下建立一个文件夹,方便管理源码 cd /usr mkdir opensource cd opensource 安装vim(文本编辑器,不习惯用vim可以换成其他的) apt-g ...
- Ubuntu14.04上安装Composer
1,查看机子上有没有安装php 2,下载Composer的安装包 3,安装Composer 4,设置Composer全局可访问
随机推荐
- Bootstrap3.0学习第六轮(表单)
Bootstrap3.0学习第六轮(表单) 前言 阅读之前您也可以到Bootstrap3.0入门学习系列导航中进行查看http://www.cnblogs.com/aehyok/p/3404867.h ...
- 用Python实现gmail邮箱服务,实现两个邮箱之间的绑定(上)
一.本程序的起源 当我决定去中科院实习的时候,我给刘奎恩老师发了封邮件.我对此事是非常看重的,因此经常使用浏览器,打开gmail去查看刘老师有没有给我回复.因为gmail的新邮件推送的功能仅限于打开浏 ...
- [转]Breaking Bad With DTrace
Source:http://initwithfunk.com/blog/2013/05/31/breaking-bad-with-dtrace/ I’ve spent an unwise amount ...
- struts2文件上传大小限制问题
struts2默认文件上传大小为2M,如需修改默认大小,解决方法如下: <struts> <constant name="struts.multipart.maxSize& ...
- SQL删除重复数据,保留一条
例如: id name value 1 a pp 2 a ...
- 一步步学习Python-django开发-添加后台管理
Pyhon-djano提供了一个很强大的后台管理功能,你很轻松的就可以拥有一个后台管理平台.你需要做啥呢?你只需要将需要管理员进行管理的表注册到管理site中即可: from django.contr ...
- PyQt设计流程
Qt designer 设计流程: 创建一个 PyQt4 的步骤,通常的方法是用 QtDesigner 工具创建 GUI 界面.可以在窗口 上添加部件,并可以对部件进行一些属性配置.一般的过程如下 ...
- c# 数据库更新操作-文本更新和数值更新小差别
1.文本更新 string strName; sql = "update 模式表 a SET 模式名称 ='"+ strName +"'where a.模式ID =&qu ...
- MFC控件(7):Split Button
VS2008中可以看到MFC有一个叫Split Button的控件,要想看它的效果,瞧下QQ那聊天窗口的"发送", "消息记录"这两个按钮就知道了.实际上就是还 ...
- 语音频谱语音信号处理之(四)梅尔频率倒谱系数(MFCC)
今天一直在查找语音频谱之类的问题,今天正好有机会和大家共享一下. 语音信号处置之(四)梅尔频率倒谱系数(MFCC) zouxy09@qq.com http://blog.csdn.net/zouxy0 ...