/etc/init.d/* status .. what to do when transitioning to an upstart job?

Clint Byrum clint at ubuntu.com
Fri Apr 15 03:25:30 UTC 2011


Excerpts from Dustin Kirkland's message of Thu Apr 14 13:37:45 -0700 2011:
> On Thu, Apr 14, 2011 at 3:11 PM, Kees Cook <kees at ubuntu.com> wrote:
> > On Thu, Dec 16, 2010 at 08:41:56AM +0100, Thierry Carrez wrote:
> >> Kees Cook wrote:
> >> >> /etc/service/status.d
> >> >>
> >> >> And if one exists for the job name, run it, otherwise just run the
> >> >> upstart status and provide an LSB compatible return code.
> >> >>
> >> >> This would also allow for the post-start stanza to call the same code if
> >> >> it is needed.
> >> >>
> >> >> Does anyone have strong thoughts on this? Given the service.d approach,
> >> >> it would seem the correct course of action is to open a feature request
> >> >> against sysvinit, document it in our upstart job writing best practices,
> >> >> and to document this feature in the server guide.
> >> >
> >> > Why should this be external to upstart? This seems to me like a clearly
> >> > missing feature in upstart itself. (i.e. a "status" stanza for services
> >> > that need a non-passive check.)
> 
> I agree, and we did talk about it at UDS-Natty in Orlando.  SJR
> disagreed with this vehemently, as I recall.
> 
> >> +1 on an optional, specific "status" stanza in upstart scripts. When
> >> present, it could be automatically called as a post-start before
> >> "started" is emitted, and would also be called when "status" is used.
> >
> > Has anything happened with this? Would this make a good UDS topic?
> 
> I'd think it would be a good one to re-visit, perhaps starting with a
> brief review of where we left it 6 months ago.  This is *definitely*
> something I personally miss, once an init script is converted to an
> upstart job.  "status $foo" tells me almost nothing interesting for
> most of my values of $foo today :-(
> 
If I recall, Scott's reluctance was in adding a 'status' stanza to upstart
jobs, because he felt it was beyond the scope of Upstart to provide any
type of "monitoring" for the service.

Scott, I hope you're reading this and can provide your own version of why
you feel the status functionality from LSB isn't needed in upstart jobs.

I'd like to discuss it again given 6 more months of users and developers
experience with upstart. I think its worthwhile to have a status stanza
that would be run on the 'status' command (or some other word to make
a clear distinction) and could be used in post-start stanzas.

We'll have another "upstart server enhancements" session, this seems
a good candidate for that discussion. I think the need for logging job
output overrides this one, but this might be the second most often cited
thing that I hear people ask for.



More information about the ubuntu-devel mailing list