Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a few services in rc.d that aren't starting at boot time. I've done the update-rc.d, redoing it tells me that start/stop links are already in place, and I can start services manually by using service start.

One of these services (sabnzbdplus) was pulled from apt, the others are downloaded from git. None of them start up automatically.

Nothing seems to be on google other than reinstall the whole system. Any advice?

share|improve this question
    
Notably, this is using Ubuntu 12.04 – Zach Sheffler Aug 18 '12 at 22:12
up vote 2 down vote accepted

I corrected this problem by chuser'ing the files/directories that were involved (including settings). I believe this happened because starting and stopping services with sudo gives them root privileges, whereas they're run as the user account at startup.

share|improve this answer
1  
can you elaborate this? I'm struggling!! – Mild Fuzz Dec 8 '12 at 17:44
    
Please can you give detail steps. My system suddenly started this issue for 2 scripts. – vikas112 Feb 6 '13 at 21:33

A folder and subsequent files in 'nix are owned/operated by users+ groups + everyone else. When root owns a folder/files in that folder, only root can use those folder/files for any purpose unless permission is given to others to use those same folder/files.

In this case, the scripts are owned by root so any user will not be able to run them unless two things happen. 1) either root allows anybody else to run them by changing permissions to something like 777 (read, write and execute by anyone) or 2) including the user in the same group with root thereby allocating those same rights to the user.

Both are not the same however. 1 gives all users the right to use (maybe dangerous) whilst ownership stays with root but 2 shares ownership with user through inclusion in same group (exposure to only one user may be more manageable).

I tend to use 1 but that is personal preference and also cos I'm lazy as running one script like "sudo chmod -R 777 /etc/init.d/couchpotato" solves my problems (note my system is isolated so it works for me whereas 2 may be the best solution for open or not so closed systems. Hope that helps someone else

share|improve this answer
    
1) How is this related to the question? 2) What's the purpose of giving everybody write permission on system daemon start files? -1 – David Foerster May 25 at 23:43
    
Sorry. late night, right answer to wrong question – seanbw Jun 17 at 6:27
    
I actually have had this problem and there area couple of factors you should consider. – seanbw Jun 17 at 6:28
    
Sorry I was caught by the 5 min rule. – seanbw Jun 17 at 6:48

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.