openstack部署及使⽤过程中遇到的问题汇总
报错01
Applying 10.130.0.148_controller.pp
10.130.0.148_controller.pp: [ ERROR ]
Applying Puppet manifests [ ERROR ]
ERROR : Error appeared during Puppet run: 10.130.0.148_controller.pp
Error: /Stage[main]/Gnocchi::Db::Sync/Exec[gnocchi-db-sync]: Failed to call refresh: gnocchi-upgrade --config-file
/etc/f returned 1 instead of one of [0]
You will find full trace in log /var/tmp/packstack/20210308-151630-LdDNev/manifests/10.130.0.148_controller.pp.log Please check log file /var/tmp/packstack/20210308-151630-LdDNev/openstack-setup.log for more information Additional information:
A new answerfile was created in: /
Time synchronization installation was skipped. Please note that unsynchronized time on server instances might be problem for some OpenStack components.
Warning: NetworkManager is active on 10.130.0.148. OpenStack networking currently does not work on systems that have the Network Manager service enabled.
File /root/keystonerc_admin has been created on OpenStack client host 10.130.0.148. To use the command line tools you need to source the file.
To access the OpenStack Dashboard browse to 10.130.0.148/dashboard .
Please, find your login credentials stored in the keystonerc_admin in your home directory.
解决⽅案
查看/var/tmp/packstack/20210308-151630-LdDNev/openstack-setup.log发现以下提⽰信息
^[[mNotice: /Stage[main]/Gnocchi::Db::Sync/Exec[gnocchi-db-sync]/returns: pkg_resources.DistributionNotFound: setuptools>=30.3^[[0m
^[[1;31mError: /Stage[main]/Gnocchi::Db::Sync/Exec[gnocchi-db-sync]: Failed to call refresh: gnocchi-upgrade --config-file /etc/f returned 1 instead of one of [0]^[[0 m
查看实际环境中对应组件版本为python-setuptools-0.9.8
[root@controller ~]# rpm -qa | grep setuptools
python-setuptools-0.9.arch
⼿动安装
[root@controller ~]# yum install -y python2-setuptools
完成后重新执⾏packstack --allinone
报错02
镜像->创建镜像报错
出错啦!
遇到异常情况,请刷新。如需帮助请联系管理员。
镜像创建过程中是将本地的iso或者其他格式的镜像上传⾄openstack服务器,因此过程中涉及到拷贝,所以需要对本地环境设置免密登陆解决:
ssh-copy-id root@10.130.0.148
实例创建后启动失败,报错:
报错03
No valid host was found. There are not enough hosts available.
解决
⽹上查了说是可能和openstack-nova-compute有关
查看服务状态,异常,多次重启依旧异常
查看⽇志/var/log/nova/nova-compute.log提⽰Connection to libvirt failed: error from service: CheckAuthorization: Connection is closed: libvirtError: error from service: CheckAuthorization: Connection is closed
怀疑和libvirt有关,重启libvirtd然后重启systemctl restart openstack-nova-compute
然后openstack-nova-compute服务正常启动
报错04
Build of instance e0d58ee2-5738-4aa3-87da-f1a448650c7b aborted: Volume 3d6505f3-53c6-48ce-b54c-
3b98f080e8e2 did not finish being created even after we waited 193 seconds or 61 attempts. And its status is downloading.
从错误原因上推测,OpenStack在不停尝试61次后,宣告创建实例失败。此时,卷创建依然还未完成。所以,实例创建失败的原因可能为,卷创建需要的时间⽐较久,在卷创建成功完成之前,Nova组件等待超时了。
解决办法
在/etc/f中有⼀个控制卷设备重试的参数:block_device_allocate_retries,可以通过修改此参数延长等待时间。
该参数默认值为60,这个对应了之前实例创建失败消息⾥的61 attempts。我们可以将此参数设置的⼤⼀点,例如:300。这样Nova组件就不会等待卷创建超时,也即解决了此问题。
报错05
Build of instance 6aeda58a-cb51-4388-a892-2d1bdabdaae1 aborted: The server has either erred or is incapable of performing the requested operation. (HTTP 500) (Request-ID: req-ce697d3c-8b41-4d4b-bead-d77494641962)
报错06
2021-03-16 02:52:55::DEBUG::sequences::52::root:: Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/packstack/installer/core/sequences.py”, line 50, in run
self.function(config, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 214, in apply_puppet_manifest
wait_for_puppet(currently_running, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 128, in wait_for_puppet
validate_logfile(log)
File “/usr/lib/python3.6/site-packages/packstack/modules/puppet.py”, line 107, in validate_logfile
raise PuppetError(message)
ptions.PuppetError: Error appeared during Puppet run: 10.2.5.156_controller.pp
^[[mNotice: /Stage[main]/Nova::Db::Sync/Exec[nova-db-sync]/returns: Error: (OperationalError) (1045,“Access denied for user ‘nova’@‘openstack’ (using password: YES)”)^[[0m
You will find full trace in log /var/tmp/packstack/20210316-023224-_zcrtdam/manifests/10.2.5.156_controller.pp.log
2021-03-16 02:52:55::ERROR::run_setup::1062::root:: Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/packstack/installer/run_setup.py”, line 1057, in main
_main(options, confFile, logFile)
File “/usr/lib/python3.6/site-packages/packstack/installer/run_setup.py”, line 681, in _main
runSequences()
File “/usr/lib/python3.6/site-packages/packstack/installer/run_setup.py”, line 648, in runSequences
controller.runAllSequences()
File “/usr/lib/python3.6/site-packages/packstack/installer/setup_controller.py”, line 81, in runAllSequences sequence.run(config=self.CONF, messages=self.MESSAGES)
File “/usr/lib/python3.6/site-packages/packstack/installer/core/sequences.py”, line 109, in run
step.run(config=config, messages=messages)
File “/usr/lib/python3.6/site-packages/packstack/installer/core/sequences.py”, line 50, in run
self.function(config, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 214, in apply_puppet_manifest
wait_for_puppet(currently_running, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 128, in wait_for_puppet
validate_logfile(log)
File “/usr/lib/python3.6/site-packages/packstack/modules/puppet.py”, line 107, in validate_logfile
raise PuppetError(message)
ptions.PuppetError: Error appeared during Puppet run: 10.2.5.156_controller.pp
^[[mNotice: /Stage[main]/Nova::Db::Sync/Exec[nova-db-sync]/returns: Error: (OperationalError) (1045,“Access denied for user ‘nova’@‘openstack’ (using password: YES)”)^[[0m
You will find full trace in log /var/tmp/packstack/20210316-023224-_zcrtdam/manifests/10.2.5.156_controller.pp.log 修改
#Email address for the Identity service ‘admin’ user. Defaults to
CONFIG_KEYSTONE_ADMIN_EMAIL=root@admin
关于使⽤packstack -d --进⾏初始化时建议修改默认密码,否则在使⽤⽤户密码登陆mysql的时候将⽐较⿇烦
执⾏mysql -u nova -p,然后⽤中对应密码进⾏登陆,验证密码是否正确
报错08
File “/usr/lib/python3.6/site-packages/packstack/installer/core/sequences.py”, line 50, in run
self.function(config, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 214, in apply_puppet_manifest
wait_for_puppet(currently_running, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 128, in wait_for_puppet
validate_logfile(log)mysql下载出现installer
File “/usr/lib/python3.6/site-packages/packstack/modules/puppet.py”, line 107, in validate_logfile
raise PuppetError(message)
ptions.PuppetError: Error appeared during Puppet run: 10.2.5.156_controller.pp
Error: Failed to apply catalog: Execution of ‘/usr/bin/openstack flavor list --quiet --format csv --long --all’ returned 1: Unknown Error (HTTP 500) (tried 29, for a total of 170 seconds)^[[0m
You will find full trace in log /var/tmp/packstack/20210316-043006-vp2u2jc8/manifests/10.2.5.156_controller.pp.log
2021-03-16 04:36:48::ERROR::run_setup::1062::root:: Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/packstack/installer/run_setup.py”, line 1057, in main
_main(options, confFile, logFile)
File “/usr/lib/python3.6/site-packages/packstack/installer/run_setup.py”, line 681, in _main
runSequences()
File “/usr/lib/python3.6/site-packages/packstack/installer/run_setup.py”, line 648, in runSequences
controller.runAllSequences()
File “/usr/lib/python3.6/site-packages/packstack/installer/setup_controller.py”, line 81, in runAllSequences
sequence.run(config=self.CONF, messages=self.MESSAGES)
File “/usr/lib/python3.6/site-packages/packstack/installer/core/sequences.py”, line 109, in run
step.run(config=config, messages=messages)
File “/usr/lib/python3.6/site-packages/packstack/installer/core/sequences.py”, line 50, in run
self.function(config, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 214, in apply_puppet_manifest
wait_for_puppet(currently_running, messages)
File “/usr/lib/python3.6/site-packages/packstack/plugins/puppet_950.py”, line 128, in wait_for_puppet
validate_logfile(log)
File “/usr/lib/python3.6/site-packages/packstack/modules/puppet.py”, line 107, in validate_logfile
raise PuppetError(message)
ptions.PuppetError: Error appeared during Puppet run: 10.2.5.156_controller.pp
Error: Failed to apply catalog: Execution of ‘/usr/bin/openstack flavor list --quiet --format csv --long --all’ returned 1: Unknown Error (HTTP 500) (tried 29, for a total of 170 seconds)^[[0m
You will find full trace in log /var/tmp/packstack/20210316-043006-vp2u2jc8/manifests/10.2.5.156_controller.pp.log
1 ]# netstat -anp|grep 35357 //使⽤命令查看是否有这个服务端⼝
2
3
4
5 如果没有35357 端⼝
6 ]# vim
/etc/f 7 8 admin_port = 35357 //取消注释
报错09
ERROR : Error appeared during Puppet run: 10.2.5.142_controller.pp
Error: Execution of ‘/usr/bin/dnf -d 0 -e 1 -y install ntpdate’ returned 1: Error: Unable to find a match: ntpdate
解决
CentOS8系统中,原有的时间同步服务 ntp/ntpdate服务已经⽆法使⽤,使⽤yum安装,提⽰已不存在,将answer⽂件中与ntp相关的配置项致空⽆需配置即可
报错10
ERROR : Error appeared during Puppet run: 10.2.5.156_controller.pp
Error: Could not prefetch mysql_user provider ‘mysql’: Execution of ‘/usr/bin/mysql --defaults-extra-file=/root/.myf -NBe SELECT CONCAT(User, ‘@’,Host) AS User FROM mysql.user’ returned 1: ERROR 1045 (28000): Access denied for user ‘root’@‘localhost’ (using password: YES)
解决
更改answer⽂件中对应的密码为简单密码解决
报错11
Applying 10.2.5.142_controller.pp
10.2.5.142_controller.pp: [ ERROR ]
Applying Puppet manifests [ ERROR ]
报错12
报错
ERROR : Error appeared during Puppet run: 10.2.5.157_controller.pp
Error: Could not prefetch keystone_domain provider ‘openstack’: Execution of ‘/usr/bin/openstack domain list --quiet --format csv’ returned 1: module ‘urllib3.packages.six’ has no attribute ‘ensure_text’ (tried 38, for a total of 170 seconds)
解决
pip3 uninstall six
pip3 install six==1.12.0
pip3 uninstall urllib3
Successfully uninstalled urllib3-1.25.7
Pip3 install urllib3==1.25.11
Successfully installed urllib3-1.26.4
报错13
Error: /Stage[main]/Packstack::Swift::Ringbuilder/Ring_object_device[dev_10.2.5.157_swiftloopback]: Could not evaluate: Execution of ‘/usr/bin/swift-ring-builder /etc/swift/object.builder’ returned 1: Traceback (most recent call last):
解决
单独执⾏/usr/bin/swift-ring-builder /etc/swift/object.builder
提⽰six模块不到
但是单独运⾏python3然后import six,没有报错,查看⽇志,
只是在运⾏/usr/bin/swift-ring-builder的时候提⽰不到six模块,发现该脚本最顶部使⽤了#!/usr/bin/python3 -s,怀疑是-s参数导致,删除-s重新执⾏解决
报错 14
报错
Error: Could not prefetch keystone_domain provider ‘openstack’: Execution of ‘/usr/bin/openstack domain list --quiet --format csv’ returned 1: /usr/lib/python3.6/site-packages/requests/init.py:91: RequestsDependencyWarning: urllib3
(1.26.4) or chardet (3.0.4) doesn’t match a supported version!
You will find full trace in log /var/tmp/packstack/20210324-040056-pt3pvlq5/manifests/10.2.5.157_controller.pp.log

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。