Getting agent v3.4 to manage my services

35 views
Skip to first unread message

Jon Yeargers

unread,
Dec 30, 2013, 6:04:25 PM12/30/13
to puppet...@googlegroups.com
I have a group of services that are supposed to be maintained by puppet agent. Up until I moved from 2.6 to 3.4 they were kept up to date and running (as expected).

Since the upgrade of the puppet agent these services are no longer being monitored. I'm sure that the server is still seeing the files as errors in them are flagged. 

Running 'puppet agent --debug' shows the requests for 'service <name> status' go by and yet even though the service is not running there is no move to start it. Running the 'service <name> start' command starts the service normally.

So: what have I broken by upgrading my clients?  As I mentioned - this used to work.

Edson Manners

unread,
Dec 30, 2013, 6:11:30 PM12/30/13
to puppet...@googlegroups.com
I had this same problem and couldn't figure out why it did it. I was 
moving from 2.7.23 to 3.x and it was driving me nuts, I never found what 
was the exact cause as there weren't any errors showing up and ' puppet 
agent -t' ran clean.

I ended up blowing away my whole puppet/passenger/puppetdb install and 
starting from 3.4 in order to get past it. I wish you better luck.
--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/dba2294d-826c-46d1-817c-6fd383818220%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Jon Yeargers

unread,
Dec 31, 2013, 8:24:09 AM12/31/13
to puppet...@googlegroups.com
I corrected the problem by including this in my /etc/init.d/<script>:

if [ -e $PIDFILE ]
then
      exit 0
else
      exit 1
fi

Put this in a 'status' command for your service control script. It works in puppet v3.4.

Felix Frank

unread,
Jan 1, 2014, 12:54:38 PM1/1/14
to puppet...@googlegroups.com
Weird. This Should Not Have Worked in puppet 2.6 either.

Note that to make puppet work correctly with uncompliant initscripts,
you can pass 'hasstatus => false' to your service resources. There are
other parameters that make operation quite flexible. Please refer to the
puppet type reference e.g.
http://docs.puppetlabs.com/references/2.6.8/type.html#service

But yes, writing LSB compliant initscripts is the best way to go about this.

HTH,
Felix
Reply all
Reply to author
Forward
0 new messages