# Mongo ReplicaSets

**URL:** <https://discourse.chef.io/t/mongo-replicasets/5303>\
**Category:** Chef Infra (archive)\
**Created:** [May 13, 2014, 2:10pm UTC](https://discourse.chef.io/t/mongo-replicasets/5303 "2014-05-13T14:10:42Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Stewart\_Curtis](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/stewart_curtis/32/237_2.png) [@Stewart\_Curtis](https://discourse.chef.io/u/Stewart_Curtis)\
**Post date:** [May 13, 2014, 2:10pm UTC](https://discourse.chef.io/t/mongo-replicasets/5303/1 "2014-05-13T14:10:42Z")

</div>

Has anyone had any luck setting up a MongoDB replicaset with the mongodb cookbook ([https://github.com/edelight/chef-mongodb](https://github.com/edelight/chef-mongodb))?

Looks like a good quality cookbook, but I was hoping for some feedback before jumping into it.

Thanks,  
Curtis

Curtis Stewart  
Consultant  
m 217.390.5067  
Skype cstewart8710  
[cstewart@momentumsi.com](mailto:cstewart@momentumsi.com)[mailto:cstewart@momentumsi.com](mailto:cstewart@momentumsi.com)  
[www.momentumsi.com](http://www.momentumsi.com)[http://www.momentumsi.com/](http://www.momentumsi.com/)

[cid:71466434-A311-4F82-BC03-F7D6BA0FA526][http://www.momentumsi.com/](http://www.momentumsi.com/)[http://www.momentumsi.com/](http://www.momentumsi.com/)

Cloud Migration - Architecture - DevOps - Big Data - App Dev

---

<div class="post-metadata">

**Author:** ![BradKnowles](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/bradknowles/32/99_2.png) [@BradKnowles](https://discourse.chef.io/u/BradKnowles)\
**Post date:** [May 14, 2014, 2:10pm UTC](https://discourse.chef.io/t/mongo-replicasets/5303/2 "2014-05-14T14:10:10Z")

</div>

On May 13, 2014, at 9:10 AM, Stewart, Curtis [cstewart@momentumsi.com](mailto:cstewart@momentumsi.com) wrote:

> Has anyone had any luck setting up a MongoDB replicaset with the mongodb cookbook ([GitHub - edelight/chef-mongodb: MongoDB Chef cookbook](https://github.com/edelight/chef-mongodb))?

At a previous employer of mine, we took this cookbook and massaged it to the point where it could auto-create replicasets with sharding and the whole shebang. Our code definitely isn't the greatest, and I wasn't the one responsible for writing the hard bits, but we felt it was an improvement. Before I left, I was able to convince them to let me upload a copy of our work to my repo at [https://github.com/bknowles/mongodb](https://github.com/bknowles/mongodb).

> Looks like a good quality cookbook, but I was hoping for some feedback before jumping into it.

Dunno what has happened to the edelight cookbook since I last saw it, but my understanding is that not much has been done. My previous employer and I contributed our changes back to them, but last I heard those changes were never accepted -- that's why we chose to post our own version.

It would be great if someone could take the latest from the edelight cookbook, the work done at my previous employer, and help combine those with whatever else is out there. Thanks for volunteering! 😉

--  
Brad Knowles [brad@shub-internet.org](mailto:brad@shub-internet.org)  
LinkedIn Profile: [http://tinyurl.com/y8kpxu](http://tinyurl.com/y8kpxu)

---

<div class="post-metadata">

**Author:** ![DV1](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/dv1/32/186_2.png) [@DV1](https://discourse.chef.io/u/DV1)\
**Post date:** [May 14, 2014, 7:47pm UTC](https://discourse.chef.io/t/mongo-replicasets/5303/3 "2014-05-14T19:47:00Z")

</div>

We've forked edelight's mongodb cookbook a year or two ago and it worked  
great at that time for auto-configuring replicasets. Sometimes it would  
break in rare corner cases, but 95% of the time it would work. One thing  
that didn't work so well was removing and re-adding a replicaset member.

We've recently moved to Chef 11, and had to update to latest version of the  
cookbook. It's a lot better at configuring replicasets, IMO - even changes  
to replicasets are handled smoothly. We haven't tried sharding in  
production yet, only in development, but I've not heard any complaints from  
devs about the cookbook, which must mean that it works.

I would suggest creating a helper cookbook for any custom behavior rather  
than changing the community cookbook.. You don't want to come back a year  
later and realize that your version is hopelessly out of date.

On Wed, May 14, 2014 at 7:10 AM, Brad Knowles [brad@shub-internet.org](mailto:brad@shub-internet.org)wrote:

> On May 13, 2014, at 9:10 AM, Stewart, Curtis [cstewart@momentumsi.com](mailto:cstewart@momentumsi.com)  
> wrote:
> 
> > Has anyone had any luck setting up a MongoDB replicaset with the mongodb  
> > cookbook ([GitHub - edelight/chef-mongodb: MongoDB Chef cookbook](https://github.com/edelight/chef-mongodb))?
> 
> At a previous employer of mine, we took this cookbook and massaged it to  
> the point where it could auto-create replicasets with sharding and the  
> whole shebang. Our code definitely isn't the greatest, and I wasn't the  
> one responsible for writing the hard bits, but we felt it was an  
> improvement. Before I left, I was able to convince them to let me upload a  
> copy of our work to my repo at [https://github.com/bknowles/mongodb](https://github.com/bknowles/mongodb).
> 
> > Looks like a good quality cookbook, but I was hoping for some feedback  
> > before jumping into it.
> 
> Dunno what has happened to the edelight cookbook since I last saw it, but  
> my understanding is that not much has been done. My previous employer and  
> I contributed our changes back to them, but last I heard those changes were  
> never accepted -- that's why we chose to post our own version.
> 
> It would be great if someone could take the latest from the edelight  
> cookbook, the work done at my previous employer, and help combine those  
> with whatever else is out there. Thanks for volunteering! 😉
> 
> --  
> Brad Knowles [brad@shub-internet.org](mailto:brad@shub-internet.org)  
> LinkedIn Profile: [http://tinyurl.com/y8kpxu](http://tinyurl.com/y8kpxu)

--  
Best regards, Dmitriy V.

---

<div class="post-metadata">

**Author:** ![jdunn](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/jdunn/32/1800_2.png) [@jdunn](https://discourse.chef.io/u/jdunn)\
**Post date:** [May 16, 2014, 2:39pm UTC](https://discourse.chef.io/t/mongo-replicasets/5303/4 "2014-05-16T14:39:20Z")

</div>

On Wed, May 14, 2014 at 9:10 AM, Brad Knowles [brad@shub-internet.org](mailto:brad@shub-internet.org) wrote:

> On May 13, 2014, at 9:10 AM, Stewart, Curtis [cstewart@momentumsi.com](mailto:cstewart@momentumsi.com) wrote:
> 
> > Has anyone had any luck setting up a MongoDB replicaset with the mongodb cookbook ([GitHub - edelight/chef-mongodb: MongoDB Chef cookbook](https://github.com/edelight/chef-mongodb))?

> Dunno what has happened to the edelight cookbook since I last saw it, but my understanding is that not much has been done. My previous employer and I contributed our changes back to them, but last I heard those changes were never accepted -- that's why we chose to post our own version.

Jameson Lee of Hey, Inc. has been pretty active in maintaining it and  
accepting patches. He's also able to upload new versions to the  
community site.

- Julian

--  
[Julian C. Dunn [jdunn@aquezada.com](mailto:jdunn@aquezada.com) \* Sorry, I'm ]  
[WWW: [http://www.aquezada.com/staff/julian](http://www.aquezada.com/staff/julian) \* only Web 1.0 ]  
[gopher://sdf.org/1/users/keymaker/ \* compliant!]  
[PGP: 91B3 7A9D 683C 7C16 715F 442C 6065 D533 FDC2 05B9]
