/srv/irclogs.ubuntu.com/2011/04/24/#upstart.txt

bencccan I tell upstart not to restart a job?09:52
benccI have a job that already have a script that monitors it09:53
steffen_bdont put respawn in the job ?09:53
benccsteffen_b: checking my upstart script 09:56
benccsteffen_b: respawn should be outside of script, pre-stop... right?09:57
steffen_byep09:57
benccso I'll comment it out. thanks09:57
benccI feel a little guilty when using upstart because it is so much easier than init.d scripts09:57
steffen_byes indeed09:58
steffen_bbut general perception is09:58
steffen_bi dont know how this upstart works09:58
benccthat's why debian guys don't want it by default09:58
steffen_bat least this is what i get from our users (yavdr)09:59
steffen_bwell , there is plenty of room for improvement in upstart (or the way ubuntu is using upstart)09:59
benccwhat would you improve?10:00
steffen_bso from debian perspective i can understand it 10:00
steffen_bcheck the shutdown handling 10:00
steffen_bmissing 'user' still compared to start-stop-daemon 10:01
steffen_bmissing states 10:01
steffen_bif you get into the details , you get your hands dirty quickly 10:02
steffen_bbut i cant judge if its ubuntu or upstart 10:02
benccok10:03
* steffen_b is also just upstart user 10:03
steffen_bin a ubuntu based linux distro 10:03
benccif my server start script run in the background, how do I use it with upstart?10:04
benccI see the wiki but it mixes old and new releases10:05
bencchttp://upstart.ubuntu.com/wiki/Stanzas10:05
benccI guess I need to use daemon and than to tell it how to find the pid10:05
steffen_bi would say dont use a start script seperate from ubuntu job 10:05
steffen_bargh10:05
steffen_bupstart job i mean10:05
steffen_bupstart10:05
steffen_b:D10:05
steffen_bone second10:06
steffen_bhttp://upstart.at/10:06
benccmaybe I'll remove the part that run it in the background10:06
steffen_bhttp://upstart.ubuntu.com/cookbook/10:06
steffen_bfar better then the wiki10:07
benccthanks10:07
steffen_bif the server you try to start has a mode to run in foreground10:07
steffen_bthen use that in the job 10:07
steffen_bif possible10:08
steffen_beasier to get it right then 10:08
steffen_bhaving hard time with natty shutdown at the moment 10:09
benccok10:09
steffen_bsomeone here who can provide me some helping hand to track it down ? 10:10
benccstart myserver and stop myserver works15:34
benccbut when I'm trying "restart myserver" I'm getting stop/waiting after ~2 seconds15:34
benccwhy is that?15:35
JanCbencc: are you sure stop & start both work correctly?  (restart does exactly that, so there shouldn't be any difference)17:26
steffen_bgood practice is to use ps -ef 17:46
steffen_band compare it to initctl list or status myserver17:47
steffen_bif pid is matching main process all is fine17:47
steffen_bif you use script section for the main process17:47
steffen_bmake sure you use exec 17:48
steffen_bso script and daemon get the same pid17:48
benccJanC: they are working. not sure how I can check if they work correctly19:53
JanCjust one example of what could go wrong: what if upstart thinks myserver is stopped while it's still shutting down so that when it's restarted too fast some resources that myserver needs are still in use?19:59
JanCchecking logs might be useful20:00
benccJanC: how can I check the logs?20:18
benccmyserver is supposed to halt until it really stops20:18

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