Thank all for helping to tackle this problem. Actually, my system administrator seems to have done something which makes my life much easier. Now, everything is done automatically. When the job is killed, I will get the following.<div>
<div>-------- .machine0 : 80 processors</div><div> Child id 1 Process termination signal received</div><div> Child id 2 Process termination signal received</div><div> Child id 3 Process termination signal received</div>
<div> Child id 4 Process termination signal received</div><div> Child id 5 Process termination signal received</div><div> Child id 6 Process termination signal received</div><div> Child id 7 Process termination signal received</div>
<div> Child id 19 Process termination signal received</div><div> Child id 24 Process termination signal received</div><div> Child id 35 Process termination signal received</div><div> Child id 40 Process termination signal received</div>
<div> Child id 77 Process termination signal received</div><div> Child id 53 Process termination signal received</div><div> Child id 59 Process termination signal received</div><div> Child id 69 Process termination signal received</div>
<div> Child id 20 Process termination signal received</div><div> Child id 28 Process termination signal received</div><div> Child id 37 Process termination signal received</div><div> Child id 42 Process termination signal received</div>
<div> Child id 72 Process termination signal received</div><div> Child id 48 Process termination signal received</div><div> Child id 57 Process termination signal received</div><div> Child id 70 Process termination signal received</div>
<div> Child id 21 Process termination signal received</div><div> Child id 25 Process termination signal received</div><div> Child id 32 Process termination signal received</div><div> Child id 46 Process termination signal received</div>
<div> Child id 73 Process termination signal received</div><div> Child id 49 Process termination signal received</div><div> Child id 60 Process termination signal received</div><div> Child id 64 Process termination signal received</div>
<div> Child id 23 Process termination signal received</div><div> Child id 26 Process termination signal received</div><div> Child id 33 Process termination signal received</div><div> Child id 41 Process termination signal received</div>
<div> Child id 76 Process termination signal received</div><div> Child id 50 Process termination signal received</div><div> Child id 56 Process termination signal received</div><div> Child id 68 Process termination signal received</div>
<div> Child id 17 Process termination signal received</div><div> Child id 27 Process termination signal received</div><div> Child id 38 Process termination signal received</div><div> Child id 47 Process termination signal received</div>
<div> Child id 78 Process termination signal received</div><div> Child id 51 Process termination signal received</div><div> Child id 62 Process termination signal received</div><div> Child id 65 Process termination signal received</div>
<div> Child id 18 Process termination signal received</div><div> Child id 30 Process termination signal received</div><div> Child id 34 Process termination signal received</div><div> Child id 43 Process termination signal received</div>
<div> Child id 74 Process termination signal received</div><div> Child id 52 Process termination signal received</div><div> Child id 58 Process termination signal received</div><div> Child id 66 Process termination signal received</div>
<div> Child id 22 Process termination signal received</div><div> Child id 31 Process termination signal received</div><div> Child id 39 Process termination signal received</div><div> Child id 44 Process termination signal received</div>
<div> Child id 75 Process termination signal received</div><div> Child id 54 Process termination signal received</div><div> Child id 61 Process termination signal received</div><div> Child id 67 Process termination signal received</div>
<div> Child id 16 Process termination signal received</div><div> Child id 29 Process termination signal received</div><div> Child id 36 Process termination signal received</div><div> Child id 45 Process termination signal received</div>
<div> Child id 79 Process termination signal received</div><div> Child id 55 Process termination signal received</div><div> Child id 63 Process termination signal received</div><div><br></div><div>
Yundi</div><br><div class="gmail_quote">On Fri, Jan 6, 2012 at 7:35 AM, Florent Boucher <span dir="ltr"><<a href="mailto:Florent.Boucher@cnrs-imn.fr">Florent.Boucher@cnrs-imn.fr</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Dear Laurence,<br>
your last lines are exactly what we need !<br>
Thank you for this.<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
set remote = "/bin/csh $WIENROOT/pbsh"<br>
<br></div><div class="im">
$WIENROOT/pbsh is just<br>
mpirun -x LD_LIBRARY_PATH -x PATH -np 1 --host $1 /bin/csh -c " $2 "<br>
</div></blockquote>
I will try but I pretty sure that it will work fine.<br>
Regards<br>
Florent<br>
<br>
Le 05/01/2012 20:16, Laurence Marks a écrit :<div><div></div><div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I gave a slightly jetlagged response -- for certain WIEN2k style works<br>
fine with all queuing systems.<br>
<br>
But...it may not fit how the queuing system has been designed and<br>
admins may not be accomodating. My understanding (second hand) is that<br>
torque is designed to work well with openmpi for accounting, and by<br>
default knows nothing about tasks created by ssh. When the users time<br>
has elapsed it will terminate those tasks it knows about (the main one<br>
plus anything using mpirun) and ignore anything else. Hence for<br>
clusters where killing a ssh on node A does not propogate a kill to<br>
children on node B (which depends upon the ssh) one is left with<br>
processes that can run forever. There is something called an epilog<br>
script which maybe can do this, but it would need WIEN2k to create one<br>
every time it launches a set of tasks. Possible, but not trivial.<br>
<br>
Note: this is not just a WIEN2k problem. One of the admin's at NU<br>
large cluster is a friend and he tells me that every now an then he<br>
goes around and tries to clean up tasks left running like this on<br>
nodes from all sorts of software. Sometimes he has to reboot nodes<br>
since if torque believes there is nothing running on a node it will<br>
merrily create more tasks on it which can lead to heavy<br>
oversubscription and hang the node.<br>
<br>
And...just to make life more fun, torque knows nothing about MKL<br>
threading so on an 8-core node can easily start 8 different non-mpi<br>
jobs and if they all want 8 threads...<br>
<br>
Probably too long a response. Below is the parallel_options file that<br>
I use on a system with moab (similar, perhaps worse than pbs) where I<br>
try and be a "gentleman" and set the mkl threading as well as use<br>
miprun to launch tasks.<br>
<br>
setenv USE_REMOTE 1<br>
setenv MPI_REMOTE 0<br>
setenv WIEN_GRANULARITY 1<br>
setenv WIEN_MPIRUN "mpirun -x LD_LIBRARY_PATH -x PATH -np _NP_<br>
-machinefile _HOSTS_ _EXEC_"<br>
set a=`grep -e "1:" .machines | grep -v lapw0 | head -1 | cut -f 3 -d:<br>
| cut -c 1-2`<br>
setenv MKL_NUM_THREADS $a<br>
setenv OMP_NUM_THREADS $a<br>
setenv MKL_DYNAMIC FALSE<br>
if (-e local_options ) source local_options<br>
set remote = "/bin/csh $WIENROOT/pbsh"<br>
set delay = 0.25<br>
<br>
$WIENROOT/pbsh is just<br>
mpirun -x LD_LIBRARY_PATH -x PATH -np 1 --host $1 /bin/csh -c " $2 "<br>
<br>
With this at least I don't create problems (hopefully).<br>
<br>
On Thu, Jan 5, 2012 at 7:19 AM, Peter Blaha<br>
<<a href="mailto:pblaha@theochem.tuwien.ac.at" target="_blank">pblaha@theochem.tuwien.ac.at</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
It is NOT true that queuing systems cannot do the "WIEN2k style".<br>
<br>
We have two big clusters and run on them all three types of jobs,<br>
i) only ssh (k-parallel), ii) only mpi-parallel (no mpi) and also<br>
of mixed type.<br>
<br>
And of course the administrators configured the "sun grid engine" so that it<br>
makes sure that there are no processes running when a job finishes and<br>
eventually<br>
kill all processes of a batch job on all the assigned nodes after it has<br>
finished.<br>
<br>
It's just a matter if the system programmers are willing (or able ??) to<br>
reconfigure<br>
the queuing system...<br>
<br>
PS: If you are running mpi-parallel use setenv MPI_REMOTE 0 in<br>
$WIENROOT/parallel_options and ssh will not be used anyway.<br>
<br>
Am 05.01.2012 13:17, schrieb Laurence Marks:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
As Florent said, this is a known issue with some (not all) versions ofssh,<br>
and it is also a torque bug. What you have to do is use mpiruninstead of ssh<br>
to launch jobs which I think you can do by setting theMPI_REMOTE/USE_REMOTE<br>
switches. I think I posted how to do this sometime ago, so please search the<br>
mailing list. (I am in China and canprovide more information next week when<br>
I return if this is notenough, which it probably is not.)<br>
N.B., in case anyone wonders with torque (PBS) you are not "supposedto"<br>
use ssh to communicate the way Wien2k does. They are not going tomove on<br>
this so this is "WIen2k's fault". I've looked in to this quitea bit and<br>
there is no solution except to avoid ssh (or live withzombie processes).<br>
Indeed, torque has the weakness of leavingprocesses around if a code does<br>
anything more adventurous than justrun a single mpirun -- so it goes.<br>
On Thu, Jan 5, 2012 at 3:22 AM, Peter Blaha<<a href="mailto:pblaha@theochem.tuwien.ac.at" target="_blank">pblaha@theochem.tuwien.<u></u>ac.at</a>><br>
wrote:> I've never done this myself, but as far as I know one can define<br>
a> "prolog" script in all those queuing systems and this prolog script><br>
should ssh to all assigned nodes and kill all remaining jobs of this<br>
user.>>> Am 05.01.2012 10:17, schrieb Florent Boucher:>>> Dear Yundi,>><br>
this is a known limitation of ssh and rsh that does not pass the<br>
interrupt>> signal to the remote host.>> Under LSF I had in the past a<br>
solution. It was a specific rshlsf for doing>> this.>> Actually I use<br>
either SGE or PBS on two different cluster and the problem>> exists.>> You<br>
will see that are not even able to suspend a running job.>> If some one has<br>
a solution, I will also appreciate.>> Regards>> Florent>>>> Le 04/01/2012<br>
21:57, Yundi Quan a écrit :>>>>>> I'm working on a cluster using torque<br>
queue system. I can directly ssh to>>> any nodes without using password.<br>
When I use qdel( or canceljob) j<br>
</blockquote>
obid to>>> terminate a running job, the>>> job will be terminated in the<br>
queue system. However, when I ssh to the>>> nodes, the job are still<br>
running. Does anyone know how to avoid this?>>>>>>>>>>>><br>
______________________________<u></u>_________________>>> Wien mailing list>>><br>
<a href="mailto:Wien@zeus.theochem.tuwien.ac.at" target="_blank">Wien@zeus.theochem.tuwien.ac.<u></u>at</a>>>><br>
<a href="http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien" target="_blank">http://zeus.theochem.tuwien.<u></u>ac.at/mailman/listinfo/wien</a>>>><u></u>>>>>> -->><br>
------------------------------<u></u>------------------------------<u></u>------------->><br>
| Florent BOUCHER |>> |>> | Institut des Matériaux<br>
Jean Rouxel |Mailto:<a href="mailto:Florent.Boucher@cnrs-imn.fr" target="_blank">Florent.Boucher@cnrs-<u></u>imn.fr</a>>> |>> | 2, rue de la<br>
Houssinière | Phone: (33) 2 40 37 39 24>> |>> | BP 32229<br>
| Fax: (33) 2 40 37 39 95>> |>> | 44322 NANTES<br>
CEDEX 3 (FRANCE) |<a href="http://www.cnrs-imn.fr" target="_blank">http://www.cnrs-imn.fr</a>>> |>><br>
------------------------------<u></u>------------------------------<u></u>------------->>>>>>>><br>
______________________________<u></u>_________________>> Wien mailing list>><br>
Wien@zeus.theoc<br>
<a href="http://hem.tuwien.ac.at" target="_blank">hem.tuwien.ac.at</a>>><br>
<a href="http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien" target="_blank">http://zeus.theochem.tuwien.<u></u>ac.at/mailman/listinfo/wien</a>>>> -->><br>
P.Blaha><br>
------------------------------<u></u>------------------------------<u></u>--------------><br>
Peter BLAHA, Inst.f. Materials Chemistry, TU Vienna, A-1060 Vienna> Phone:<br>
<a href="tel:%2B43-1-58801-165300" value="+43158801165300" target="_blank">+43-1-58801-165300</a> FAX: <a href="tel:%2B43-1-58801-165982" value="+43158801165982" target="_blank">+43-1-58801-165982</a>> Email:<br>
<a href="mailto:blaha@theochem.tuwien.ac.at" target="_blank">blaha@theochem.tuwien.ac.at</a> WWW:> <a href="http://info.tuwien.ac.at/theochem/" target="_blank">http://info.tuwien.ac.at/<u></u>theochem/</a>><br>
------------------------------<u></u>------------------------------<u></u>-------------->>><br>
______________________________<u></u>_________________> Wien mailing list><br>
<a href="mailto:Wien@zeus.theochem.tuwien.ac.at" target="_blank">Wien@zeus.theochem.tuwien.ac.<u></u>at</a>><br>
<a href="http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien" target="_blank">http://zeus.theochem.tuwien.<u></u>ac.at/mailman/listinfo/wien</a><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
-- Professor Laurence MarksDepartment of Materials Science and<br>
EngineeringNorthwestern <a href="http://Universitywww.numis.northwestern.edu" target="_blank">Universitywww.numis.<u></u>northwestern.edu</a><br>
<a href="tel:1-847-491-3996" value="+18474913996" target="_blank">1-847-491-3996</a>"Research is to see what everybody else has seen, and to think<br>
whatnobody else has thought"Albert<br>
Szent-Gyorgi__________________<u></u>_____________________________<u></u>Wien mailing<br>
listWien@zeus.theochem.tuwien.<u></u>ac.athttp://<a href="http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien" target="_blank">zeus.theochem.<u></u>tuwien.ac.at/mailman/listinfo/<u></u>wien</a><br>
</blockquote>
<br>
--<br>
<br>
P.Blaha<br>
------------------------------<u></u>------------------------------<u></u>--------------<br>
Peter BLAHA, Inst.f. Materials Chemistry, TU Vienna, A-1060 Vienna<br>
Phone: <a href="tel:%2B43-1-58801-165300" value="+43158801165300" target="_blank">+43-1-58801-165300</a> FAX: <a href="tel:%2B43-1-58801-165982" value="+43158801165982" target="_blank">+43-1-58801-165982</a><br>
Email: <a href="mailto:blaha@theochem.tuwien.ac.at" target="_blank">blaha@theochem.tuwien.ac.at</a> WWW:<br>
<a href="http://info.tuwien.ac.at/theochem/" target="_blank">http://info.tuwien.ac.at/<u></u>theochem/</a><br>
------------------------------<u></u>------------------------------<u></u>--------------<br>
<br>
______________________________<u></u>_________________<br>
Wien mailing list<br>
<a href="mailto:Wien@zeus.theochem.tuwien.ac.at" target="_blank">Wien@zeus.theochem.tuwien.ac.<u></u>at</a><br>
<a href="http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien" target="_blank">http://zeus.theochem.tuwien.<u></u>ac.at/mailman/listinfo/wien</a><br>
</blockquote>
<br>
<br>
</blockquote>
<br>
<br>
<br>
-- <br>
------------------------------<u></u>------------------------------<u></u>-------------<br>
| Florent BOUCHER | |<br>
| Institut des Matériaux Jean Rouxel | Mailto:<a href="mailto:Florent.Boucher@cnrs-imn.fr" target="_blank">Florent.Boucher@cnrs-<u></u>imn.fr</a> |<br>
| 2, rue de la Houssinière | Phone: (33) 2 40 37 39 24 |<br>
| BP 32229 | Fax: (33) 2 40 37 39 95 |<br>
| 44322 NANTES CEDEX 3 (FRANCE) | <a href="http://www.cnrs-imn.fr" target="_blank">http://www.cnrs-imn.fr</a> |<br>
------------------------------<u></u>------------------------------<u></u>-------------<br>
<br>
______________________________<u></u>_________________<br>
Wien mailing list<br>
<a href="mailto:Wien@zeus.theochem.tuwien.ac.at" target="_blank">Wien@zeus.theochem.tuwien.ac.<u></u>at</a><br>
<a href="http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien" target="_blank">http://zeus.theochem.tuwien.<u></u>ac.at/mailman/listinfo/wien</a><br>
</div></div></blockquote></div><br></div>