I'm trying to setup a MongoDB replica set using the puppetlabs/mongodb module. My manifests pretty much match the example on the modules page:
class mongodb::server {
replset => 'configserver',
replset_config => { 'configserver' => { ensure => present, members => ['host1:27017', 'host2:27017''] } }
}
This is throwing the following error:
> Debug: Executing: '/usr/bin/mongo> admin --quiet --host 127.0.0.1:27017> --eval printjson(rs.conf())' Debug: Request failed: 'Execution of> '/usr/bin/mongo admin --quiet --host> 127.0.0.1:27017 --eval printjson(rs.conf())' returned 252:> 2016-04-25T15:18:21.132-0600 E QUERY> [thread1] Error: Could not retrieve> replica set config: { "info" : "run> rs.initiate(...) if not yet done for> the set", "ok" : 0, "errmsg" : "no> replset config has been received",> "code" : 94 } :> rs.conf@src/mongo/shell/utils.js:1196:11> @(shell eval):1:11' Retry: '3' Debug:> Got an exception: Could not evalute> MongoDB shell command:> printjson(rs.conf()) Debug: Storing> state Debug: Stored state in 0.07> seconds Error: Failed to apply> catalog: Could not evalute MongoDB> shell command: printjson(rs.conf())
Can anybody provide some insight as to why its happening?
↧