问题描述
问题分析
首先查看日志
tail /var/log/httpd/openstack_dashboard-error.log
查阅了很多资料,最后发现这个应该是 OpenStack 的一个 bug,原因分析可能是以前的仪表盘 dashboard 的访问路径是 http://controller/dashboard,而 OpenStack-Train 版本做了升级,把路径改为了 http://controller/所以需要进行相应的修改
解决方案
1.重建 dashboard 配置
cd /usr/share/openstack-dashboard
python manage.py make_web_conf --apache > /etc/httpd/conf.d/openstack-dashboard.conf
2.建立策略的软链接
ln -s /etc/openstack-dashboard /usr/share/openstack-dashboard/openstack_dashboard/conf
3.新增根目录指向
vim /etc/openstack-dashboard/local_settings
WEBROOT = '/dashboard/'
4.修改 openstack-dashboard.conf
vim /etc/httpd/conf.d/openstack-dashboard.conf
WSGIScriptAlias /dashboard /usr/share/openstack-dashboard/openstack_dashboard/wsgi/django.wsgi
Alias /dashboard/static /usr/share/openstack-dashboard/static
- 重启 httpd 和 memcached 服务
systemctl restart httpd.service systemctl restart memcached.service
openstack horizon web uiopenstack horizon web uiopenstack horizon web ui
文章评论