Issue #15929 has been reported by Clay Caviness.

----------------------------------------
Bug #15929: launchd service provider can't handle malformed plists
https://projects.puppetlabs.com/issues/15929

Author: Clay Caviness
Status: Unreviewed
Priority: Normal
Assignee: 
Category: OSX
Target version: 
Affected Puppet version: 2.7.12
Keywords: 
Branch: 


If there's a zero-length or other un-parseable plist in the 
{/System}/Library/Launch{Daemons,Agents}/ directories, the launcd service 
provider gives up.

<pre>
$ sudo touch /Library/LaunchDaemons/foo
$ sudo puppet resource service
Could not run: Execution of '/usr/bin/plutil -convert xml1 -o /dev/stdout 
/Library/LaunchDaemons/foo' returned 1: /Library/LaunchDaemons/foo: Property 
List error: Cannot parse a NULL or zero-length data / JSON error: No value.
</pre>

There is a non-zero chance a zero-length file can show up if a puppet run is 
interrupted, leaving a file named something like 
`/Library/LaunchDaemons/com.company.foo.plist.puppettmp_2620`; after this tmp 
file is left, all further puppet runs will fail.

I think the provider should warn on parse/convert errors, but still continue on 
with those services it's able to read.


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en.

Reply via email to