Comment 2 for bug 1728111

Revision history for this message
James Page (james-page) wrote : Re: cluster-relation-changed KeyError: 'getpwnam(): name not found: mysql'

Looking at the mysql log data:

./12/lxd/6/var/log/juju/unit-mysql-2.log

2017-10-27 16:26:09 INFO juju.worker.uniter resolver.go:104 found queued "install" hook

2017-10-27 16:42:24 INFO juju.worker.uniter resolver.go:104 found queued "leader-elected" hook
2017-10-27 16:42:24 DEBUG juju.worker.uniter.operation executor.go:69 running operation run leader-elected hook
2017-10-27 16:42:24 DEBUG juju.worker.uniter.operation executor.go:100 preparing operation "run leader-elected hook"
2017-10-27 16:42:24 DEBUG juju.worker.uniter.operation executor.go:100 executing operation "run leader-elected hook"
2017-10-27 16:42:24 DEBUG juju.worker.uniter agent.go:17 [AGENT-STATUS] executing: running leader-elected hook
2017-10-27 16:42:25 INFO juju-log Unknown hook leader-elected - skipping.
2017-10-27 16:44:04 INFO juju.worker.uniter.operation runhook.go:113 ran "leader-elected" hook
2017-10-27 16:44:04 DEBUG juju.worker.uniter.operation executor.go:100 committing operation "run leader-elected hook"

./0/lxd/6/var/log/juju/unit-mysql-0.log

2017-10-27 16:25:56 INFO juju.worker.uniter resolver.go:104 found queued "install" hook

2017-10-27 16:35:30 INFO juju.worker.uniter resolver.go:104 found queued "leader-elected" hook
2017-10-27 16:35:30 DEBUG juju.worker.uniter.operation executor.go:69 running operation run leader-elected hook
2017-10-27 16:35:30 DEBUG juju.worker.uniter.operation executor.go:100 preparing operation "run leader-elected hook"
2017-10-27 16:35:30 DEBUG juju.worker.uniter.operation executor.go:100 executing operation "run leader-elected hook"
2017-10-27 16:35:30 DEBUG juju.worker.uniter agent.go:17 [AGENT-STATUS] executing: running leader-elected hook
2017-10-27 16:35:31 INFO juju-log Unknown hook leader-elected - skipping.
2017-10-27 16:36:50 INFO juju.worker.uniter.operation runhook.go:113 ran "leader-elected" hook
2017-10-27 16:36:50 DEBUG juju.worker.uniter.operation executor.go:100 committing operation "run leader-elected hook"
2017-10-27 16:43:57 INFO juju.worker.uniter resolver.go:104 found queued "leader-elected" hook
2017-10-27 16:43:57 DEBUG juju.worker.uniter.operation executor.go:69 running operation run leader-elected hook
2017-10-27 16:43:57 DEBUG juju.worker.uniter.operation executor.go:100 preparing operation "run leader-elected hook"
2017-10-27 16:43:57 DEBUG juju.worker.uniter.operation executor.go:100 executing operation "run leader-elected hook"
2017-10-27 16:43:57 DEBUG juju.worker.uniter agent.go:17 [AGENT-STATUS] executing: running leader-elected hook
2017-10-27 16:43:59 INFO juju-log Unknown hook leader-elected - skipping.
2017-10-27 16:44:58 INFO juju.worker.uniter.operation runhook.go:113 ran "leader-elected" hook
2017-10-27 16:44:58 DEBUG juju.worker.uniter.operation executor.go:100 committing operation "run leader-elected hook"

pxc only installed once the lead unit has actually set the cluster root and sst passwords into leader storage; it would appear that at the time of install, non of the units was the leader, so the data was never seeded into leader storage.