0
votes

My Puppet master and agent are on the same machine. The master node.pp file contains this:

node 'pear.myserver.com' {
    include ntp
}

The ntp.pp file contains this:

class ntp {

    package { "ntp":
        ensure => installed
    }

    service { "ntp":
        ensure => running,
    }
}

The /etc/hosts file contains the line:

96.124.119.41   pear.myserver.com  pear

I was able to successfully launch puppetmaster, but when I execute this, ntp doesn't get installed (it is not installed already, I checked).

puppet agent --test --server='pear.myserver.com'

It just reports this:

info: Caching catalog for pear.myserver.com
info: Applying configuration version '1387782253'
notice: Finished catalog run in 0.01 seconds

I don't know what else I could have missed. Can you please help? Note that I replaced the actual server name with 'myserver' for security reasons.

I was following this tutorial: http://bitfieldconsulting.com/puppet-tutorial

1

1 Answers

1
votes
$puppet agent --test

This will fetch compiled catalog from Master puppet, which is in /etc/puppetlabs/puppet/manifests/site.pp and run locally.

$puppet apply /etc/puppet/modules/ntp/manifests/ntp.pp

Will apply locally