PTL logo

From: Jean-Michel.Perraud_at_[hidden]
Date: 2014-05-02 21:26:48


Brian, You are not far off having it working, by the sound of it. A post with an issue very similar to yours at least by the sound of it is http://stackoverflow.com/questions/14359981/mono-and-unmanaged-code-in-ubuntu . This may offer a workaround, though i am not sure what the issue described exactly was. I cannot look at my Debian box right now, which would be similar to Ubuntu. I can however report a working MPI setup on what I think is a CentOS or Suse system. I am using OpenMPI, loaded on that system with: module load openmpi/1.6.5 ldconfig then does not look to me like reporting the MPI libraries used: /sbin/ldconfig -p | grep mpi libexempi.so.3 (libc6,x86-64) => /usr/lib64/libexempi.so.3 So it is a bit of a temporary mystery that a sample worked: mpiexec -n 2 mono ./Hello.exe Hello, from process number 0 of 2 Hello, from process number 1 of 2 This works because the 'module' command updates the LD_LIBRARY_PATH env var: echo $LD_LIBRARY_PATH /apps/openmpi/1.6.5/lib:/apps/openmpi/1.6.5/lib/profilers:et caetara ls -l --color /apps/openmpi/1.6.5/lib/libmpi.* /apps/openmpi/1.6.5/lib/libmpi.la /apps/openmpi/1.6.5/lib/libmpi.so -> libmpi.so.1.0.8 /apps/openmpi/1.6.5/lib/libmpi.so.1 -> libmpi.so.1.0.8 /apps/openmpi/1.6.5/lib/libmpi.so.1.0.8 Hope this helps ________________________________________ From: mpi.net [mpi.net-bounces_at_[hidden]] on behalf of Brian [bpswenson_at_[hidden]] Sent: Saturday, May 03, 2014 8:11 AM To: mpi.net_at_[hidden] Subject: Re: [MPI.NET] Compiling in Ubuntu Ok so the last error was because /usr/local/lib wasn't in my LD_LIBRARY_PATH. That added I now get: Unhandled Exception: System.DllNotFoundException: mpi at (wrapper managed-to-native) MPI.Unsafe:MPI_Initialized (int&) at MPI.Environment.get_Initialized () [0x00000] in <filename unknown>:0 at MPI.Environment..ctor (System.String[]& args, Threading threading) [0x00000] in <filename unknown>:0 at MPI.Environment..ctor (System.String[]& args) [0x00000] in <filename unknown>:0 at MPIHello.Main (System.String[] args) [0x00000] in <filename unknown>:0 [ERROR] FATAL UNHANDLED EXCEPTION: System.DllNotFoundException: mpi at (wrapper managed-to-native) MPI.Unsafe:MPI_Initialized (int&) at MPI.Environment.get_Initialized () [0x00000] in <filename unknown>:0 at MPI.Environment..ctor (System.String[]& args, Threading threading) [0x00000] in <filename unknown>:0 at MPI.Environment..ctor (System.String[]& args) [0x00000] in <filename unknown>:0 at MPIHello.Main (System.String[] args) [0x00000] in <filename unknown>:0 MONO_LOG_LEVEL=debug mono TestMPI.exe gives me: Mono: DllImport loading library: '/home/brian/Code/C#/TestMPI/TestMPI/bin/Debug/libmpi.so'. Mono: DllImport error loading library '/home/brian/Code/C#/TestMPI/TestMPI/bin/Debug/libmpi.so: invalid ELF header'. Mono: DllImport loading location: 'libmpi'. Mono: DllImport error loading library: 'libmpi: cannot open shared object file: No such file or directory'. Mono: DllImport loading location: 'libmpi.so'. Mono: DllImport error loading library: 'libmpi.so: invalid ELF header'. Mono: DllImport loading: 'libmpi'. Mono: DllImport error loading library 'libmpi: cannot open shared object file: No such file or directory'. Mono: DllImport unable to load library 'libmpi: cannot open shared object file: No such file or directory ldconfig -p | grep libmpi gives: libmpi_f90.so.0 (libc6,x86-64) => /usr/lib/libmpi_f90.so.0 libmpi_f90.so (libc6,x86-64) => /usr/lib/libmpi_f90.so libmpi_f77.so.0 (libc6,x86-64) => /usr/lib/libmpi_f77.so.0 libmpi_f77.so (libc6,x86-64) => /usr/lib/libmpi_f77.so libmpi_cxx.so.0 (libc6,x86-64) => /usr/lib/libmpi_cxx.so.0 libmpi_cxx.so (libc6,x86-64) => /usr/lib/libmpi_cxx.so libmpi.so.0 (libc6,x86-64) => /usr/lib/libmpi.so.0 libmpi.so (libc6,x86-64) => /usr/lib/libmpi.so So now I'm kind of stuck again. On 05/02/2014 04:42 PM, Brian wrote: > So I grabbed the version on GitHub from late April. It compiles, > however all of the tests seem to fail and if I try to compile and run > a Hello program I get the following: > > Unhandled Exception: System.TypeInitializationException: An exception > was thrown by the type initializer for MPI.Unsafe ---> > System.DllNotFoundException: mpinet > at (wrapper managed-to-native) MPI.Unsafe:mpinet_MPI_COMM_WORLD () > at MPI.Unsafe..cctor () [0x00000] in <filename unknown>:0 > --- End of inner exception stack trace --- > at MPI.Environment..ctor (System.String[]& args) [0x00000] in > <filename unknown>:0 > at MPIHello.Main (System.String[] args) [0x00000] in <filename > unknown>:0 > [ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: > An exception was thrown by the type initializer for MPI.Unsafe ---> > System.DllNotFoundException: mpinet > at (wrapper managed-to-native) MPI.Unsafe:mpinet_MPI_COMM_WORLD () > at MPI.Unsafe..cctor () [0x00000] in <filename unknown>:0 > --- End of inner exception stack trace --- > at MPI.Environment..ctor (System.String[]& args) [0x00000] in > <filename unknown>:0 > at MPIHello.Main (System.String[] args) [0x00000] in <filename > unknown>:0 > > > > On 05/02/2014 03:09 PM, Brian wrote: >> Hello >> >> I'm trying to install MPI.NET in Ubuntu. >> >> The first issue that I came upon was saying there was no CIL >> assembler. Which I found the solution to is this: >> >> sudo ln -s /usr/bin/ilasm /usr/bin/ilasm2 >> >> by searching archives. Anyway now that finishes completely and when >> I type 'make' I get this: >> >> :~/Software/mpi.net-1.0.0$ make >> Making all in MPIUtils >> make[1]: Entering directory >> `/home/brian/Software/mpi.net-1.0.0/MPIUtils' >> make[1]: Nothing to be done for `all'. >> make[1]: Leaving directory `/home/brian/Software/mpi.net-1.0.0/MPIUtils' >> Making all in MPI >> make[1]: Entering directory `/home/brian/Software/mpi.net-1.0.0/MPI' >> Makefile:19: *** missing separator (did you mean TAB instead of 8 >> spaces?). Stop. >> make[1]: Leaving directory `/home/brian/Software/mpi.net-1.0.0/MPI' >> make: *** [all-recursive] Error 1 >> >> Line 19 of the makefile is: >> >> pkgdatadir = $(datadir)/mpi-net >> >> Not sure what to do here. Any suggestions would be welcome. >> >> Thank you >> > _______________________________________________ mpi.net mailing list mpi.net_at_[hidden] http://www.osl.iu.edu/mailman/listinfo.cgi/mpi.net