OpenStack排錯總結
1、AMQP Server on controller:5672 is unreachable
解決方法:iptables -I INPUT -p tcp –dport 5672 -j ACCEPT
2、unable to establish connection to http://controller:8874
解決方法:首先,執行openstack service list和openstack endpoint list檢視服務和API接口是否成功建立;然後,openstack compute service list檢視nova-scheduler、nova-conductor、nova-compute等是否正常啟動;最後,嘗試重新開機相關服務。
3、Host ‘compute’ is not mapped to any cell
解決方法:su -s /bin/sh -c “nova-mange cell_v2 discover_hosts –verbose” nova
4、access denied for user ‘nova’@’controller’
解決方法:nova.conf中connection連結配置有誤。
5、dashboard無法登陸,提示有誤,請聯系管理者。
解決方法:vi /etc/sysconfig/memcached,修改OPTIONS為OPTIONS=”-1 127.0.0.1,::1,controller”,重新開機memcached服務。
6、控制節點檢視cinder服務發現cinder-volume顯示down,但是實際systemctl status openstack-cinder-volume顯示正常。
解決方法:檢視NTP是否正常安裝以及配置是否正确。
7、httpd.service無法啟動的問題,錯誤代碼為4499,錯誤提示為無法綁定位址。
解決方法:setenforce 0關閉系統自帶的selinux,如果遇到nova docker鏡像啟動錯誤的問題,該解決方法也同樣适用。
8、Pike版本更新節點的庫報錯,錯誤為http://mirror.centos.org/%24contentdir/7/virt/x86_64/kvm-common/repodata/repomd.xml: [Errno 14] HTTP Error 404 - Not Found。
解決方法:修改CentOS-QEMU-EV.repo 中的
baseurl=http://mirror.centos.org/centos/$releasever/virt/$basearch/kvm-common/
9、AttributeError: type object ‘BaseCommand’ has no attribute ‘option_list’
解決方法:pip install django==1.9.2
10、Pike版本dashboard無法打開
解決方法:vi /etc/httpd/conf.d/openstack-dashboard.conf
在WSGISocketPrefix run/wsgi下面增加一行
WSGIApplicationGroup %{GLOBAL}
11、ACCESS_REFUSED - Login was refused using authentication mechanism AMQPLAIN. For details see the broker logfile.
解決方法:檢視對應配置項中的rabbitmq使用者是否存在(rabbitmqctl list_users)以及密碼是否正确。
openstack中所有的日志檔案都存放在/var/log中,執行tail -f加日志檔案可以監控相關服務。執行openstack指令行接口時,加上debug參數也可以看到詳細的接口調用過程,這些有助于排錯以及相關源碼追蹤。