Ask Your Question

smf provider forces use of -s flag

asked 2015-03-26 16:15:35 -0600

mydogspot gravatar image

I'm using puppet 3.7.4 running on rhel 6.6 and trying to manage ntp on solaris 11.2.

On the solaris server I can manually start ntp service with svcadm enable ntp, but if I use the -s flag, svcadm enable -s ntp it won't start because it says it has unsatisfied dependencies. So I don't care about the dependencies and I know ntp will start if i don't use the -s flag - but when my puppet agent runs it seems to insist on using the -s flag. My puppet code is really simple -

  'sun4v' : {
    file { '/etc/inet/ntp.conf':
    ensure => file,
    owner => 'root',
    group => 'root',
    source => 'puppet:///modules/ntp_new/ntp.sun',
    notify => Service['ntp']
    service { 'ntp' :
    ensure => 'running',
    enable => 'true',
    provider => 'smf',

Does anyone know if there is any way that I can force svcadm to not use the -s flag?

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2015-03-31 16:01:50 -0600

WhatsARanjit gravatar image

The provider is hard-coded to do this. You'd have to submit a pull request. Take a look at the code here:

edit flag offensive delete link more

answered 2015-04-06 22:06:02 -0600

rnelson0 gravatar image

You could pass valid restart/start/stop parameters to your Service resource. However, you should probably just satisfy the dependencies to ensure your puppet code describes an accurate state definition.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2015-03-26 16:15:35 -0600

Seen: 207 times

Last updated: Apr 06 '15