[13:21] I'm writing an upstart script for an erlang server [13:21] the erlang server has a script that can start/stop/ping it [13:22] how do I combine it with the upstart script? [13:22] when using "status myserver" I guess I'm asking upstart what it thinks but this functionality is already implemented in the server itself [13:26] Upstart is designed with the idea that services don't just fall over by themselves and stay running [13:26] so you should find that your "status" script is unnecessary [13:27] gee, hang around for the answer, why don't you === apachelogger_ is now known as apachelogger [13:52] what is the upstart version on ubuntu 10.10? [13:57] benc: 0.6.7-1 currently [13:57] thanks [13:58] benc: http://launchpad.net/ubuntu/+source/upstart is the place to check that kind of thing out [14:01] ok [14:02] benc: before you vanished earlier, I was going to suggest the following [14:02] exec command-to-start-erlang-server [14:02] pre-stop exec command-to-stop-erlang-server [14:03] that may or may not work for you [14:03] if it doesn't, you may be able to do [14:03] pre-start command-to-start-erlang-server [14:03] post-stop command-to-stop-erlang-server [14:03] (with no exec or script) [14:03] err pre-start exec, post-stop exec [14:03] but no exec/script on their own [14:03] your first suggestion seems right [14:03] what about status? [14:04] which is ping in my server script [14:04] there isn't support for overriding that in 0.6 [14:04] because upstart assumes that if the pid is alive, then the service is running [14:04] and logs? [14:04] maybe if the pid is alive the erlang server is running. not sure [14:05] there's a conversation on ubuntu-devel about extending the "service" command to run custom status scripts [14:05] that might interest you [14:07] on ubuntu-devel in irc? [14:07] the mailing list [14:08] thanks. searching [16:11] is it possible to ensure a network-required upstart job (upon shutdown) will always have the network resources available? === mezcaler1 is now known as mezcalero [21:24] What would be a common reason why "stop foo" would hang? [21:27] upstart looking at the wrong PID ? [21:29] Possibly. [21:29] I guess this thing may not actually be daemonising properly. [21:31] Ah... [21:31] Right, of course. [21:32] * soren plays around a bit [21:44] Oh, I see what's going on. [21:44] Darn it. [21:44] I need a "expect ". [21:45] soren: good luck with that ;) [21:45] You need Upstart 0.10 :-) [22:23] soren: guessing you have a script + an oldschool daemon (forks twice) ?