Upstart is not seeing my new script

An easy way to check your script syntax is with the following command:

init-checkconf -d /etc/init/service_name.conf

I've found that even with a valid Upstart file if the file didn't exist when the server was booted last I have to reboot the server for Upstart to see the file.


Check the upstart logs (it's in /var/log/syslog) while reloading the configuration using initctl reload-configuration. If there is a syntax error, it will show up there. That's usually why you cannot use your new upstart configuration.


I feel kinda dumb... But here it is:

I missed the "end script" stanza from the very end of the upstart script...

post-start script
   echo "minecraft started"

should have been

post-start script
   echo "minecraft started"
end script

I'm not sure why it worked for @schkovich without the end script, though...

Tags:

Upstart