查看日志/var/log/nova/nova-scheduler.log
,/var/log/nova/nova-compute.log
,均无报错
查看/var/log/nova/nova-conductor.log
报错为
2017-02-06 09:27:04.976 2206 ERROR oslo_messaging.rpc.server OperationalError: (pymysql.err.OperationalError) (1040, u'Too many connections')
修改mariadb配置文件
]# vim /etc/my.cnf.d/openstack.cnf
[mysqld]
max_connections = 4096
修改系统打开数
]# vim /etc/security/limits.conf
* soft nofile 65536
* hard nofile 65536
]# ulimit -SHn 65536
]# vim /etc/sysctl.conf
# max open files
fs.file-max = 65536
]# sysctl -p
重启mariadb
]# systemctl restart mariadb
如下错误
2017-02-06 09:54:56.400 2213 ERROR nova.servicegroup.drivers.db OperationalError: (pymysql.err.OperationalError) (2006, "MySQL server has gone away (error(32, 'Broken pipe'))")
上面的报错意思就是指client和MySQL server之间的链接断开了。
因为重启mariadb,其他openstack服务工作不正常了,需要重启其他服务
]# openstack-service list
neutron-dhcp-agent
neutron-l3-agent
neutron-linuxbridge-agent
neutron-metadata-agent
neutron-server
openstack-glance-api
openstack-glance-registry
openstack-nova-api
openstack-nova-compute
openstack-nova-conductor
openstack-nova-consoleauth
openstack-nova-novncproxy
openstack-nova-scheduler
]# openstack-service restart