Hi List, I''ve tried searching for this more, but I cannot find the right documentation. I''ve setup a freebsd box as a node, with an sshd configuration module. This is its manifest/init.pp: class ssh { file { "sshd_config": path => "/etc/ssh/sshd_config", source => "puppet:///ssh/sshd_config", notify => Service[sshd] } service {"sshd": enable => true, ensure => ''running'', } } This works quite alright on the configuring part. Enabling is strange: I''ve already enabled the service in /etc/rc.conf, but writes out a file in /etc/rc.conf.d/sshd. But "ensure" doesn''t work. Perhaps it would if no one was logged in, as it seems to recognize one of the logged in users as a service. Imho the proper way to see if somethings already enabled is by executing: $ /etc/rc.d/sshd rcvar Testing the service: $ /etc/rc.d/sshd status I curious to what the common perception was when the service module was designed for freebsd; I don''t know if it''s a bug or an intended design :) I''m running puppet 0.24.4. Thanks in advance, --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Kai wrote:> But "ensure" doesn''t work. Perhaps it would if no one was logged in, > as it seems to recognize one of the logged in users as a service.Under Debian, we got bitten by the exact same problem when puppet tried to restart sshd after a configuration change. Thoses processes were interepreted by puppet as the service already running. 11862 ? Ss 0:00 sshd: francois [priv] 11864 ? S 0:00 sshd: francois@pts/0 The workaround we found out is to specify a pattern like "/usr/sbin/sshd" in the service. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Hi> I curious to what the common perception was when the service module > was designed for freebsd; I don''t know if it''s a bug or an intended > design :)I dunno a lot of FreeBSD, but maybe have a look @ the freebsd provider for the service. You can find it here: lib/puppet/provider/service/freebsd.rb as well according to http://reductivelabs.com/trac/puppet/wiki/TypeReference#service you might use the start and status parameters to change the behaviour. I don''t know if this might work, but I think it''s worth a try. greets pete --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---