java.io.FileNotFoundException: null\conf\wrapper.conf (The system cannot find the path specified)
Asked Answered
C

3

2

I've been using this tutorial http://mpjexpress.blogspot.co.nz/2010/05/executing-and-debugging-mpj-express.html, text: steps 1,2,3 and video: steps between 0:00 to 3:29

Referenced files

build path
(source: iforce.co.nz)

Sample Code (Copy paste from the tutorial)

import mpi.*;
public class HelloEclipseWorld {
vpublic static void main(String[] args) throws Exception {
MPI.Init(args) ;
int rank = MPI.COMM_WORLD.Rank();
int size = MPI.COMM_WORLD.Size();
System.out.println("I am process <"+rank+"> of total <"+
size+"> processes.");
MPI.Finalize();
}
}

And I've included the mpi and mpj jar file from http://en.sourceforge.jp/projects/sfnet_mpjexpress/downloads/releases/mpj-v0_38.zip/ (as per tutorial step)

Then I set the run path configuration (as per tutorial step)

-jar ${MPJ_HOME}/lib/starter.jar

I also tried the same command but with -np 4 appended to the end (as per tutorial step)

-jar ${MPJ_HOME}/lib/starter.jar -np 4

VM arguments

mpi run config
(source: iforce.co.nz)

MPJ_HOME variable

mpi var
(source: iforce.co.nz)

MPJ Express Output

 MPJ Express (0.38) is started in the multicore configuration
 I am process <3> of total <4> processes
 I am process <3> of total <4> processes
 I am process <3> of total <4> processes
 I am process <3> of total <4> processes

Once I finished setting everything I try to execute it via Eclipse, but I'm getting these errors :(

Compiler Error

java.io.FileNotFoundException: null\conf\wrapper.conf (The system cannot find the path specified)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(Unknown Source)
at java.io.FileInputStream.<init>(Unknown Source)
at runtime.starter.MPJRun.getPortFromWrapper(MPJRun.java:807)
at runtime.starter.MPJRun.<init>(MPJRun.java:68)
at runtime.starter.MPJRun.main(MPJRun.java:964)

Wrapper.conf location

wrapper loc
(source: iforce.co.nz)

I'm slightly confused on why I'm getting these errors.. am I meant to do something else ? that the tutorial isn't telling me? in order to get this to work?

what am I doing wrong? how can I fix this JRE error? regarding the file "conf\wrapper.conf" on mpj express? I think I'm missing something but I've read so many resources and followed the tutorial over and over... but I'm still receiving the FileNotFoundException for wrapper.conf.

Some resources I've found (none answer the FileNotFoundException problem).

If anyone has any advice on how to fix the FileNotFoundException I'd greatly appreciate it thanks!

Cullet answered 22/5, 2012 at 7:25 Comment(0)
W
1

In the preferences menu go to run/debug --> String Substitution. Put your variable there. You are not dealing with an environment variable in this context. Environment variables will appear in totally platform specific way on windows you'll see %MJP_HOME% and on *nix it will look like $MJP_HOME in this case you are use Eclipse's string substitution mechanism

you can read about it here

Wessex answered 22/5, 2012 at 7:25 Comment(0)
R
1

Addressing the MPJ error

Error: Could not find or load main class runtime.starter.MulticoreStarter

To get it working.. go to Run Config -> Class Path, and under "Bootstrap" click "Add External JARS" and just include everything from /lib/ folder from mpj and that will make the mpj run, but I'm unsure on how you can address the compiler issues.

Romanic answered 22/5, 2012 at 7:51 Comment(1)
Thanks andrew mpj is now returning the expected output, :) I've updated the question, to try and address the compiler issues.Pallas
P
0

Addressing Compiler

java.io.FileNotFoundException: null\conf\wrapper.conf (The system cannot find the path specified) at java.io.FileInputStream.open(Native Method) at java.io.FileInputStream.(Unknown Source) at java.io.FileInputStream.(Unknown Source) at runtime.starter.MPJRun.getPortFromWrapper(MPJRun.java:807) at runtime.starter.MPJRun.(MPJRun.java:68) at runtime.starter.MPJRun.main(MPJRun.java:964)

My Lecturer told me I was missing the Enviroment Variable "MPJ_HOME", Run Config -> Enviroment Variables -> New "MPJ_HOME" (use the variable created for VM Arguments)

Pallas answered 22/5, 2012 at 7:25 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.