Closed solairerove closed 7 years ago
@solairerove take everything down via: docker-compose down
Then start them up one by one in this order:
docker-compose up -d mongo
- give it a minute to start
docker-compose up -d mongo-init-replica
- give this one a minute to start as well.
Then finally: docker-compose up -d
should bring the rest of the stack up.
it's working, thanks!
This just happened to me with no change to the environment overnight - I'm glad it happened on a dev machine, but it renders my perfectly setup livechat environment with integrations useless overnight. The above commands not yield any success, as the mongo-init-replica
errors that it has been already been initialized.
ongo-init-replica_1 | MongoDB shell version v4.0.18
mongo-init-replica_1 | connecting to: mongodb://mongo:27017/rocketchat?gssapiServiceName=mongodb
mongo-init-replica_1 | Implicit session: session { "id" : UUID("e5474f2c-9db2-40e5-8b3a-c699eeacc757") }
mongo-init-replica_1 | MongoDB server version: 4.0.18
mongo-init-replica_1 | {
mongo-init-replica_1 | "operationTime" : Timestamp(1589086563, 1),
mongo-init-replica_1 | "ok" : 0,
mongo-init-replica_1 | "errmsg" : "already initialized",
mongo-init-replica_1 | "code" : 23,
mongo-init-replica_1 | "codeName" : "AlreadyInitialized",
mongo-init-replica_1 | "$clusterTime" : {
mongo-init-replica_1 | "clusterTime" : Timestamp(1589086563, 1),
mongo-init-replica_1 | "signature" : {
mongo-init-replica_1 | "hash" : BinData(0,"AAAAAAAAAAAAAAAAAAAAAAAAAAA="),
mongo-init-replica_1 | "keyId" : NumberLong(0)
mongo-init-replica_1 | }
mongo-init-replica_1 | }
mongo-init-replica_1 | }
EDIT:
docker-compose.yml
Has to be different situation. Since this issue would only happen on first startup. Never would show randomly While running. Also your output proves mongo already has replicaSet.
Make sure you don’t have multiple mongos running. Can often happen when iterating in dev environment. If another mongo instance came up with no replicaset initialized this would happen.
If still have repeatable situation please open new issue with steps to reproduce
@geekgonecrazy it was indeed a separate mongo instance that started up with my docker daemon
It happens :) glad you got it
https://raw.githubusercontent.com/RocketChat/Rocket.Chat/develop/docker-compose.yml not work