/srv/irclogs.ubuntu.com/2007/03/05/#upstart.txt

=== cortana [n=sam@62-31-146-25.cable.ubr12.azte.blueyonder.co.uk] has joined #upstart
=== khermans__ [i=administ@nat/cisco/x-f8b562da6ccce3bd] has joined #upstart
=== eikniw [n=winkie@unaffiliated/eikniw] has joined #upstart
=== wasabi [n=wasabi@ubuntu/member/wasabi] has joined #upstart
=== wasabi_ [n=jhaltom@ubuntu/member/wasabi] has joined #upstart
=== j_ack [n=rudi@p508DC039.dip0.t-ipconnect.de] has joined #upstart
=== mbiebl [n=michael@e180098207.adsl.alicedsl.de] has joined #upstart
=== khermans__ [i=administ@nat/cisco/x-4a0c84b9d49c532f] has joined #upstart
=== pkt [n=pantelis@athedsl-135885.otenet.gr] has joined #upstart
=== urban__ [n=urban@xa147.internetdsl.tpnet.pl] has joined #upstart
=== urban__ is now known as urban
=== Starting logfile irclogs/upstart.log
=== ubuntulog [i=ubuntulo@ubuntu/bot/ubuntulog] has joined #upstart
=== Topic for #upstart: Upstart 0.3.5 | http://upstart.ubuntu.com/ | http://upstart.ubuntu.com/wiki/ | http://upstart.ubuntu.com/doc/getting-started.html | http://codebrowse.launchpad.net/~keybuk/upstart/main/changes | irc logs: http://people.ubuntu.com/~fabbione/irclogs | http://upstart.ubuntu.com/wiki/UpstartOnGentoo
=== Topic (#upstart): set by Keybuk at Tue Feb 13 18:08:07 2007
=== Keybuk [n=scott@quest.netsplit.com] has joined #upstart
=== mbiebl [n=michael@e180098207.adsl.alicedsl.de] has joined #upstart
=== Md [i=md@freenode/staff/md] has joined #upstart
Keybukhmm12:49
Keybukso "status foo", pretty obvious that should return one entry for a normal job12:49
Keybukand I think it's correct to return a list of jobs for an instance job12:50
Keybukbut should it also return the "master" job, which would always be stop/waiting12:54
Keybukor should I have a special message for an instance job list12:54
=== pkt [n=pantelis@85.75.154.205] has joined #upstart
=== j_ack [n=rudi@p508DC0A7.dip0.t-ipconnect.de] has joined #upstart
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
=== Keybuk starts tackling initctl
AlexExtremeheh05:38
AlexExtreme"Do not stand directly in front of this door."05:38
AlexExtremewell do you expect blind people to read it without going up to it? :p05:38
Keybukthat was my point :p05:39
AlexExtremeyeah i know ;)05:39
=== mbiebl [n=michael@e180106039.adsl.alicedsl.de] has joined #upstart
=== Mithodin [n=tux@p57A95222.dip.t-dialin.net] has joined #upstart
MithodinHello06:12
=== mbiebl [n=michael@e180106039.adsl.alicedsl.de] has joined #upstart
=== maro [n=mark@0x55511dab.adsl.cybercity.dk] has joined #upstart
=== j_ack [n=rudi@p508DC0A7.dip0.t-ipconnect.de] has joined #upstart
=== juergbi [n=juerg@80-219-17-102.dclient.hispeed.ch] has joined #upstart
=== khermans__ [i=administ@nat/cisco/x-4973a7fc3d4def11] has joined #upstart
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
=== Starting logfile irclogs/upstart.log
=== ubuntulog [i=ubuntulo@ubuntu/bot/ubuntulog] has joined #upstart
=== Topic for #upstart: Upstart 0.3.5 | http://upstart.ubuntu.com/ | http://upstart.ubuntu.com/wiki/ | http://upstart.ubuntu.com/doc/getting-started.html | http://codebrowse.launchpad.net/~keybuk/upstart/main/changes | irc logs: http://people.ubuntu.com/~fabbione/irclogs | http://upstart.ubuntu.com/wiki/UpstartOnGentoo
=== Topic (#upstart): set by Keybuk at Tue Feb 13 18:08:07 2007
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
=== AlexExtreme [n=AlexExtr@frugalware/developer/AlexExtreme] has joined #upstart
=== Keybuk [n=scott@wing-commander.netsplit.com] has joined #upstart
=== shawarma [n=sh@atlas.linux2go.dk] has joined #upstart
=== Keybuk is much happier
AlexExtremewhy's that?08:13
Keybukinitctl is turning out to be rather simpler with the new IPC messages08:14
AlexExtremecool08:14
mbieblKeybuk: I wanted to prepare a 0.3.5 release for experimental today. 08:33
mbieblGot a couple of questions08:34
Keybuksure08:34
mbieblIs console logged still unsafe?08:34
Keybukit's still disabled yeah, I haven't touched logd any further yet08:35
Keybukthe problem is the bad behaviour of just about every app when they can't write to stdout08:35
mbieblok, then I'll better also use console output then.08:35
mbieblThe next issue is rc0-poweroff/rc0-halt, which were obsoleted.08:36
Keybukhaven't traced it further; can't see why they terminate, rather than just ignore it08:36
Keybukyes08:36
Keybuksince we can transfer environment variables in an event, it made more sense for shutdown itself to set INIT_HALT, just as it did with sysvinit08:36
mbieblYou seem to backup them to dpkg-bak if they were modified in preinst. Why not just remove it?08:37
Keybukgeneral "don't remove other people's modified conffiles" behaviour08:38
mbieblYou also delete the unmodified ones in preinst, so they are still recorded as installed by dpkg08:38
Keybukthat's a dpkg bug08:38
Keybukolder dpkg behaves correctly08:38
Keybukthere's currently no way to remove a conffile without it still showing up in dpkg -L08:38
Keybukeven if it's not shipped in the current version of a package08:39
mbieblI tried it that way:08:39
mbieblmv the modified ones in preinst to .dpkg-bak, the unmodified ones to .dpkg-remove08:39
mbieblRemove .dpkg-remove files in postinst.08:39
mbieblIf upgrade fails, restore .dpkg-bak and .dpkg-remove files back.08:40
mbiebl(abort-upgrade in postinst)08:40
Keybukhow does that change it?08:42
Keybukdpkg still records the conffile, no?08:42
mbieblno, it doesn't08:42
Keybukahh08:42
Keybukinteresting08:42
Keybukthat's changed recently then08:43
Keybukshiny08:43
KeybukI'll update my functions accordingly08:43
mbieblIt also restores the state completely on an aborted upgrade.08:43
mbieblIf I rmmed the unmodified ones in preinst that wouldn't be possible.08:44
KeybukI rm them in postinst, no?08:44
mbieblYes.08:45
Keybukthe recipe always used to be:08:45
Keybuk  in preinst, move to dpkg.bak if modified, leave alone if not08:46
Keybuk  in postinst, remove if still exists08:46
Keybuk  in postrm abort-upgrade, rename .dpkg-bak back to the conffile08:46
Keybuk-- 08:46
Keybukso what happens there is the conffile is in place when the package is upgraded, so dpkg notes it in status as an obsolete08:46
Keybuklooks like dpkg has been fixed so dpkg actually stats the file, and doesn't note a missing file as obsolete now08:47
Keybukso the recipe should be:08:47
Keybuk  in preinst, move to .dpkg-bak if modified, .dpkg-remove if not08:47
Keybuk  in postinst, remove .dpkg-remove if it exists08:47
Keybuk  in postrm abort-upgrade, rename .dpkg-bak or .dpkg-remove back to the conffile08:47
Keybukyes?08:47
mbieblyeah, that's what I do currently.08:48
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
mbieblI just wanted to hear your thoughts on this, if you think this is the correct way (tm) to do it.08:48
Keybukthat makes perfect sense08:48
mbieblI really hoped dpkg would be a bit more clever in that regard.08:49
mbieblAnd did that automatically.08:49
Keybuk:D08:50
Keybuknote a bug in the Ubuntu upstart package08:50
Keybukmigrate-inittab generates the wrong runlevel event names08:50
mbieblI haven't synced this feature into the Debian postinst (yet)08:52
Keybuk*nods*08:53
Keybukbtw, woooooo shiny:08:53
Keybukwing-commander util% sudo ./initctl start tests/foo 08:53
Keybuktests/foo (start) waiting08:53
Keybuktests/foo (start) starting08:53
Keybuktests/foo (start) pre-start08:53
Keybuk        pre-start process 253308:53
Keybuktests/foo (stop) pre-start08:53
Keybuktests/foo (stop) stopping08:53
Keybuktests/foo (stop) killed08:53
Keybuktests/foo (stop) post-stop08:53
Keybuktests/foo (stop) waiting08:53
Keybukinitctl: tests/foo pre-start process killed by SEGV signal08:54
Keybuk-- 08:54
Keybukstart blocks until the job is running/finished, and returns an error if the job failed, and outputs all the interim process states08:54
mbiebloh, I remember another issue: postinst/purge08:55
mbieblI added a call to remove .dpkg-bak there.08:55
Keybukhmm, interesting08:55
Keybukhadn't previously considered that08:55
Keybukdoes dpkg remove modified configuration files on purge?08:55
mbieblyes, that's why I added it08:56
mbieblTo be compliant with dpkg's behaviour08:56
Keybuk*nods*08:58
Keybuk tests/foo (start) post-start08:58
Keybuk        main process 286508:58
Keybuk        post-start process 286608:58
Keybuk\o/08:58
mbieblDoes that mean, I could start a daemon in (pre|post)-(start|stop) (and have it monitored/respawned)?09:00
Keybukno, upstart wouldn't know the process id09:00
KeybukMar  5 19:59:52 wing-commander init: Caught segmentation fault, core dumped09:01
KeybukMar  5 20:00:23 wing-commander last message repeated 19073 times09:01
KeybukMar  5 20:01:24 wing-commander last message repeated 33310 times09:01
Keybukoops09:01
=== Md [i=md@freenode/staff/md] has joined #upstart
AlexExtremeKeybuk, that looks bad ;)09:06
KeybukAlexExtreme: yeah, haven't figured out a way to dump core *and* get over the problem instruction yet09:13
Keybukso when it SEGVs, it basically ends up in an infinite loop writing core to the disk09:13
AlexExtremeyes09:13
AlexExtremeso basically it needs to stop calling the function that's causing the SEGV if possible?09:14
Keybukright, but how do you do that?09:14
Keybukthe function has probably altered state09:14
Keybukso you have no idea whether the global state is consistent09:15
Keybukyou may have a job that has dangling pointers into the nether09:15
Keybukso you can't carry on, because you'll just dump core again09:15
AlexExtremeyep :/09:15
Keybukand you can't even reexec and transfer your state, because you could dump core while reexecing09:15
Keybukthe best solution so far is to reexec without transfering state09:15
Keybukwhich will cause X to crash :p09:15
AlexExtreme:)09:15
Keybukbut I figure X crashing is better than nothing09:15
AlexExtremeyes09:16
Keybukbrb, need to SUB09:25
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
=== Keybuk [n=scott@wing-commander.netsplit.com] has joined #upstart
Keybukright09:30
Keybukbetter09:30
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
Keybukthat works actually09:31
KeybukSEGV'ing init might crash X09:31
Keybukbut apport catches it09:31
Keybukso you get a friendly explanation *why* and can click to file a bug09:31
Keybukwhich is nice09:32
Keybukwing-commander util# ./initctl status tests/inst09:34
Keybuktests/inst (instance)09:34
Keybukwing-commander util# ./initctl start -n tests/inst09:34
Keybukwing-commander util# ./initctl start -n tests/inst09:34
Keybukwing-commander util# ./initctl start -n tests/inst09:34
Keybukwing-commander util# ./initctl status tests/inst  09:34
Keybuktests/inst (instance)09:34
Keybuk    (start) running09:34
Keybuk    (start) running09:34
Keybuk    (start) running09:34
Keybuk^ do we like that as a method for reporting instance jobs?09:34
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
Keybuk(and stop tests/inst stops every single instance)09:40
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
AlexExtremeKeybuk, looks good10:03
Keybukneeds some cleaning up, and testing but I'm pretty happy with it10:04
=== j_ack [n=rudi@p508DC0A7.dip0.t-ipconnect.de] has joined #upstart

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