I'm already doing the start on starting mountall, but while the job is copying the directory some other jobs are processing. I don't know why, but when I do that the system simply stops (possibly triggers a deadlock) and after 2 minutes it says that the task modprobe is not responding for 120 seconds.
I figured that this task might be the module-init-tools, so I did: start on (starting mountall or starting module-init-tools) With that the system stops locking, but strangely my job runs twice. Is that expected? 2012/5/10 James Hunt <[email protected]> > On 10/05/12 14:25, Rogerio Vinhal Nunes wrote: > > Hi, I'm trying to make a diskless client with an Ubuntu image booting > from a read-only common root > > folder. > > > > To do so, we usually mount the /var partition in memory and populates it > with the read-only content > > so the services would work. But this seems to be causing some problems > due to the copy process > > taking some time while the other jobs are running. > > > > Is there a way to run a job before everyone else or making a job to > stall all other processes until > > it finishes? Without upstart we did this in the rc.sysinit script that > executed before the init scripts. > > > > At least an option to make part of the job synchronized would be nice. > > > > > Rogerio, > > If you haven't already done so, I recommend reading the Upstart Cookbook > [1]. > > For the scenario you describe you can create a job that specifies a 'start > on' condition of: > > start on starting mountall > > That job can mount /var and perform the copy. Crucially, the mountall job > will: > > - not run until your /var copy job has finished. > - will not mount /var itself in this scenario since will already be > mounted. > > This works because the 'starting' event is a "hook" which blocks. See: > > - http://upstart.ubuntu.com/cookbook/#event-types > - upstart-events(7) or > http://upstart.ubuntu.com/cookbook/#ubuntu-well-known-events-ubuntu-specific > > Kind regards, > > James. > > [1] - http://upstart.ubuntu.com/cookbook/ > -- > James Hunt > ____________________________________ > http://upstart.ubuntu.com/cookbook > http://upstart.ubuntu.com/cookbook/upstart_cookbook.pdf >
-- upstart-devel mailing list [email protected] Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/upstart-devel
