安装openstack同步数据库时出错解决方法
错误提示:(2003, "Can't connect to MySQL server on 'controller' ([Errno -2] Name or service not known)")
问题原因:域名解析(controller)出错
解决办法:vi /etc/hosts
192.168.1.11 controller
(注:192.168.1.11用本地ip代替)
错误提示:1045, u"Access denied for user 'keystone'@'controller' (using password: YES)
问题原因:可能是密码错误或权限问题
解决办法:
用root登录到MySQL查看一下用户:
mysql -u root -p
select host,user from mysql.user;
并再重新设置权限:
grant all privileges on keystone.* to 'keystone'@'%' identified by '密码';
flush privileges;
退出root,使用用户keystone登录MySQL测试。