<div>I didn't see any replies to my comments about the ui/output of "initctl list"... after some experimentation in the code, you can see what I came up with below.</div><div><br></div><div>1) I don't have any examples of multi-process services, so I edited the output to add a "fake" second process for rsyslog so you can see what it would look like.</div>
<div><br></div><div>2) the "xx:xx" is intended to be the length the process has been running. I'm working on filling in the real numbers now..</div><div><br></div><div>3) I'm thinking of adding a command/flag for a "machine readable" version of "list"... (the current list isn't very machine readable, but this format is less so)</div>
<div><br></div><div>4) I'm thinking about sorting this output, probably by prop-name.... </div><div><br></div><div>Thoughts?</div><div><br></div><div><br></div><div><div><font face="'courier new', monospace"><div>
root@w5:~/src2/upstart-0.6.5/util# ./initctl list</div><div> start/running xx:xx 634 rsyslog</div><div> xx:xx 999999 + (logger)</div><div> start/running xx:xx 675 tty4</div>
<div>
start/running xx:xx 308 udev</div><div> start/running xx:xx 304 upstart-udev-bridge</div><div> stop/waiting mountall-net</div><div> stop/waiting rc</div>
<div> stop/waiting screen-cleanup</div><div> stop/waiting ureadahead-other</div><div> start/running xx:xx 682 tty5</div><div> stop/waiting apport</div>
<div> stop/waiting console-setup</div><div> stop/waiting hwclock-save</div><div> stop/waiting irqbalance</div><div> stop/waiting plymouth-log</div>
<div> start/running xx:xx 702 atd</div><div> start/running xx:xx 31434 ssh</div><div> stop/waiting failsafe-x</div><div> stop/waiting plymouth</div><div>
start/running xx:xx 12964 dbus</div><div> stop/waiting control-alt-delete</div><div> stop/waiting hwclock</div><div> stop/waiting module-init-tools</div>
<div> start/running xx:xx 703 cron</div><div> stop/waiting mountall</div><div> start/running ufw</div><div> stop/waiting plymouth-stop</div>
<div>
stop/waiting rcS</div><div> stop/waiting mounted-varrun</div><div> stop/waiting rc-sysinit</div><div> start/running xx:xx 689 tty2</div><div>
stop/waiting udevtrigger</div><div> start/running xx:xx 690 tty3</div><div> stop/waiting mounted-dev</div><div> stop/waiting udev-finish</div>
<div> start/running xx:xx 10652 mysql</div><div> stop/waiting hostname</div><div> stop/waiting mountall-reboot</div><div> start/running network-interface (lo)</div>
<div> start/running network-interface (eth0)</div><div> start/running xx:xx 743 tty1</div><div> start/running xx:xx 19384 svscan</div><div> stop/waiting mountall-shell</div>
<div> stop/waiting mounted-tmp</div><div> stop/waiting plymouth-splash</div><div> stop/waiting udevmonitor</div><div> start/running network-interface-security (network-interface/eth0)</div>
<div> start/running network-interface-security (network-interface/lo)</div><div> start/running network-interface-security (networking)</div><div> start/running xx:xx 693 tty6</div>
<div> start/running xx:xx 25764 willow-smtpd</div><div> stop/waiting dmesg</div><div> stop/waiting networking</div><div> stop/waiting procps</div>
<div> stop/waiting ureadahead</div><div><br></div></font></div></div><div><br></div><br><br><div class="gmail_quote">On Thu, Mar 29, 2012 at 6:20 PM, David Jeske <span dir="ltr"><<a href="mailto:davidj@gmail.com">davidj@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div><div>2) I find the output of "initctl list" is pretty hard to human-parse and we use these command lines alot. "service --service-list" or "svstat *" is much easier to look at. Is there some reason for the format? Is it machine read? Are you folks open to patches to change/improve it? Of course we can just change our version, but I hate to maintain local changes like that. We'd probably just make wrappers instead.</div>
<div><br></div><div>Here are some examples:</div><div><br></div><div><div>[root@w1 service]# svstat shttpd</div><div>shttpd: up (pid 18292) 36899416 seconds</div></div><div><br></div><div><div>root@w5:~# service --status-all</div>
<div> [ + ] apache2</div><div> [ + ] apparmor</div></div><div>...</div><div><br></div><div>I think it would be best to separate a fully "script/machine readable" version of "initctl list" and a normal human version. Here is one proposal for a human readable version with a little more information..</div>
<div><br></div><div><span style="font-family:'courier new',monospace"> PID EVENT/STATE TIME SERVICE CAUSE</span></div><div><font face="'courier new', monospace"> 24883 stop/waiting 0d 32:22 httpd runlevel=5</font></div>
<div><font face="'courier new', monospace"> 690 start/running 0d 00:00 willow-smtpd usercmd: reload</font></div></div></div></div></blockquote><div><br></div></div>