Hi all
I''m on my first attempt to set up puppet and so far all is well but for
one
issue that I just don''t understand.
I''ve set up a class for ntp configuration. This includes a subscribe
line
which for some reason won''t work when I try to subscribe to the package
ntp!
Here''s the class entry:
class ntp_service {
$ntp_servers = $subnet ? {
''82.112.122.128'' =>
[''82.112.122.129''] ,
''172.16.6.0'' => [''62.73.186.194'']
}
file { "ntp.conf":
path => "/etc/ntp.conf",
content => template("ntp.conf.erb")
}
service { ntp:
ensure => running,
subscribe => [file["ntp.conf"], package [ntp]]
#subscribe => [file["ntp.conf"] ]
}
}
When I run puppetd, I get the following error:
err: Could not retrieve object ''ntp'' of type
''Puppet::Type::Package'' in file
/etc/puppet/manifests/standard.pp at line 103
Puppet runs fine without the package entry.
I''m running on Debian Etch. I know for a fact that the package name is
ntp.
I don''t get this error for syslog-ng so I''m wondering
what''s so different
about ntp?
thanks in advance
Stephen
_______________________________________________
Puppet-users mailing list
Puppet-users@madstop.com
https://mail.madstop.com/mailman/listinfo/puppet-users
> > service { ntp: > ensure => running, > subscribe => [file["ntp.conf"], package [ntp]] > #subscribe => [file[" ntp.conf"] ] > } > }perhaps try package [''ntp'']] with '' to wrap it ? perhaps the package''s name is ntpd ? -- Cordialement, Ghislain _______________________________________________ Puppet-users mailing list Puppet-users@madstop.com https://mail.madstop.com/mailman/listinfo/puppet-users
> service { ntp: > ensure => running, > subscribe => [file["ntp.conf"], package [ntp]] > #subscribe => [file[" ntp.conf"] ] > } > } > > When I run puppetd, I get the following error: > > err: Could not retrieve object ''ntp'' of type ''Puppet::Type::Package'' > in file /etc/puppet/manifests/standard.pp at line 103 > > Puppet runs fine without the package entry. > > I''m running on Debian Etch. I know for a fact that the package name is > ntp. I don''t get this error for syslog-ng so I''m wondering what''s so > different about ntp?You haven''t actually told puppet to manage the package, eg: package { ntp: ensure => installed } The ''subscribe'' lines don''t handle installing the package. As far as I know, they just register the service instance to receive ''events'' from a specific package instance - which hasn''t been created yet.