FAQ
Hi,

I have a service /etc/init.d/a that spawns multiple daemons b and c.

This manifest does not make much sense to me but… any tip?

service { 'a':
ensure => running,
pattern => ["/usr/local/bin/b", "/usr/local/bin/c"],
}

or should I test them individually?

service { 'a':
ensure => running,
pattern => "/usr/local/bin/b",
}

service { 'a':
ensure => running,
pattern => "/usr/local/bin/c",
}


or even other way around :)


thanks in advance

--
Frank

--
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.

Search Discussions

  • Jcbollinger at Oct 3, 2012 at 2:34 pm

    On Tuesday, October 2, 2012 11:47:43 AM UTC-5, ureal frank wrote:
    Hi,

    I have a service /etc/init.d/a that spawns multiple daemons b and c.

    This manifest does not make much sense to me but… any tip?

    service { 'a':
    ensure => running,
    pattern => ["/usr/local/bin/b", "/usr/local/bin/c"],
    }
    As far as I know, the 'pattern' parameter understands only a single
    pattern. What you have written probably won't do what you want.


    or should I test them individually?

    service { 'a':
    ensure => running,
    pattern => "/usr/local/bin/b",
    }
    service { 'a':
    ensure => running,
    pattern => "/usr/local/bin/c",
    }
    No, you cannot declare Service['a'] (or any other resource) twice.

    Your best bet would be to make the service control script /etc/init.d/a
    respond to the "status" command in an appropriate way (ideally as specified
    by the LSB; see
    http://refspecs.freestandards.org/LSB_3.1.1/LSB-Core-generic/LSB-Core-generic/iniscrptact.html),
    and leave off the 'pattern' parameter in the service declaration. If you
    are running a Puppet version older than 2.7.0 then you will also need to
    add "hasstatus => true" to the service parameters.


    John

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/NpAfZV6TrIkJ.
    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.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppuppet-users @
categoriespuppet
postedOct 2, '12 at 4:47p
activeOct 3, '12 at 2:34p
posts2
users2
websitepuppetlabs.com

2 users in discussion

Frank: 1 post Jcbollinger: 1 post

People

Translate

site design / logo © 2022 Grokbase