[02:58] hello [02:58] in an upstart job, how can I specify the user to run the job as? [08:40] don't know [10:51] mcarter: I don't think there is a built in way. [10:51] mcarter: I'm using 'sudo -u user cmd' [10:52] "chdir /some/where", "exec sudo -u foo ./app" [10:53] Anyway, I came here with a question! :-D What's the best way to restart stuff? Make a script that is invoked by emitting something fancy? [10:54] Or using ... stop ... ; ... start ... manually. [10:55] there's a restart command? [10:58] Not with initctl in 0.3.9 (I'm using the latest Ubuntu LTS release) [10:59] So I guess it was added in 0.4.x or 0.5.0, darn it :-D [10:59] ah, no there's no restart there [11:00] stop && start is as close as you can get [11:00] though that's not entirely atomic, it's close enough [11:00] Yeah, but it will do. Thanks anyway :) [11:07] when I do "stop on starting service_xxx" in service_yyy and I start service_xxx. the service_xxx is not waiting for the service_yyy to stop [11:07] is there a wait around this? [11:07] to be stopped [11:09] err, it should [11:11] I am not sure what is indened. the reverse "start on starting an_other_service" does wait [11:12] which version of Upstart [11:12] so if (a = start on starting b) and I start B b will only reach started once a i staterd [11:12] 0.3.9 [11:14] Ok at leat I now know what is indened. I only discovered this recently because the stop script wat taking very long [11:15] WFM here [11:16] quest event.d# cat test-stopper [11:16] stop on starting test-starter [11:16] service [11:16] post-stop script [11:16] sleep 5 [11:16] end script [11:17] quest event.d# cat test-starter [11:17] service [11:17] -- [11:17] quest event.d# status test-stopper [11:17] test-stopper (start) running [11:17] -- [11:17] quest event.d# start test-starter | ts [11:18] Jan 09 11:16:54 test-starter (start) waiting [11:18] Jan 09 11:16:54 test-starter (start) starting [11:18] Jan 09 11:16:59 test-starter (start) pre-start [11:18] Jan 09 11:17:00 test-starter (start) spawned [11:18] Jan 09 11:17:00 test-starter (start) post-start [11:18] Jan 09 11:17:00 test-starter (start) running [11:18] note the 5s delay [11:19] yes, the problem is probably a little more complex , I just wrote about the same test and it "works" [11:21] what is ts? [11:30] timestamps its input? [12:12] I see [12:13] while read i ; date -n ; echo $i ; done [12:14] somethine like that :p [12:14] indeed [12:14] something like that , sorry for the spam [12:15] it's in moreutils in Debian/Ubuntu [12:16] 113 lines of perl :p [12:19] Well, its sloccount is 62. :-) === notting_ is now known as notting [16:17] notting: so what do we do about 450488? [16:17] I vote kill telinit u support [16:18] 1) fix it to translate job state [16:18] 2) fix it so it ignores 'u' [16:18] (*accepts the argument, but ignores it) [16:18] 1 isn't productive because the damn code isn't sitting still long enough [16:20] telinit u? [16:20] * Keybuk tries to remember his sysvinit [16:20] that's "reload configuration *and make changes to running state*" isn't it? [16:21] oh, no [16:21] telinit u is reexec [16:21] I thought you implemented that one? [16:21] I remember seeing some very very amusing code that had initctl send a special message to upstart, had upstart receive and process that message; and then just send itself SIGTERM [16:22] it loses track of job state [16:22] oh [16:23] that's just a general "not yet 1.0" bug ;) [16:23] I fully intend to have state passing working before 1.0 [16:28] sadmac2: so, yeah. make it a no-op for now [16:29] notting: agreed [16:29] I'll do that when I get home [16:29] Keybuk: could you please weigh in on the new waitfd thread on lkml? [16:30] they're asking for why/wherefore stuff, and that's not my strong suit :)