[mpich-discuss] mpich problem.... net_send: could not write to fd=4,	errno = 32
    Luís Miranda 
    luistm at gmail.com
       
    Wed Feb  4 10:39:48 CST 2009
    
    
  
Hi. I'm trying to run this:
 /opt/mpich/gnu/bin/mpirun -v -np 2    -machinefile program
but i get this *error:*
i'm process 0 de 2...
ROOT:  trying to send message...
p0_26706:  p4_error: interrupt SIGSEGV: 11
Killed by signal 2.
p0_26706: (0.113281) net_send: could not write to fd=4, errno = 32
*This is the code:*
#include <stdio.h>
#include "mpi.h"
int main(int argc, char **argv){
    int message,
        rank,
        size,
        i,
        tag = 0,
        namelen;
    char processor_name[MPI_MAX_PROCESSOR_NAME];
    MPI_Status status;
    MPI_Init(&argc, &argv);
    MPI_Comm_rank(MPI_COMM_WORLD, &rank);
    MPI_Comm_size(MPI_COMM_WORLD, &size);
    printf("i'm process %d de %d...\n", rank, size);
    MPI_Barrier(MPI_COMM_WORLD);
    if(rank == 0){
        message = 1;
        for (i=1; i<size; i++){
            printf("ROOT: trying to send message...\n");
            MPI_Ssend(&message, 1, MPI_INT, i, tag, MPI_COMM_WORLD);
        }
    }else{
        printf("SLAVE %d: trying to receive message...\n", rank);
        MPI_Get_processor_name(processor_name,&namelen);
        MPI_Recv(&message, 1, MPI_INT, MPI_ANY_SOURCE, tag , MPI_COMM_WORLD,
&status);
        printf("SLAVE %d MAQUINA %s: receive message %d\n ",rank,
processor_name, message);
    }
    MPI_Finalize();
    return 0;
}
*And this is my machine file:*
beta.something.com
compute-1-0.local
compute-1-1.local
compute-1-2.local
Any solution?
Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/mpich-discuss/attachments/20090204/e38906d4/attachment.htm>
    
    
More information about the mpich-discuss
mailing list