/srv/irclogs.ubuntu.com/2009/03/08/#upstart.txt

=== sadmac_ is now known as sadmac
MarcWeberIs there some logging support again or do I have to use script\n &> /var/log/foo \n end script ?11:35
keesjin scripts?12:20
keesjin 0.5.x upstart self tries to use syslog, for scripts it should be possible to lot to syslog but I have not seen that work12:22
keesjthe "easy" thing to do IMHO is to use the logger command12:23
MarcWeberkeesj: It's about reading error messages from startup scripts etc.13:27
MarcWeberupstart-0.3 had its own (bitrotted) daemon to log stdout and stderr of the scripts into a file13:28
keesjMarcWeber: how is this daemon called it that hte logd?13:29
MarcWeberIt was called logd13:30
MarcWeberHowever using script &> file works fine in practise..13:30
keesjYes, , what I sometime do is a ( echo bla ; do this; echo bla ) | while read line ;do  echo "SCRIPT_NAME:" $line ; done13:33
geiseri_hi, i have a even  that needs to wait for hal to be loaded, is there a way with the current upstart in Ubuntu intrepid to do this?16:53
pktperhaps you mean a service that needs to wait for hal ?17:18
geiseri_well i want to start Xorg on boot for a live CD, but i guess the new Xorg wants to use hal to get input devices.17:19
geiseri_i had an upstart event script in event.d in hardy, but when i upgraded to intrepid it stopped working17:19
geiseri_diagnosis told me that it needed hal... so that is where i am stuck17:20
MarcWeberI'm trying to add upstart-0.5.1 support to nixos now. init ist started then nothing happens. Probably the job files aren't found? Is there a simpler way to debug this than patching upstart to support running as pid2 and running strace?19:07
sadmacMarcWeber: pass init=/sbin/init -v on the kernel command line19:13
damjanAnybody here? I'm installing Upstart in ArchLinux, and on startup I get a "unable to set oom adjustment" so the first job is not started19:14
sadmacdamjan: your initrd needs to mount /proc19:15
damjanit seems to me that upstart tries to write to /proc/xxx/oom_adj .. but /proc is not mounted when upstart 19:15
MarcWebersadmac :-) After starting udev before upstart I get some output as well now :-)19:15
damjansadmac: I'm not using a initrd19:15
MarcWeberdamjan: Mount proc before running upstart.19:15
sadmacdamjan: then it won't work right now (we don't like it either, it'll be fixed at some point. patches welcome)19:16
MarcWeberdamjan: Also make sure that your kernel supports it..19:16
MarcWeberif it doesn't you can still patch upstart.19:16
damjanMarcWeber: supports what?19:16
MarcWeberoom19:16
damjanit should, I see /proc/1/oom_adj19:17
damjanwhy is that needed at all? how about completelly disableing that part of the code?19:17
sadmacdamjan: go for it19:17
damjanwhat's the "But.." ? :)19:18
sadmacyou don't get OOM support, and there's no flag, so you're doing it on your own. In a text editor.19:19
geiseri_what are the files called in the /etc/events.d directory?  are those events themselves?19:19
sadmacgeiseri_: those are jobs19:19
sadmacgeiseri_: its a poorly named folder19:19
geiseri_okay, no problem19:19
geiseri_so is there a list of events that i can start on and stop on somewhere?19:19
MarcWebergeiseri_: initctl list will show them all19:20
sadmacMarcWeber: those are jobs19:20
MarcWeberoh. I've missed that. sry19:20
sadmacgeiseri_: there's an events manpage in fedora. think its on die.net too19:20
damjanwell ... ok, going to reboot to try this :)19:20
damjanbrb19:20
geiseri_okay, ill check there19:20
geiseri_im trying to start a job when hal is finished starting19:20
geiseri_if that is even possible right now19:21
sadmacstart on started hal19:21
* geiseri_ checks what he had19:21
geiseri_yeah i have that but it doesnt seem to be working19:22
geiseri_im on ubuntu intrepid, is this not supported in that version?19:22
sadmacare you starting on something else?19:22
MarcWebergeiseri_: You can log events when jobs are started..19:24
geiseri_im sorry im not parsing your question...  my line is "start of started hal" in my job in /etc/event.d/Xorg19:24
sadmacgeiseri_: on, not of19:24
geiseri_MarcWeber: that is the --debug flag you can pass to the boot args?19:25
geiseri_sadmac: im trying to launch Xorg right after hal is started successfuly 19:26
sadmacgeiseri_: then start on started hal19:26
MarcWebergeiseri_: Try grep init /var/log/messages. Maybe it is all there..19:26
sadmacgeiseri_: not of started, on started19:26
geiseri_sadmac: sorry i had a typo, that is what i have now... 19:27
sadmacgeiseri_: is the job that starts hal in fact named hal?19:27
geiseri_that im not sure... how would i find that out for certain?19:27
sadmacls /etc/events.d19:28
geiseri_ah, i dont have one in there, it seems ubuntu still uses the sysv init compat stuff19:28
geiseri_so im assuming ill never get an event from there19:28
sadmacprobably not. Fedora has some kinda chintzy event emulation for that stuff, but I don't think ubuntu followed on19:29
geiseri_ah okay19:29
geiseri_so if i put an initctl event hal in the end of my rc.local, that might do it?19:29
sadmacinitctl emint19:30
sadmac*emit19:30
sadmacyes, that'd do it19:30
geiseri_ah, right19:30
geiseri_okay, let me give that a whirl19:30
geiseri_sadmac okay that seems to have worked, thanks20:41
sadmaccool20:41
MarcWeberCan I syntax check job files somehow?20:47
geiseri_sadmac: hrm... only one problem when i do the emit the rc.local blocks... should i be doing "initctl emit xorg &" so it starts in the background?20:47
sadmacgeiseri_: initctl emit --no-wait I think was the option20:48
geiseri_ah20:48
geiseri_okay20:48
* geiseri_ checks the man page20:48
geiseri_that looks like it might do it20:50
MarcWeberCan the default PATH be set to a sensible default?21:01
MarcWeberOr do I have to use env PATH=... in all job files?21:02
sadmac_define sensible?21:03
MarcWebercontaining corutils such as touch and upstart itself..21:03
sadmac_don't think we have global environment. Might be a good RFE21:04
MarcWeberI don't mind adding env PATH=.. everywhere either21:04
MarcWeberIt does'nt matter that much because nixos does already have some kind of abstraction. adding this myself is done very fast.21:04
MarcWeberI think this differs from upstart-0.3 somehow21:05

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!