If Puppet is running on a Solaris server as an SMF service, and starts a long-running process - e.g. it starts a daemon via an init script - that process is within the same "contract" as the Puppet agent process. If the Puppet agent is stopped/restarted, SMF waits for the *contract* to finish, not just the agent process. As the daemon doesn't terminate, the contract doesn't finish within the configured timeout, and so SMF puts the service into "maintenance" state and sends *kill -9* to all processes still left in the contract.
It is possible to force a process to run in a new contract (e.g. using "/usr/bin/ctrun") and it would be useful if Puppet could support this on Solaris, so that the agent can be stopped/restarted without affecting services that it manages.
Steps to reproduce:
1. Configure and run a puppet agent as an SMF service (using the default "contract" model of service management).
(For example, install & configure the OpenCSW Puppet package)
2. Set puppet to manage a daemon that is started by an init script.
3. Try to stop the puppet agent.
4. Observe (from the service log files, server's messages file, and process listings) that the init-controlled daemon has been killed and the puppet agent service placed into "maintenance" state.
In my test scenario, Puppet was starting an exim daemon via an init script.