openstack 常见问题及解决方法

来源:互联网 发布:安康市 软件正版 编辑:程序博客网 时间:2024/06/09 21:59

1. 实例不能PXE启动

问题如下:

创建vm没有任何报错,打开控制台提示:

SeaBIOS (versio xxxxxxx)Machine UUID xxxxxxxxxxiPXE (http://ipxe.org) 00.03.0 C980 PCI2.10 PnP PMM

导致这个问题的原因在于centos7.3源中的qemu1.5版本低,更新一下qemu版本即可

[root@compute01 ~]# yum install -y centos-release-qemu-ev.noarch

[root@compute01 ~]# yum update -y 

 查看更新后的版本为qemu2.6,之前是1.5

[root@compute01 ~]# virsh version 
Compiled against library: libvirt 2.0.0
Using library: libvirt 2.0.0
Using API: QEMU 2.0.0
Running hypervisor: QEMU 2.6.0

转载自:http://www.cnblogs.com/menkeyi/p/6689256.html

======================================================================================

2. dashboard能正常登陆,能做一系列的操作,但在做删除操作时会报如下错误。


日志如下所示


报UnicodeDecodeError: 'ascii' codec can't decode byte 0xe5 in position 0: ordinal not in range(128)是转码失败

解决办法:

在/etc/OpenStack-dashboard/local_settings中加入相关模块

import sys

reload(sys)

sys.setdefaultencoding('utf-8')

加入后local_settings如下图所示:


最后重启http和memcached服务

systemctl start httpd.service memcached.service

转载自:http://blog.csdn.net/wylfengyujiancheng/article/details/49681799

======================================================================================

3.安装openstack-dashboard时出现的python compress command not found错误 httpd服务启动失败

出现如下的报错信息:

 python[xxxxx]: CommandError: An error occurred during rendering 

 /usr/share/openstack-dashboard/openstack_dashboard/templates/_stylesheets.html: 

 /bin/sh: django_pyscss.compressor.DjangoScssFilter: command not found

 centos7 中的python版本为2.7

 django-pyscss的版本为要在2.0以上才能正常使用,而自带版本为:

 #yum list|grep django-pyscss

python-django-pyscss.noarch1.0.5-2.el7@epel

所以更新一下django-pyscss版本即可


本文出自 “纷繁中享受技术的简单喜悦” 博客,请务必保留此出处http://51enjoy.blog.51cto.com/8393791/1891410

4. openstack kilo版本启动httpd失败,报ImportError: cannot import name importlib错误

这个是因为centos7.3 用pip升级django-pyscss后django自动升级到了django-1.11.4版,换成低版本的django就好了(好像是从django-1.9开始django.utils里就没有importlib了),我这里从新安装了django-1.8.18,再启动httpd就能正常启动了