On 2013-02-12 00:23, Sašo Kiselkov wrote:
Just as a curious question, would a "kick" be functionally equivalent to
running the following 3 commands:

# svcadm clear <fmri>
# svcadm restart <fmri>
# svcadm enable <fmri>

In terms of such a simple chain, I'd position them in this order:

# svcadm restart <fmri>
# svcadm enable -t <fmri>
# svcadm clear <fmri>

If at the beginning the service is disabled or in maintenance,
the restart request is effectively (and - worse - quietly)
ignored. If the service is running, it is sent into restart.

If the service is disabled, it becomes enabled and starts up
as of the second command. Also, it is not clear if we want the
service to stick around after reboot if it was now explicitly
disabled, hence the temp-enablement.

And if it was failed, it is cleared as of the third one.

(Your ordering could restart it one or two extra times)

But yes, this is roughly the idea - with proper error-checking
and interactive (command-line oriented) status reporting too :)

//Jim



_______________________________________________
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss

Reply via email to