<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.6000.16525" name=GENERATOR>
<STYLE>
<!--
/* Font Definitions */
@font-face
        {font-family:宋体;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:Verdana;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:"\@宋体";
        panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        text-align:justify;
        text-justify:inter-ideograph;
        font-size:10.5pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:Verdana;
        color:windowtext;
        font-weight:normal;
        font-style:normal;
        text-decoration:none none;}
/* Page Definitions */
@page Section1
        {size:595.3pt 841.9pt;
        margin:72.0pt 90.0pt 72.0pt 90.0pt;
        layout-grid:15.6pt;}
div.Section1
        {page:Section1;}
-->
</STYLE>
</HEAD>
<BODY style="FONT-SIZE: 10pt; FONT-FAMILY: verdana">
<DIV dir=ltr align=left><SPAN class=554393722-07112007><FONT
face=verdana>Hi,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=554393722-07112007> MPI_Publish_name()
and MPI_Lookup_name() work as defined in MPI standard with the MPD process
manager. However MPD is only available on unix. You could try using MPD on unix
or cygwin (Install cygwin on windows. Compile MPICH2 and run using the MPD
process manager. See the user's guide for details.).</SPAN></DIV>
<DIV><SPAN class=554393722-07112007><FONT face=verdana> We are also in the
process of development of a new process manager which will replace SMPD. This
process manager will be available on windows as well as unix and will support
Publish/lookup (It should be available sometime early next
year.).</FONT></SPAN></DIV>
<DIV><SPAN class=554393722-07112007></SPAN> </DIV>
<DIV><SPAN class=554393722-07112007><FONT face=verdana>(Note: Part of the
problem why publish/lookup does not work as defined in the standard has to do
with the design of SMPD. SMPD, unlike MPD, does not have any prior
connection with other SMPDs before launching an MPI job and hence it is
difficult to publish names across multiple MPI jobs.)</FONT></SPAN></DIV>
<DIV><FONT face=verdana></FONT> </DIV>
<DIV><SPAN class=554393722-07112007><FONT
face=verdana>Regards,</FONT></SPAN></DIV>
<DIV><SPAN class=554393722-07112007>Jayesh</SPAN></DIV><BR>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma><B>From:</B> owner-mpich-discuss@mcs.anl.gov
[mailto:owner-mpich-discuss@mcs.anl.gov] <B>On Behalf Of </B>Jayesh
Krishna<BR><B>Sent:</B> Wednesday, November 07, 2007 2:37 PM<BR><B>To:</B>
'menglige'<BR><B>Cc:</B> 'mpich-discuss';
mpich2-maint@mcs.anl.gov<BR><B>Subject:</B> RE: [MPICH] a question about MPI -
Pblm in Publish/Lookup with SMPD<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana>Hi,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007> We are looking into
the problem (The problem is not in your code. It is a bug in the SMPD process
manager.). Meanwhile, as a workaround, try putting a barrier after publish
and before lookup and run the programs as below,</SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana> mpiexec -n 1 LookupClient.exe : -n 1
PublishServer.exe</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana> The excerpt from the modified files are given below for your
reference,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana>############# LookupClient.c
#######################</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT
face=verdana></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007><FONT face=verdana>int
main(..){</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007>...</SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007>
<P>MPI_Get_processor_name(processor_name,&namelen); </P>
<P>MPI_Barrier(MPI_COMM_WORLD);</P>
<P>MPI_Lookup_name(serv_name, MPI_INFO_NULL, port_name_out );</P></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007>...</SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=825482820-07112007>}</SPAN></DIV>
<DIV><FONT face=verdana></FONT> </DIV>
<DIV><SPAN class=825482820-07112007><FONT face=verdana>#############
PublishServer.c #######################</FONT></SPAN></DIV>
<DIV><SPAN class=825482820-07112007></SPAN> </DIV>
<DIV><SPAN class=825482820-07112007><FONT face=verdana>int
main(...){</FONT></SPAN></DIV>
<DIV><SPAN class=825482820-07112007>...</SPAN></DIV>
<DIV><SPAN class=825482820-07112007>
<P>MPI_Open_port(MPI_INFO_NULL, port); </P>
<P>printf(<FONT color=#a31515>"opened port...<%s>\n"</FONT>, port);</P>
<P>fflush(stdout);</P>
<P>merr = MPI_Publish_name( serv_name, MPI_INFO_NULL, port );</P>
<P>MPI_Barrier(MPI_COMM_WORLD);</P></SPAN></DIV>
<DIV><SPAN class=825482820-07112007>...</SPAN></DIV>
<DIV><SPAN class=825482820-07112007>}</SPAN></DIV>
<DIV><SPAN class=825482820-07112007><FONT
face=verdana></FONT></SPAN> </DIV>
<DIV><SPAN class=825482820-07112007><FONT
face=verdana>###############################################</FONT></SPAN></DIV>
<DIV><SPAN class=825482820-07112007></SPAN> </DIV>
<DIV><SPAN class=825482820-07112007><FONT face=verdana> Let us know if it
works for you.</FONT></SPAN></DIV>
<DIV><SPAN class=825482820-07112007></SPAN> </DIV>
<DIV><SPAN class=825482820-07112007><FONT
face=verdana>Regards,</FONT></SPAN></DIV>
<DIV><SPAN class=825482820-07112007>Jayesh</SPAN></DIV><BR>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma><B>From:</B> owner-mpich-discuss@mcs.anl.gov
[mailto:owner-mpich-discuss@mcs.anl.gov] <B>On Behalf Of
</B>menglige<BR><B>Sent:</B> Tuesday, November 06, 2007 7:12 PM<BR><B>To:</B>
mpich-discuss<BR><B>Subject:</B> [MPICH] a question about
MPI<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV>
<DIV><FONT face=Verdana></FONT></DIV><FONT face=Verdana></FONT></DIV>
<DIV><FONT face=Verdana>
<DIV><FONT face=Verdana>HELLO!</FONT></DIV>
<DIV><FONT face=Verdana> i hava two '.exe' ,and i want to send
message from one to the other. </FONT></DIV>
<DIV><FONT face=Verdana>i use 'mpiexec' to run send.exe </FONT></DIV>
<DIV><FONT face=Verdana>and then use 'mpiexec' to run receive.exe,</FONT></DIV>
<DIV><FONT face=Verdana>but there is an erro ,receive.exe can find the
published port .what 's wrong with me ??? (i hava attached my
code).</FONT></DIV><FONT face=Verdana>
<DIV>THANK YOU VERY MUCH <IMG src="cid:554393722@07112007-1827"></DIV>
<DIV> </DIV>
<DIV align=left>
<HR style="WIDTH: 122px; HEIGHT: 2px" SIZE=2>
</DIV>
<DIV><FONT color=#c0c0c0>menglige</DIV>
<DIV>2007-11-06</FONT></DIV></FONT></FONT></DIV></BODY></HTML>