Hot answers tagged services
You can use the Upstart respawn feature. Use the upstart job for apache found here: https://bitbucket.org/CameronNemo/upstart-jobs/src/2090612200fa588412e3fe22aec5ba3747ae88d2/apache2.conf?at=master then just add a line that reads respawn.
my guess is that one of the commands in your pre-start script is failing (mkdir probably). Try appending with "|| true" pre-start script mkdir -p /var/run/myservice || true chown -R root:root /var/run/myservice || true end script You should see a pid appear after the initctl start myservice command
I seriously doubt that your system will be still in a useful state after disabling everything but sshd. For a status list of upstart services do: sudo service --status-all For System V services: sudo initctl list Disable anything that has a + or is listed as start/running with the appropriate commands. To state the blatantly obvious: if you do this ...
What you are looking for is called single user mode. It is a state where only the bare essential services required for the machine to run are running. You enter it either by booting with an 's' argument given to the kernel, or you can switch to it using init s. sshd is not normally considered an essential service though, so it would be stopped. To fix ...
sudo service network-manager restart nor: sudo service networking restart Doesn't work on Ubuntu server 14.04 only: sudo ifdown eth0:0 sudo ifup eth0:0 Works. Change eth0:0 to your interface.
Looking at the logs at /var/log/boot.log (location provided by Letizia), I found a very suspicious line: /etc/rc2.d/S80noderoot: 16: /etc/rc2.d/S80noderoot: forever: not found The command not being found pointed to it being a problem with the path. Sure enough, the lines export PATH=$PATH:/usr/bin export NODE_PATH=$NODE_PATH:/home/azureuser/npm/bin ...
Only top voted, non community-wiki answers of a minimum length are eligible