Hi,

 Thanks for the info. I found why the service was returning 0 when
status was stopped. But the

 /sbin/service ypbind status is still getting puppet stuck. If I run
it by hand it works perfectly. But puppet gets stuck after doing it.

Cheers,
 Adri

On 10 November 2011 13:04, Dick Davies <rasput...@hellooperator.net> wrote:
> Is yum-updatesd status returning true?
> That would act as you describe.
>
> If so, you could either push out a fixed init script
> or set 'hasstatus => false' and use the pattern parameter instead.
>
> (I prefer the former myself, since I have other things (monit etc.)
> that I want to use service scripts with.
>
> On Thu, Nov 10, 2011 at 11:05 AM, Adrian Casajús <ad...@ecm.ub.es> wrote:
>> Hi all,
>>
>>   Puppet gets stuck in one machine after the line
>>
>> debug: Service[nis](provider=redhat): Executing '/sbin/service ypbind status'
>>
>> if I run by hand '/sbin/service ypbind status' it works properly:
>>
>> [root@host ~]# /sbin/service ypbind status
>> ypbind (pid  12605) is running...
>> [root@host ~]# echo $?
>> 0
>> [root@host ~]#
>>
>> Service definition is:
>>
>> service{ 'nis':
>>   name => $operatingsystem ? {
>>     'Scientific' => 'ypbind',
>>     'SLC' => 'ypbind',
>>     default => 'nis'
>>   },
>>   ensure => running,
>>   hasstatus => $operatingsystem ? {
>>     'Scientific' => true,
>>     'SLC' => true,
>>     default => false
>>   },
>>   require => [ Package[ 'nis' ], File[ '/etc/yp.conf', 'nisdomainfile' ] ]
>> }
>>
>>
>> And for another service status seems to report that's always running
>> when it's not:
>>
>> debug: Service[yum-updatesd](provider=redhat): Executing
>> '/sbin/service yum-updatesd status'
>> debug: Service[yum-updatesd](provider=redhat): Executing
>> '/sbin/service yum-updatesd stop'
>> notice: 
>> /Stage[main]/Yumsvc/Yumsvc::Disablesvc[yum-updatesd]/Service[yum-updatesd]/ensure:
>> ensure changed 'running' to 'stopped'
>>
>> I check:
>>
>> [root@host ~]# /sbin/service yum-updatesd status
>> yum-updatesd is stopped
>>
>> Run puppet again and get again:
>>
>> debug: Service[yum-updatesd](provider=redhat): Executing
>> '/sbin/service yum-updatesd status'
>> debug: Service[yum-updatesd](provider=redhat): Executing
>> '/sbin/service yum-updatesd stop'
>> notice: 
>> /Stage[main]/Yumsvc/Yumsvc::Disablesvc[yum-updatesd]/Service[yum-updatesd]/ensure:
>> ensure changed 'running' to 'stopped'
>>
>> Service definition is:
>>
>> service{ 'yum-updatesd':
>>   ensure => stopped,
>>   hasstatus => true
>> }
>>
>> I'd be thankful if anyone can give me some pointers on where to look at:
>>
>> Cheers,
>>  Adri
>>
>> --
>> 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+unsubscr...@googlegroups.com.
>> For more options, visit this group at 
>> http://groups.google.com/group/puppet-users?hl=en.
>>
>>
>
> --
> 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+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/puppet-users?hl=en.
>
>

-- 
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+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to