1

There seems to be no definitive solution for this, either in Ubuntu's official documentation or other sources of information.

In some places systemctl is suggested but I think Ubuntu does not support it for the moment.

Other suggestions include manually creating the links, but I feel there should be a better way. On the other hand there are graphical programs to achieve this, but what about servers without GUI?

In Fedora I don't think this is an issue. You can use chkconfig to add/remove a service from the startup sequence.

The equivalent of chkconfig for Ubuntu seems update-rc.d, but:

# update-rc.d modemmanager enable
update-rc.d: /etc/init.d/modemmanager: file does not exist

Since Ubuntu is the most used GNU/Linux distribution, I believe there must be a way to do this in the command line with a specific command.

João M. S. Silva
  • 263
  • 1
  • 2
  • 7
  • @lemonslice: If I read correctly, none of the solutions answers my question. – João M. S. Silva Aug 04 '15 at 15:12
  • Sorry I should have asked which version of Ubuntu you are using. Also, is echo manual | sudo tee /etc/init/modemmanager.override working for you? – lemonslice Aug 04 '15 at 15:13
  • @lemonslice: Sorry, I'm using Linux Mint based on Ubuntu 14.04, so it's not the most updated Ubuntu release. The command worked, but is it meant to enable or disable the service? It continued disabled. – João M. S. Silva Aug 04 '15 at 15:29
  • What do you want to achieve exactly? This is for upstart to determine which commands to start at reboot. – lemonslice Aug 04 '15 at 15:31
  • I'm sorry---what a mistake!---, I mixed my workstation with the server that I'm working on: the server release is Ubuntu 14.04.2. – João M. S. Silva Aug 04 '15 at 15:31
  • @lemonslice: ModemManager package changed some time ago, and now it runs modemmanager only when NetworkManager is running. Since I am not running NetworkManager, I have to run modemmanager on my own. So I'd like to chkconfig modemmanager on. – João M. S. Silva Aug 04 '15 at 15:35
  • So it is not working with the override file I proposed? – lemonslice Aug 04 '15 at 15:35
  • No, after reboot: $ cat /etc/init/modemmanager.override manual $ service modemmanager status modemmanager stop/waiting. Should I replace "manual" with "auto" or so? – João M. S. Silva Aug 04 '15 at 15:45
  • I think I'll have to run service modemmanager start from /etc/rc.local which seems a bad and dirty solution... – João M. S. Silva Aug 04 '15 at 16:18
  • First which flavor of Ubuntu are you running?.Is it Xubuntu,Ubuntu GNOME,Ubuntu Mate,Lubuntu or just plain old default Ubuntu. – The Intelligent Human Aug 04 '15 at 15:21
  • First, Mint is off-topic on this site. Mint is its own distribution. This site supports only official flavors of Ubuntu: Ubuntu Studio, Lubuntu, Xubuntu. Second, AFAIK Mint stil uses upstart, so you should use sudo service modemmanager stop to stop temporarily, or edit/move the appropriate file in /etc/init folder – Sergiy Kolodyazhnyy Aug 07 '15 at 07:32
  • @Serg Please read comment from Aug 4 at 15:31. I'm using Ubuntu. So, the conclusion is that there is no command to achieve this, I must tweak /etc/init/modemmanager, right? – João M. S. Silva Aug 08 '15 at 11:40

0 Answers0