/srv/irclogs.ubuntu.com/2009/02/19/#upstart.txt

sadmacsolrize: if you can talk Keybuk in to it we'll change00:00
sadmacI don't expect you will00:00
solrizewell it sounds like upstart is already ignoring some filename patterns, it's just a matter of documenting them00:01
sadmacI can't seem to find the code that does that right now...00:01
solrizehmm, i wonder if it is gone00:02
* sadmac wonders if it was in libnih00:04
sadmacyep00:05
sadmacfound it00:05
solrizebrb00:05
sadmacsolrize: .dpkg-*, *.rpm{save,orig,new}, *;d3adb33f; where d3adb33f is random hex.00:06
sadmacsolrize: and a few more now, it seems00:08
sadmacsolrize: *,v RCS CVS CVS.adm SCCS .bzr .bzr.log .hg .git .svn BitKeeper .arch-ids .arch-inventory {arch} _darcs *.swp *.swo *.swn .#* *~ *.bak *.BAK #*# .*00:10
sadmacsolrize: so revision control, editor tempfiles, and a few backups00:13
solrizeok, that is reasonable, they're not so uptight about the FHS thing.  or anyway the FHS spec says /etc contains conf files but it doesn't exclude other files (besides binaries)00:15
solrizere, had to talk to someone here in the office00:17
solrizeso how about add README-* to the list?  that's a unix tradition00:18
sadmacin tarballs00:18
solrizethe practice predates tarballs :)00:22
sadmacScott's the one you need to flagellate about that one.00:24
solrizeanyways i won't worry about it for now, there's too much else to figure out.  thanks00:26
sadmacnp00:27
solrizeis there someplace where upstart actions are logged?  02:36
sadmacsolrize: system log02:39
solrizeaha thanks02:41
solrizeinitctl reload says "initctl: invalid command: reload"02:44
sadmacsolrize: what do you want that to do?02:44
solrizeget upstart to reload the conf files02:44
solrizefaq.html says initctl reload does this02:45
sadmacsolrize: that's automatic. inotify02:45
solrizeit doesn't seem to have noticed changes that i made02:45
sadmacsolrize: restart the individual job(s) in question02:45
solrizehow?02:45
sadmacsolrize: 0.3.9?02:46
solrizehmm02:46
solrize0.3.802:46
solrizeic, it's out of sync with the web site02:46
solrizeit's what came on ubuntu gutsy, i think02:46
sadmacsolrize: initctl stop;initctl start02:46
solrize"missing job name"02:47
solrizeoh adding that02:47
sadmacheh02:47
solrizestill doesn't seem to notice the change.  it's running an old version of the file.02:48
sadmacwhat's different?02:49
solrizesec02:50
solrizei changed the name of an event and used initctl emit02:51
solrizebut it only recognizes the old name, not the new one02:52
solrizeand it runs the wrong command to start the service02:52
solrizei.e. i changed that too, but it runs the old one02:52
solrizebrb02:52
sadmachmm02:56
solrizeshould i kill -HUP the /sbin/init process?  is that where this runs from?02:58
sadmacthat would do it. On that version of upstart though it will cease to manage your existing processes02:59
solrizehmm02:59
solrizei better not do that then02:59
solrizedoes upstart care whether a conf file is owned by root or by a user?  i chowned it to myself so i could edit it without sudo03:02
solrizechowned back to root, no change03:03
sadmachmm03:03
sadmacany issues loading it should be in syslog03:03
solrizei just see a bunch of error messages there about how it couldn't run the old command03:04
sadmachmm03:04
solrizejust tried again, no change.  i wondered if it might auto-reload after 10 minutes or anything like that.03:25
sadmacno. it should be in there03:26
solrizeaccording to ls -lu  the file hasn't been accessed in the past 25 minutes03:27
solrizei will try renaming the file03:28
solrizeweird, now the job doesn't even show up in initctl list03:29
sadmacare you sure your syntax is right?03:29
solrizechecking syslog03:29
solrizethere's an erorr message03:30
solrize"duplicate value"03:30
solrizei have two exec commands, is that ok?  i thought i saw that in one of the examples03:31
sadmacnope03:31
sadmacnot ok.03:31
solrizeic03:31
solrizeok i deleted one of them03:31
solrizehmm i think htis is better, it seems to be trying to start the task and failing and respawning03:32
sadmacgood03:33
solrizethanks! i think i can add more tracing and figure out what's wrong from here03:35
sadmaccool03:35
solrizeis there a way to set the uid of an exec process, like cron has?03:38
solrizei guess "sudo -u username", hmm03:38
sadmacyeah. or su03:38
solrizestill seems to run as root03:40
sadmacthat doesn't make sense...03:41
solrize"exec sudo -u solrize /bin/bash scriptname...."03:41
sadmacmaybe an su thing03:42
sadmacexec su solrize - /bin/bash scriptname03:43
solrizetrying03:43
sadmacoh crap, that won't work03:43
sadmacexec su solrize "/bin/bash scriptname"03:43
solrizeok03:43
sadmacsu doesn't concatenate args03:43
solrizei need -c maybe ?03:44
sadmacthat too03:44
sadmac:)03:44
solrizesu -c "command" solrize03:45
sadmacthere we go03:45
solrizebah, still runs as root03:48
sadmacI have no idea why.03:49
solrizei'll keep tracing it, thanks for all the help03:49
sadmacnp03:50
solrizeaha, got it working.  i didn't realize that killing the service and letting it restart with "respawn" wouldn't reload the upstart task04:13
solrizethanks04:13
sadmacthat'd explain it.04:13
solrizeupstart is pretty cool but it really needs documentation04:13
sadmacpatchers wanted :)]04:16
solrizethere's a similar situation with the prog i'm working on... most of the code was written by a guy i'll call "bob" and there's no docs.  my manager used to keep asking if there are any resources i need, and my answer was always "yes, about 10 feet of ethernet cable"04:17
solrize"what do you want that for?"04:17
solrize"i want to tie bob to a chair and make him explain how the code works so i can document it"04:18
sadmacle sigh04:18
solrizehee04:22
=== sadmac_ is now known as sadmac
keesjsadmac: where to document?12:24
sadmac2keesj: document which?15:32
keesjsadmac2: I wonder where the documentation can be enhanced. I would fancy having a read syntax manual for each release18:47
sadmac2keesj: its neglected enough that I think you could pretty much do whatever you wanted :) Keybuk has been historically opposed to documenting a lot of it because he presently reserves the right to change any of it at any time.18:49
Keybukplus I like moving the files around ;)18:50
sadmac2that too18:50
Keybuk1.0 will probably be /etc/init/*.conf <g>18:51
sadmac2Keybuk: we're not in /lib anymore at least.18:51
Keybukwe've never been in /lib :p18:54
sadmac2Keybuk: we were hypothetically there once18:54
sadmac2It made me itchy.18:54
keesjtoday i created a bzr branch on launchpad of upstart18:54
Keybuksadmac2: I briefly considered it18:55
Keybukudev installs to there, but udev's rules are a programming language18:55
Keybukand you can simply "add lines of code" to that programming language to change its behaviour18:55
Keybukso it makes sense18:55
keesjI added support for loglevel in the /etc/init/init.conf file18:56
keesjwould like to get it in upstart http://bazaar.launchpad.net/~keesj/upstart/upstart-next/revision/96918:56
sadmac2Keybuk: what have you been working on code-wise? In addition to most of a Bison parser I've been ripping out start/stop on and looking at doing that job tree thing.18:56
Keybukhaven't18:57
* Keybuk bbl18:57
sadmac2oh good, I'll just go nuts then :)18:57
keesjOMG18:57
sadmac2keesj: yes?18:58
keesjwhat?18:58
sadmac2keesj: OMG?18:58
sadmac2you sounded excited...18:58
keesjno just the removal of start/stop 18:59
sadmac2yep18:59
sadmac2now its just on18:59
sadmac2or on/until18:59
* sadmac2 also bbl19:00

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