Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
root@graphite-cache-24086:/etc/init# cat /etc/init/carbon-cache.conf
start on filesystem
stop on runlevel [06]
console output
pre-start script
echo test >> /tmp/upstart.log
end script
script
echo test2 >> /tmp/upstart.log
end script
root@graphite-cache-24086:/etc/init# service carbon-cache stop
carbon-cache stop/waiting
root@graphite-cache-24086:/etc/init# service carbon-cache stop
stop: Unknown instance:
root@graphite-cache-24086:/etc/init# service carbon-cache stop
stop: Unknown instance:
root@graphite-cache-24086:/etc/init# service carbon-cache start
carbon-cache start/running
root@graphite-cache-24086:/etc/init# tail /var/log/syslog
Dec 27 12:14:33 graphite-cache-24086 kernel: [9629016.431677] init: carbon-cache main process ended, respawning
Dec 27 12:15:01 graphite-cache-24086 CRON[14100]: (root) CMD (command -v debian-sa1 > /dev/null && debian-sa1 1 1)
Dec 27 12:17:01 graphite-cache-24086 CRON[14134]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Dec 27 12:19:53 graphite-cache-24086 kernel: [9629336.297018] init: carbon-cache main process (14169) terminated with status 1
Dec 27 12:19:53 graphite-cache-24086 kernel: [9629336.297066] init: carbon-cache main process ended, respawning
Dec 27 12:24:20 graphite-cache-24086 kernel: [9629603.087786] init: carbon-cache main process (14226) terminated with status 1
Dec 27 12:24:20 graphite-cache-24086 kernel: [9629603.087835] init: carbon-cache main process ended, respawning
Dec 27 12:25:01 graphite-cache-24086 CRON[14246]: (root) CMD (command -v debian-sa1 > /dev/null && debian-sa1 1 1)
Dec 27 12:25:42 graphite-cache-24086 kernel: [9629684.695995] init: carbon-cache main process (14277) terminated with status 1
Dec 27 12:25:42 graphite-cache-24086 kernel: [9629684.696042] init: carbon-cache main process ended, respawning
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment