stefanprodan / mongo-swarm Goto Github PK
View Code? Open in Web Editor NEWBootstrapping MongoDB sharded clusters on Docker Swarm
License: MIT License
Bootstrapping MongoDB sharded clusters on Docker Swarm
License: MIT License
Hi,
I know this repo hasn't been updated in 2 years so this is a bit of a reach. The mongo bootstrap image does not work for any mongo image above version 3.4. I tried deploying the stack with version 3.6 and also 4.0 but it's unable to find the 2 mongo servers (mongs1 and mongos2 after initializing the config and data services.
mongo_bootstrap.1.kjqj8sfndjtz@ip-10-50-1-39 | time="2019-06-21T12:24:21Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.msxdw6cg7v5r@ip-10-50-1-39 | time="2019-06-21T12:07:14Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:40:24Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.kjqj8sfndjtz@ip-10-50-1-39 | time="2019-06-21T12:24:32Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.msxdw6cg7v5r@ip-10-50-1-39 | time="2019-06-21T12:07:19Z" level=fatal msg="%!m(string=mongos1:27017)ongos connection failed" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:40:35Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:40:45Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.kjqj8sfndjtz@ip-10-50-1-39 | time="2019-06-21T12:24:42Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.kjqj8sfndjtz@ip-10-50-1-39 | time="2019-06-21T12:24:53Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:40:56Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:41:06Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.kjqj8sfndjtz@ip-10-50-1-39 | time="2019-06-21T12:24:58Z" level=fatal msg="%!m(string=mongos1:27017)ongos connection failed" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:41:17Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:41:27Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:41:38Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:41:48Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:41:59Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:42:09Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:42:20Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:42:30Z" level=warning msg="mongos1:27017 is offline retrying in 5 seconds" mongo_bootstrap.1.ibwky8in8ucy@ip-10-50-1-39 | time="2019-06-21T12:42:35Z" level=fatal msg="%!m(string=mongos1:27017)ongos connection failed"
It'll be nice to get a pointer as to how to fix this (or maintain the repo) if you don't have enough time to get around to fixing it yourself
Thanks
hi, I modify the code of bootstrap, then build a new image base on Dockfile, but when I do it, it happens to occur these error, can you help me ?
I review your code in bootstarp, It happen to support only one shard, ie, datars shard replSet, can you modify the go code to support multiple shard, for example, I can write shard config as
last, how to add Authenticate MongoDB shard cluster in Docker swarm, can you tell me in details, looking forward to your reply?
Can it be possible to make it dynamic?
For example :
.....
data:
image: mongo:3.4
networks:
- mongo
volumes:
- data:/data/db
command: mongod --shardsvr --replSet datars --smallfiles --port 27017
deploy:
mode: replicated
replicas: 3
placement:
constraints:
- node.labels.mongo.role == data
Hello
I have launched a client instance
docker run --network mongos -it mongo:3.4 mongo mongos1:27017
and from there I am trying to restore one of my database but mongorestore is not working and giving me this error
2018-02-07T16:07:53.369+0000 Failed: error connecting to db server: no reachable servers
would you please tell me how I can restore database in mongo swarm
I was looking thorugh the docs and I didn't see how you can specify different shards on the data configuration?
Hello There,
Please guide how to enable remote access of client with auth uname and password
Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.