错误:在 openstack pike devstack 上创建实例时未建立 sql_connection 参数 [英] Error: No sql_connection parameter is established when creating instances on openstack pike devstack
问题描述
我已经通过以下链接在我的 Ubuntu 16.04 上成功安装了 Openstack Devstack pike:https://www.mirantis.com/blog/how-to-install-openstack-on-your-local-machine-using-devstack/.
I've successfully installed Openstack Devstack pike on my Ubuntu 16.04 by following this link: https://www.mirantis.com/blog/how-to-install-openstack-on-your-local-machine-using-devstack/.
当我尝试创建一个实例时,我得到 No sql_connection 参数被建立为错误.
when i tried to create an instance i got No sql_connection parameter is established as an error.
我检查了/etc/nova/nova.conf 和数据库配置如下:
I've checked /etc/nova/nova.conf and database configuration was as following:
[数据库]连接 = mysql+pymysql://root:mypassword@127.0.0.1/nova_cell0?charset=utf8
[database] connection = mysql+pymysql://root:mypassword@127.0.0.1/nova_cell0?charset=utf8
[api_database]连接 = mysql+pymysql://root:mypassword@127.0.0.1/nova_api?charset=utf8
[api_database] connection = mysql+pymysql://root:mypassword@127.0.0.1/nova_api?charset=utf8
此外,我没有找到与 openstack 相关的日志所在的位置.我只访问了/opt/stack/logs/stack.sh.log,没有任何进程.
Besides i didn't find where the logs related to openstack are located. I only accessed to /opt/stack/logs/stack.sh.log and it doesn't any process.
我该如何解决这个问题?如果有人能帮我解决这个问题,我将不胜感激.
How can i resolve this issue? I'll be grateful if someone could help me resolving it.
推荐答案
我在 Devstack Pike 上遇到了这个问题,当我想创建一个虚拟机(从 HOT 模板)将其连接到现有网络(public,默认存在.)(您可以通过(至少)两种方式为 VM 设置网络:将端口连接到它,或将 VM 连接到现有网络.在后一种情况下,会隐式创建一个端口.
I had this problem on Devstack Pike when I wanted to create a VM (from a HOT template) connecting it to an already existing network (public, which exists by default.) (You can set up networking for a VM in (at least) 2 ways: either connect a port to it, or connect the VM to an existing network. In the latter case a port is implicitly created.)
问题是 public 属于另一个项目.
The problem was that public belonged to another project.
当我指定一个属于同一个项目的网络时,它成功了.
When I specified a network that belonged to the same project, it was successful.
我希望这会有所帮助.
顺便说一句,Devstack 日志会进入系统日志.
Btw, the Devstack logs go into the syslog.
这篇关于错误:在 openstack pike devstack 上创建实例时未建立 sql_connection 参数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!