/srv/irclogs.ubuntu.com/2010/11/18/#upstart.txt

bancalHi! Let me ask one question...09:42
bancalI'm preparing an upstart job that has to be executed on shutdown (or reboot). That job absolutely needs the network and local drives to be read-write accessible.09:42
bancalI can't find any "require network" instruction in upstart documentation.09:42
bancalAfter some tests, it seems to be ok with these access, but how could I be sure that those resources won't be shut down before or during my job to run?09:43
bancalIt's running on Ubuntu 10.04LTS.09:43
toabctli use upstart in debian squeeze and wrote my own upstart script, but i always get:11:24
toabctlSetting up test (0.1+2814M-1) ...11:25
toabctlUsage: /lib/init/upstart-job {start|stop|restart|reload|force-reload}11:25
toabctlinsserv: warning: script 'test' missing LSB tags and overrides11:25
toabctlinsserv: Default-Start undefined, assuming empty start runlevel(s) for script `test'11:25
toabctlinsserv: Default-Stop  undefined, assuming empty stop  runlevel(s) for script `test'11:25
toabctlany ideas how to fix this?11:25
toabctlit's this bug report: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=59334811:29
JanCbancal: I suppose that job is a "task"?  I think it should have "start on stopping networking RESULT=ok" or something like that (see "man 7 stopping")15:58
bancalYes it's a task15:58
bancalI did : 15:58
bancalstart on starting rc RUNLEVEL=[06]15:59
bancalWhich seems to work ... I can't be sure if it's guaranteed to work...15:59
bancal"start on stopping networking RESULT=ok" ... is that not to late in the shut down process?16:00
JanCyeah, probably not networking, but something about network filesystems16:00
JanCwith your solution it will not run if you down the network for some other reason than shutdown, which is maybe what you want16:02
bancalThanks for your interest, sorry but I really have to leave now (will be back tomorrow 8AM - switzerland) I keep it connected in case you want to write some more ...16:16

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