parallel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: job race!


From: Hans Schou
Subject: Re: job race!
Date: Wed, 24 Apr 2013 22:01:27 +0200


2013/4/24 Ozgur Akgun <ozgurakgun@gmail.com>
Hans,

On 24 April 2013 07:28, Hans Schou <chlor@schou.dk> wrote:
Use --joblog to get the execution time and after each job-line running jobs.txt add " ; killall racejobs ".

Does this make sence?

I don't think I understand this. Say we have the following job-list.

$ cat jobs.txt
sleep 2 ; echo 2 # job 1
sleep 7 ; echo 7 # job 2
sleep 3; echo 3 # job 3

ok, here is where I kill the job which takes time

$ cat jobs.txt 
sleep 7 ; killall sleep ; echo 7 # job 1
sleep 2 ; killall sleep ; echo 2 # job 2
sleep 5 ; killall sleep ; echo 5 # job 3

Then

parallel -j0 --joblog job.log < jobs.txt

but the result is not what is expected

$ sort -n -k4 job.log | head -n 2
Seq     Host    Starttime       Runtime Send    Receive Exitval Signal  Command
3       :       1366832563.661  2.124   0       0       0       0       sleep 5 ; killall sleep ; echo 5 # job 3

My idea was to stop the other jobs when the first one complete. They do get stopped but it is not the right result which is printed. Im sorry I can not come any closer but it might be posssible to do it.

/hans

reply via email to

[Prev in Thread] Current Thread [Next in Thread]