Details
-
Bug
-
Status: Closed
-
Blocker
-
Resolution: Duplicate
-
PUP 4.3.1
-
None
-
None
-
Fedora 18
Virtualbox 4.3.34
Puppet 4.3.1
Description
IRC LOG:
<<robSmth> I think I need the client.pp but where do I make one. I followed the instructions here.https://github.com/puppetlabs/puppetlabs-mongodb
<robSmth> I only inserted some lines n my code.> It looks like the module might have a puppet 4 related bug. That's all.
afisher> I think the 'versioncmp' function in puppet 4 is more strict that it was in puppet 3
<afisher> It appears there are ways to make the module call versioncmp with invalid parameters. I'd probably class that as a bug.
THE ERROR
gexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::ssl_key in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: Evicting cache entry for environment 'production'
==> default: Debug: Caching environment 'production' (ttl = 0 sec)
==> default: Debug: Performing a hiera indirector lookup of mongodb::server::ssl_ca with options {:variables=>Scope(Class[Mongodb::Server]), :merge=>#<Puppet::Pops::FirstFoundStrategy:0x000000034712a8 @options_t=#<Puppet::Pops::Types::PStructType:0x0000000346d590 @elements=[#<Puppet::Pops::Types::PStructElement:0x0000000346d5b8 @key_type=#<Puppet::Pops::Types::POptionalType:0x0000000346d5e0 @optional_type=#<Puppet::Pops::Types::PStringType:0x0000000346d680 @size_type=nil, @values=["strategy"]>>, @value_type=#<Puppet::Pops::Types::POptionalType:0x0000000346d770 @optional_type=#<Puppet::Pops::Types::PPatternType:0x0000000346d798 @patterns=[#<Puppet::Pops::Types::PRegexpType:0x0000000346d8b0 @pattern="first", @regexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::ssl_ca in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: Evicting cache entry for environment 'production'
==> default: Debug: Caching environment 'production' (ttl = 0 sec)
==> default: Debug: Performing a hiera indirector lookup of mongodb::server::restart with options {:variables=>Scope(Class[Mongodb::Server]), :merge=>#<Puppet::Pops::FirstFoundStrategy:0x00000003459e78 @options_t=#<Puppet::Pops::Types::PStructType:0x00000003454310 @elements=[#<Puppet::Pops::Types::PStructElement:0x00000003454360 @key_type=#<Puppet::Pops::Types::POptionalType:0x00000003454388 @optional_type=#<Puppet::Pops::Types::PStringType:0x00000003454400 @size_type=nil, @values=["strategy"]>>, @value_type=#<Puppet::Pops::Types::POptionalType:0x00000003454518 @optional_type=#<Puppet::Pops::Types::PPatternType:0x00000003454540 @patterns=[#<Puppet::Pops::Types::PRegexpType:0x00000003454680 @pattern="first", @regexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::restart in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: Evicting cache entry for environment 'production'
==> default: Debug: Caching environment 'production' (ttl = 0 sec)
==> default: Debug: Performing a hiera indirector lookup of mongodb::server::master with options {:variables=>Scope(Class[Mongodb::Server]), :merge=>#<Puppet::Pops::FirstFoundStrategy:0x00000003783c20 @options_t=#<Puppet::Pops::Types::PStructType:0x00000003765310 @elements=[#<Puppet::Pops::Types::PStructElement:0x00000003765360 @key_type=#<Puppet::Pops::Types::POptionalType:0x00000003765388 @optional_type=#<Puppet::Pops::Types::PStringType:0x00000003765568 @size_type=nil, @values=["strategy"]>>, @value_type=#<Puppet::Pops::Types::POptionalType:0x00000003765a68 @optional_type=#<Puppet::Pops::Types::PPatternType:0x00000003765a90 @patterns=[#<Puppet::Pops::Types::PRegexpType:0x000000037660f8 @pattern="first", @regexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::master in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: Evicting cache entry for environment 'production'
==> default: Debug: Caching environment 'production' (ttl = 0 sec)
==> default: Debug: Performing a hiera indirector lookup of mongodb::server::slave with options {:variables=>Scope(Class[Mongodb::Server]), :merge=>#<Puppet::Pops::FirstFoundStrategy:0x00000003731a60 @options_t=#<Puppet::Pops::Types::PStructType:0x0000000371f2e8 @elements=[#<Puppet::Pops::Types::PStructElement:0x0000000371f338 @key_type=#<Puppet::Pops::Types::POptionalType:0x0000000371f3b0 @optional_type=#<Puppet::Pops::Types::PStringType:0x0000000371f400 @size_type=nil, @values=["strategy"]>>, @value_type=#<Puppet::Pops::Types::POptionalType:0x0000000371f6f8 @optional_type=#<Puppet::Pops::Types::PPatternType:0x0000000371f770 @patterns=[#<Puppet::Pops::Types::PRegexpType:0x0000000371f978 @pattern="first", @regexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::slave in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: Evicting cache entry for environment 'production'
==> default: Debug: Caching environment 'production' (ttl = 0 sec)
==> default: Debug: Performing a hiera indirector lookup of mongodb::server::only with options {:variables=>Scope(Class[Mongodb::Server]), :merge=>#<Puppet::Pops::FirstFoundStrategy:0x000000036e3e28 @options_t=#<Puppet::Pops::Types::PStructType:0x000000036cb6e8 @elements=[#<Puppet::Pops::Types::PStructElement:0x000000036cb710 @key_type=#<Puppet::Pops::Types::POptionalType:0x000000036cb738 @optional_type=#<Puppet::Pops::Types::PStringType:0x000000036cb7d8 @size_type=nil, @values=["strategy"]>>, @value_type=#<Puppet::Pops::Types::POptionalType:0x000000036cb8c8 @optional_type=#<Puppet::Pops::Types::PPatternType:0x000000036cb8f0 @patterns=[#<Puppet::Pops::Types::PRegexpType:0x000000036cba58 @pattern="first", @regexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::only in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: Evicting cache entry for environment 'production'
==> default: Debug: Caching environment 'production' (ttl = 0 sec)
==> default: Debug: Performing a hiera indirector lookup of mongodb::server::source with options {:variables=>Scope(Class[Mongodb::Server]), :merge=>#<Puppet::Pops::FirstFoundStrategy:0x000000036b2058 @options_t=#<Puppet::Pops::Types::PStructType:0x000000036a1ca8 @elements=[#<Puppet::Pops::Types::PStructElement:0x000000036a1cd0 @key_type=#<Puppet::Pops::Types::POptionalType:0x000000036a1cf8 @optional_type=#<Puppet::Pops::Types::PStringType:0x000000036a1d70 @size_type=nil, @values=["strategy"]>>, @value_type=#<Puppet::Pops::Types::POptionalType:0x000000036a1e88 @optional_type=#<Puppet::Pops::Types::PPatternType:0x000000036a1eb0 @patterns=[#<Puppet::Pops::Types::PRegexpType:0x000000036a2040 @pattern="first", @regexp=/first/>]>>>]>, @options={}>}
==> default: Debug: hiera(): Looking up mongodb::server::source in YAML backend
==> default: Debug: hiera(): Looking for data source nodes/localhost.localdomain
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/nodes/localhost.localdomain.yaml, skipping
==> default: Debug: hiera(): Looking for data source common
==> default: Debug: hiera(): Cannot find datafile /etc/puppetlabs/code/environments/production/hieradata/common.yaml, skipping
==> default: Debug: importing '/tmp/vagrant-puppet/modules-521b1b04f16d1c57100f192a69df90d4/mongodb/manifests/server/install.pp' in environment production
==> default: Debug: Automatically imported mongodb::server::install from mongodb/server/install into production
==> default: Debug: importing '/tmp/vagrant-puppet/modules-521b1b04f16d1c57100f192a69df90d4/mongodb/manifests/server/config.pp' in environment production
==> default: Debug: Automatically imported mongodb::server::config from mongodb/server/config into production
==> default: Error: Evaluation Error: Error while evaluating a Function Call, 'versioncmp' parameter 'a' expects a String value, got Undef at /tmp/vagrant-puppet/modules-521b1b04f16d1c57100f192a69df90d4/mongodb/manifests/server/config.pp:89:14 on node localhost.localdomain
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.
THE PUPPET FILE
Exec
{ path => ['/usr/sbin', '/usr/bin', '/sbin', '/bin', '/usr/local/bin'] }class apache {
case $operatingsystem {
centos, redhat :
debian, ubuntu :
{ $package_name = 'apache2' $service_name = 'apache2' $config_file = 'apache2.conf' $config_path = '/etc/apache2/' }}
package
{ $package_name: ensure => installed, }}
- — Preinstall Stage ---#
stage
{ 'preinstall': before => Stage['main'] }class install_packages {
package
}
- Declare (invoke) install_packages
class { 'install_packages': stage => preinstall }
- Setup your locale to avoid warnings
file { '/etc/default/locale': content => "LANG=\"en_US.UTF-8\"\nLC_ALL=\"en_US.UTF-8\"\n" }class
{ '::nodejs': nodejs_dev_package_ensure => 'present', npm_package_ensure => 'present', repo_class => '::epel', }
package
{ 'express': ensure => 'present', provider => 'npm', }package
{ 'mime': ensure => '1.2.4', provider => 'npm', }file
{ '/var/log/mongodb': ensure => directory, owner => $::mongodb::params::user, mode => '0775', notify => Service[$::mongodb::globals::service_name], require => User[$::mongodb::params::user] }class
{ 'mongodb::globals': manage_package_repo => false, # enable the 10gen repository server_package_name => 'mongodb-org', service_name => 'mongod', }->
class
#->
#class
Attachments
Issue Links
- duplicates
-
PUP-4780 enhance versioncmp() error checking as it only accepts strings
-
- Closed
-
- is duplicated by
-
MODULES-2988 Mongodb module unusable with puppet 4.3
-
- Closed
-