Xenial - Can't connect to local MySQL server through socket /var/run/mysqld/mysqld.sock
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Charm Testing |
Fix Released
|
High
|
Ryan Beisner | ||
Openstack Mojo Testing |
Fix Released
|
High
|
Ryan Beisner | ||
percona-cluster (Juju Charms Collection) |
Fix Released
|
Undecided
|
David Ames |
Bug Description
Xenial-Mitaka full deploy tests (non-ha) are failing as of Jul 4 (\o/), but were passing on Jul 2 before the commit below [1].
percona-cluster (mysql) services are not started and running when shared_db_changed tries to connect and configure.
2016-07-04 22:45:58 INFO shared-
2016-07-04 22:45:58 ERROR juju.worker.
# Reproducer bundle (xenial-mitaka target)
http://
# Juju stat, full trace & other info
See attached.
# Possibly began with:
[1] https:/
Changed in openstack-charm-testing: | |
status: | New → Confirmed |
importance: | Undecided → High |
assignee: | nobody → Ryan Beisner (1chb1n) |
Changed in openstack-mojo-specs: | |
status: | New → Confirmed |
importance: | Undecided → High |
assignee: | nobody → Ryan Beisner (1chb1n) |
Changed in percona-cluster (Juju Charms Collection): | |
status: | Invalid → New |
Changed in percona-cluster (Juju Charms Collection): | |
assignee: | nobody → David Ames (thedac) |
status: | New → In Progress |
milestone: | none → 16.07 |
Changed in percona-cluster (Juju Charms Collection): | |
status: | In Progress → Fix Released |
Changed in openstack-mojo-specs: | |
status: | Confirmed → Fix Released |
Changed in openstack-charm-testing: | |
status: | Confirmed → Fix Released |
This is a configuration problem.
First, we should be using innodb- buffer- pool-size rather than dataset-size.
Second, the max connections settings has memory implications. It takes a little more than 2MB [1] for each connection. So setting max-connections to 20000 requires > 5G of memory just for mysql.
The error we see is InnoDB failing to allocate memory:
2016-07-07 22:08:43 28260 [Note] InnoDB: Initializing buffer pool, size = xM InnoDB: mmap(x bytes) failed; errno 12
The solution is balancing the amount of memory on a system/instance and the two settings innodb- buffer- pool-size and max-connections.
[1] http:// www.mysqlcalcul ator.com/