Questions tagged [upstart]

Upstart is an event-based replacement for the traditional init daemon used to perform tasks when the computer is started.

Upstart is an event-based replacement for the traditional init daemon used to perform tasks when the computer is started. Be sure to check out the cook book found at : http://upstart.ubuntu.com/cookbook/

545 questions
3
votes
1 answer

can't query upstart service status from cron job

I'm running Ubuntu 14 and I added the following line to my crontab: */1 * * * * : testing; /usr/sbin/service my-service status > ~/status 2>&1 After the next minute rolls around, I see this in ~/status: my-service: unrecognized service If I run…
nonagon
  • 3,271
  • 1
  • 29
  • 42
3
votes
1 answer

Direct output to syslog from upstart

With the changes to /dev/kmsg in Ubuntu 14.04 I'm not sure of a clean way to direct STDOUT/STDERR from an upstart script into the syslog. Formerly the script would look like this: script exec &> /dev/kmsg cd /var/www/app exec bin/puma -C…
Parker Selbert
  • 1,546
  • 13
  • 13
3
votes
1 answer

How to start a process with realtime priority (jackd) with upstart?

I'm trying to start jackd with realtime priority at boot with an upstart script but with no success so far. I'm using ubuntu server 14.04. My upstart version is 1.12.1. If I start jackd without realtime the upstart script works as intended. The user…
3
votes
1 answer

How to send an email notification on upstart reaching respawn limit?

Is it possible to send an email notification in case of upstart reaching the respawn limit? respawn respawn limit 5 60
Manuel
  • 9,112
  • 13
  • 70
  • 110
3
votes
1 answer

Change logging directory/file for an Upstart service

I have an upstart service that logs so much that it fills up all space on the hard drive. (This on the default 8GB HDD on an EC2 instance, so it is not a big surprise.) So I would like to change the name of the log file from /var/log/upstart/XYZ to…
David Nemeskey
  • 640
  • 1
  • 5
  • 16
3
votes
1 answer

How to change the default upstart log directory?

I have some upstart-started apps which log a lot of stuff... I want to be able to choose in which directory the upstart logs will be saved. The default is /var/log/upstart. In the upstart docs, they say I should give upstart a command-line option…
Renato
  • 12,940
  • 3
  • 54
  • 85
3
votes
3 answers

Run Upstart with Forever

We have a series of node.js scripts on an Ubuntu (13.10) server that we want to keep up and running as much as possible, and restart automatically in the event of a server reboot. We've tried a few different techniques, but have yet to find a…
hotshotiguana
  • 1,520
  • 2
  • 26
  • 40
3
votes
1 answer

Forever Node JS startup or stop/starting

I'm fairly new to all of this, so I apologize. My search has not yielded me an answer yet and I'm still testing around. I have an Node JS app thats started by Forever on Ubuntu 12.04 LTS. Several requirements I'm trying to figure out: Start…
nocode
  • 1,238
  • 1
  • 15
  • 21
3
votes
2 answers

Script not starting on boot with start-stop-daemon

My script (located in /etc/init.d) is creating a pid file ($PIDFILE), but there is no process running. My daemon script includes: start-stop-daemon --start --quiet --pidfile $PIDFILE -m -b --startas $DAEMON --test > /dev/null || return 1 The script…
mjpsr11
  • 595
  • 3
  • 10
  • 25
3
votes
3 answers

Source a file in upstart conf file

I am trying to create a service for tomcat on Ubuntu 12.10 using upstart. So, i created a tomcat.conf file in /etc/init description "Tomcat Server" start on runlevel [2345] stop on runlevel [!2345] respawn respawn limit 10 5 # run as non…
ufdeveloper
  • 387
  • 6
  • 19
3
votes
2 answers

Ubuntu upstart will hang on start/stop/etc

I've got a several services on Ubuntu which will start using 'upstart'. They are working as requested, but when I use 'stop/start/restart {myservice}' it will hang (but WILL do as requested). I understand it has something to do with forking. My…
3
votes
1 answer

Forever, node: Strange upstart behavior (restart behaving same as stop)

This is my upstart file /etc/init/myapp.conf on my Ubuntu 12.04. description "Example of starting Node with Upstart and Forever" start on filesystem or runlevel [2345] stop on runlevel [06] expect fork console output setuid lwood env…
lwood
  • 265
  • 1
  • 5
  • 10
3
votes
0 answers

upstart script for logstash, writing the pid file that deals with the fork

I am using the example upstart script for logstash but am having trouble writing a pid file for monit to use at /var/run/logstash.pid When i use "echo $$ > /var/run/logstash.pid" it writes the wrong pid value to file, I think its often the value…
henry.oswald
  • 5,304
  • 13
  • 51
  • 73
3
votes
1 answer

How to concatenate two string environment /w env stanza in Upstart?

Here is a part of my .conf file. env SERVICE_ROOT="/data/service_root" env LOG_DIR="$SERVICE_ROOT/logs" and I checked all variables with following.. echo "\n`env`" >> /tmp/listener.log 2>&1 I expect that $LOG_DIR is "/data/service_root/logs" but…
Younggun Kim
  • 938
  • 10
  • 26
3
votes
1 answer

Can't import readline in ruby script called by upstart

I'm trying to get a rails app to deploy with upstart. As part of this, I'm using an rbenv ruby (ruby 1.9.3p392, should it matter). Through a long string of debugging, I've got things down to what I think is a minimal test case. This script: require…
Nate
  • 4,561
  • 2
  • 34
  • 44