colinmollenhour / mariadb-galera-swarm

MariaDb Galera Cluster container based on official mariadb image which can auto-bootstrap and recover cluster state.
https://hub.docker.com/r/colinmollenhour/mariadb-galera-swarm
Apache License 2.0
217 stars 103 forks source link

Nodes can't join the "seed" container #7

Closed w7089 closed 7 years ago

w7089 commented 7 years ago

Hi, After running docker service create --name galera-seed --replicas 1 -e XTRABACKUP_PASSWORD=test seed docker service create --name galera --replicas 2 -e XTRABACKUP_PASSWORD=test node tasks.galera-seed,tasks.galera

I see that 2 docker galera containers are crashing after a minute after failing to reach "healthy" status. And there's error at the log of the crashed containers.

{"log":"ERROR 1045 (28000): Access denied for user 'system'@'127.0.0.1' (using password: YES)\n","stream":"stderr","time":"2017-01-01T18:38:43.485726233Z"} {"log":"start.sh: Trapped error on line 198\n","stream":"stdout","time":"2017-01-01T18:38:43.486807412Z"}

The first service is up and running. Can you tell me what i might be doing wrong, please?

colinmollenhour commented 7 years ago

Please see #5. I suppose the README should be updated with this info..

w7089 commented 7 years ago

Hi, thanks, i fear, i don't fully understand the problem and it's solution. My db is empty, this error happens during the initial cluster bootstrap.

colinmollenhour commented 7 years ago

Line 198 is in the trapped shutdown signal handler so I suspect docker is sending the shutdown signal due to unhealthy status so playing with the swarm options might help. I think I'd have to see the full logs to be helpful.

colinmollenhour commented 7 years ago

There was a bug that I found where the seed node was starting with the wrong command line arguments. Not sure if this was your issue or not.