九、仪表盘集群

6.1、安装软件包

所有控制节点上安装

# yum install openstack-dashboard

6.2、编辑配置文件

编辑文件 /etc/openstack-dashboard/local_settings 并完成如下动作:

在 controller 节点上配置仪表盘以使用 OpenStack 服务:

OPENSTACK_HOST = "controller1"

Allow your hosts to access the dashboard:

ALLOWED_HOSTS = ['one.example.com', 'two.example.com']

 注解

如果是面向所有开放,可以是[‘*’]

配置 memcached 会话存储服务:

SESSION_ENGINE = 'django.contrib.sessions.backends.cache'

CACHES = {

    'default': {

         'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',

         'LOCATION': 'controller:11211',

    }

}

 注解

将其他的会话存储服务配置注释。

启用第3版认证API:

OPENSTACK_KEYSTONE_URL = "http://%s:5000/v3" % OPENSTACK_HOST

启用对域的支持

OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT = True

配置API版本:

OPENSTACK_API_VERSIONS = {

    "identity": 3,

    "image": 2,

    "volume": 2,

}

Configure Default as the default domain for users that you create via the dashboard:

OPENSTACK_KEYSTONE_DEFAULT_DOMAIN = "Default"

通过仪表盘创建的用户默认角色配置为 user :

OPENSTACK_KEYSTONE_DEFAULT_ROLE = "user"

如果您选择网络参数1,禁用支持3层网络服务:

OPENSTACK_NEUTRON_NETWORK = {

    ...

    'enable_router': False,

    'enable_quotas': False,

    'enable_distributed_router': False,

    'enable_ha_router': False,

    'enable_lb': False,

    'enable_firewall': False,

    'enable_vpn': False,

    'enable_fip_topology_check': False,

}

可以选择性地配置时区:

TIME_ZONE = "TIME_ZONE"

Replace TIME_ZONE with an appropriate time zone identifier. For more information, see the list of time zones.

完成安装

重启web服务器以及会话存储服务:

# systemctl restart httpd.service memcached.service

将配置文件copy道其他控制节点上,更换ip

然后将http服务添加到haproxy里,重启服务

listen access_http

    mode http

    bind  192.168.16.10:80

    balance source

    server controller1 192.168.16.11:80 check inter 2000 rise 3 fall 3

    server controller2 192.168.16.12:80 check inter 2000 rise 3 fall 3

server controller3 192.168.16.13:80 check inter 2000 rise 3 fall 3

copy到其他控制节点上进行重启服务

6.3、验证仪表盘的操作。

在浏览器中输入 ``http://controller/dashboard``访问仪表盘。

验证使用 admin 或者``demo``用户凭证和``default``域凭证。

猜你喜欢

转载自www.cnblogs.com/hanjingzheng/p/9082258.html