The following is a quote from "A Practical Guide to Ubuntu Linux" by Mark G. Sobell:
""The following administrator-defined job uses the exec keyword to execute a shell command. You can also use this keyword to execute a shell script stored in a file or a binary executable file.
$ cat /etc/event.d/mudat
start on runlevel 2
exec echo "Entering multiuser mode on " $(date) > /tmp/mudat.out
This file defines a task: It runs the echo shell command when the system enters multiuser mode (runlevel 2).""
As I've learnt one could use exec because exec does not return control to the original program.
My question is what exec for in the above example if anyway a task in the upstart system is a job that performs its work and returns to a waiting state when it is done.
Thanks in advance for your answers.
I've maarked the post as solved because I think I'm just careless - exec here is for a job to be monitored, just upstart syntax, right?
Last edited by newk; 09-30-2009 at 07:12 AM.