Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am using upstart for services on my servers. Writing a conf file and placing it in /etc/init is easy enough, but that doesn't seem to completely install. For one, the service --status-all doesn't list my new service. I checked and if I make a link in /etc/init.d to /lib/init/ubstart-job it'll show up in the status. But doing this manually makes me think I'm not doing it right, and there may well be other configuration steps which aren't being done.

What is the correct way to install an upstart service such that it is properly registered in all tools dealing with services?

share|improve this question
1  
This guy answered one of my questions using upstart service and gave a detailed explanation, it might point out a step that might have been missed askubuntu.com/a/278128/75967 –  Meer Borg May 24 '13 at 6:53

2 Answers 2

When you initially copy a new conf file into the /etc/init folder you need to call:

initctl reload-configuration

By this your upstart should be properly registered.

share|improve this answer
2  
So this correctly sets up the job (ie, start and stop work) but it doesn't make the job show up in status all. I still had to manually add it to /etc/init.d/ for that to happen. –  James McMahon May 8 at 14:32

Checkout the service manual:

service --status-all runs all init scripts, in alphabetical order, with the status command. This option only calls status for sysvinit jobs, upstart jobs can be queried in a similar manner with initctl list.

(emphasis added)

That's why adding it to /etc/init.d (where the sysvinit jobs are located) made that work. So: try running initctl list instead :) .

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.