Newsgroups: comp.parallel.pvm
From: sarwar@up.edu (Mansoor Sarwar)
Subject: Help on pvm_spawn()
Organization: School of Engineering, University of Portland, Portland OR
Date: 16 Mar 1995 10:57:05 -0800

Hi 

I am a rookie in the PVM world and am trying to get the following 
program to run.  I think, I've followed everything according to the book, 
but when I run the program the following appears on the screen.  I have 
tried specifying full pathname for hello_2, which is in ~/pvm3/bin/ARCH 
(it's rightful place according to the pvm-book and a short tutorial that 
I grabbed off the net).  Any help will be appreciated.

BTW, I have tried some other pieces of codes that do not use pvm_spawn() 
and they work fine.  So, obviously, the problem is with pvm_spawn(), which 
cannot seem to find the executable.

Mansoor

----- Error Message ------------
10% hello
i'm t40004
cc = 0
SPAWN Error: No such file or directory
can't start hello_2

-------------------- Source Code ------------------
#include <stdio.h>
#include "pvm3.h"

main()
{
        int cc, tid;
        char buf[100];

        printf("i'm t%x\n", pvm_mytid());

        cc = pvm_spawn("hello_2", NULL, "upsun21.up.edu", "SUN4", 1, &tid);

        if (cc == 1) {
                cc = pvm_recv(-1, -1);
                pvm_bufinfo(cc, (int*)0, (int*)0, &tid);
                pvm_upkstr(buf);
                printf("from t%x: %s\n", tid, buf);

        }
        else {
                printf("cc = %d\n", cc);
                perror("SPAWN Error");
                printf("can't start hello_2\n");
        }

        pvm_exit();
}
-- 
-----------------------------------------------------


