/srv/irclogs.ubuntu.com/2007/02/10/#upstart.txt

_ion27C outside. \o/12:31
=== j_ack [n=rudi@p508DAD43.dip0.t-ipconnect.de] has joined #upstart
=== Amaranth [n=travis@ubuntu/member/Amaranth] has joined #upstart
=== Amaranth [n=travis@ubuntu/member/Amaranth] has joined #upstart
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
=== iSeriesTech [n=iSeriesT@64-17-87-28.co.warpdriveonline.com] has joined #upstart
=== int0x0c [n=ben@161.253.46.23] has joined #upstart
=== pkt [n=knoppel@athedsl-292867.otenet.gr] has joined #upstart
=== baze [n=baze@c217110.adsl.hansenet.de] has joined #upstart
=== phsdv [n=paul@dyn-83-156-79-127.ppp.tiscali.fr] has joined #upstart
=== juergbi [n=juerg@80-219-17-102.dclient.hispeed.ch] has joined #upstart
=== Md [i=md@freenode/staff/md] has joined #upstart
=== Keybuk [n=scott@wing-commander.netsplit.com] has joined #upstart
KeybukFeb 10 13:49:23 wing-commander init: /etc/event.d/4913: unable to read: Invalid argument02:49
Keybukgrr @ vim02:49
_ion:-\02:54
Keybukit really does write a file called 4913 into the current directory when you modify something02:54
Keybukgo figure02:54
_ionPerhaps the directory watching code should do something like "wait one second after things have stopped changing"02:55
_ionand then react02:55
_ionThat should take care of any evil things editors might do with temporary files.02:55
_ionThe very same feature would be useful in the future when "file/directory changing" can be used as triggers for upstart jobs.02:56
_ionI.e. "watch directory /foo, do this when things have changed and there have been no more changes for 15 seconds"02:57
Keybukyeah, will have to think how to smooth that kind of thing out02:59
Keybuk15s is a long time though02:59
_ionThat was just an example of an arbitrary number a user might choose.03:00
_ionNot something we'd want for watching /etc :-)03:00
_ion/etc/event.d even03:00
Keybukit's vaguely useful in many cases03:03
_ionA use case: i define a job that watches www-dir/apt-repo-incoming, and when one *minute* has passed from changes, it copies things to www-dir/apt-repo and runs falcon. I might want this because i manually copy things to it, and want to have up to a minute of time between copying individual files until the thing is actually triggered.03:03
Keybuksome editors just modify the file directly03:03
Keybuksome copy the file to a backup and modify the file itself03:03
_ionYeah.03:03
Keybuksome write a temporary file, and move it over the previous file03:03
Keybukat some point, I need to rethink the way process ids are stored in the Job04:45
Keybukright now there's just job->pid and job->aux_pid05:32
KeybukI'm temped to move the pid to underneath the process definition05:32
Keybukjob->process->pid, job->pre_start->pid, job->post_start->pid, etc.05:33
Keybukand then I could enum those05:33
Keybukjob->process[PROCESS_PRE_START] ->pid05:33
Keybukand then we can add arbitrary actions05:33
Keybukid = job_action_id (job, "reload");05:33
Keybukjob->process[id] ->pid05:33
=== theCore [n=alex@ubuntu/member/theCore] has joined #upstart
Keybukactually, I just found another reason to do that05:48
Keybukthen job->failed_state could actually be the *process* that failed :p05:48
Keybukhttp://rafb.net/p/fOPZlY98.html06:27
Keybuk^ \o/06:27
Keybukso, here's a poser07:00
Keybukwhen you change a job's configuration file, should it07:00
Keybuka) modify the configuration of the running job07:01
Keybukb) mark the running job to be deleted when it stops, and use the new configuration for any new instances started later07:01
Mdis implementing a actually possible?07:03
Keybuka is what is currently implemented07:04
Keybukbut I'm increasingly thinking it's wrong07:04
Keybukit works for debugging, "a quick edit to fix the job"07:04
Keybukbut I think in practice b is better, because changes to the job file are likely to be upgrades07:04
Keybukand you might end up with a post-stop script that wasn't intended for the running process, since it doesn't match what pre-start did at the time07:04
Keybuksilly things, like what if the upgrade changed the pid file location?07:05
Keybukor the run directory location07:05
Keybukthat's an issue we have todya07:05
Keybukwould be nice to fix it07:05
_ionb sounds good.07:11
theCorea) seems scary to me.07:31
theCoreit seems to beg for race-conditions07:32
Keybukyeah, like a pre-start script being run; the config file getting read; and a different process all together getting run afterwards07:34
=== AlexExtreme[T] [n=AlexExtr@frugalware/developer/AlexExtreme] has joined #upstart
MdKeybuk: yes, I agree that b would be better08:32
=== mbiebl [n=michael@e180064209.adsl.alicedsl.de] has joined #upstart
=== AlexExtreme [n=AlexExtr@frugalware/developer/AlexExtreme] has joined #upstart
AlexExtremeKeybuk, just found an upstart bug - if you hit ctrl+alt+del multiple times, it will try to shut down multiple times09:52
Keybukright, yes?09:53
AlexExtremewell, that shouldn't really happen, should it?09:53
Keybukdunno09:54
Keybukchange "stop on runlevel" to "stop on runlevel [^6] "09:54
Keybuk:p09:54
AlexExtreme:p09:54
mbieblKeybuk: I got a small problem with current svn10:02
mbieblSeems as if kill -s TERM 1 in postinst10:03
mbieblcauses upstart to run sulogin (which kills my keyboard on X)10:04
Keybukyes10:17
Keybukit does that10:17
Keybuknormally it kills the entire X server10:19
Keybuk        * WARNING: if you have any job declared "console owner" which is10:21
Keybuk          run by the "stalled" event, comment out the "start on" stanza10:21
Keybuk          before sending the TERM signal -- otherwise the newly started10:21
Keybuk          process will start that job, which will kill your running X10:21
Keybuk          server.10:21
mbieblHm, it didn't do that with <=0.3.210:25
mbieblIs that a recent change?10:25
Keybukyes10:26
Keybukit's a "lack of a feature"10:26
KeybukI disabled the stuff that serialised the state between upstart instances, because it was a mess and hard to maintain10:26
KeybukI plan to put it back sometime in the couple of releases10:26
mbieblok10:33
wasabi_hey, quicky casper question since I know ya'll know a lot about it. ;)10:39
wasabi_Trying to copy the feisty boot CD to a USB drive, to install on a system without a CD.10:39
wasabi_filesystem.squashfs is what casper needs to mount... the vmlinuz and initrd.gz are obvious. What option tells casper how to find filesystem.squashfs?10:40
Keybukit hunts for it10:40
Keybukit's in the casper-local initramfs script10:40
=== wasabi_ installs casper!
wasabi_would ideally just be an option to mount a certain efs2 partition with a static path. ...  *hopes*10:41
Keybukit might be10:41
wasabi_hopefully the initramfs does usb mass storage by default. =/10:41
Keybukit should10:41
Keybuk./usr/share/initramfs-tools/scripts/casper10:42
wasabi_hmm LIVEMEDIA maybe10:43
Keybukit might be fixed as /casper/*.squashfs10:44
wasabi_That'll be fine. I just have to be able to point it to /dev/sdb310:44
wasabi_And it has to wait for it to appear.10:44
wasabi_Or... /dev/sd something.10:44
wasabi_Actually I won't know.10:44
Keybukit should just fine it10:44
Keybukuh, find it10:44
wasabi_# or do the scan of block devices10:45
Keybukit checks all block devices10:45
wasabi_bah. grub doesn't like this. prints GRUB and dies.10:47
wasabi_wonder how I fix that one.10:48
wasabi_... how does grub find it's stage2 anyways?10:48
wasabi_well this is obnoxious.10:53
=== ..[topic/#upstart:Keybuk] : Upstart 0.3.5 | http://upstart.ubuntu.com/ | http://upstart.ubuntu.com/wiki/ | http://upstart.ubuntu.com/doc/getting-started.html | irc logs: http://people.ubuntu.com/~fabbione/irclogs | http://upstart.ubuntu.com/wiki/UpstartOnGentoo
wasabi_Odd. So I've got it booted into the initrd... casper breaks... probably can't find the livefs.11:02
wasabi_Guess I can just mount it manually.11:02
wasabi_nope. blah.11:05
wasabi_i've got it at an initramfs prompt though. that's good enough. i'm going on a road trip and at least needed it that far. ;)11:13
wasabi_I can do the rest by hand in the car.11:13

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