Sponsored Content
Top Forums UNIX for Dummies Questions & Answers How do I find the correct environment variables for MPI? Post 302469195 by EinsteinMcfly on Friday 5th of November 2010 11:36:52 AM
Old 11-05-2010
How do I find the correct environment variables for MPI?

Hello all. I've been trying to install NWCHEM in parallel on a new cluster, and have been able to get it to work on single processors by ignoring any MPI environment variables.

This is, of course, pretty worthless. So I'm starting over and trying to get thing set up right for the MPI. The key variables are:
Code:
 USE_MPI="y"
MPI_LIB="/usr/lib64"
#  LIBMPI="/usr/lib64/OMPI/pgi/libmpi.so" ; export LIBMPI
MPI_INCLUDE="/usr/include"
USE_MPIF="y"

As far as I can tell, the MPI_INCLUDE is supposed to be the place where the mpi.h and/or mpif.h are which I think I have correctly. Also, the MPI_LIB is mean to have all of the libmpixxxxxetc, right? That leaves LIBMPI,which I THOUGH was supposed to be the location of the libmpi.so file, but when I set it that way and try to compile I get:
Code:
File with unknown suffix passed to linker: /usr/lib64/OMPI/pgi
/usr/lib64/OMPI/pgi: file not recognized: Is a directory
make: *** [all] Error 2

I get this error whether I include the "libmpi.so" part in the path or not. It appears that it's not finding what it needs in that folder, but then what is it that it's supposed to find?

Thanks for any help.

EMF

---------- Post updated 11-05-10 at 10:36 AM ---------- Previous update was 11-04-10 at 11:58 PM ----------

Sorry for the lack of proper code.

Is this in the correct forum? Is there a parallel forum that I'm missing?

Last edited by pludi; 11-05-2010 at 03:15 AM.. Reason: code tags, please...
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

what is the use of Environment variables

what is the actual use of environment variables. I know only PS1, LOGNAME, PS2 variables what are the other variables & what is there use (2 Replies)
Discussion started by: indianguru
2 Replies

2. Programming

environment variables

Hi! How-to get the environment variables in GNU. getenv() only fetches the ones that you can find under export (not the ones under declare)... best regars .David (2 Replies)
Discussion started by: Esaia
2 Replies

3. UNIX for Dummies Questions & Answers

environment variables

Hi Folks, Is it possible somehow to unset all the environment variables which have been defined before in UNIX (Solaris). Thanks, Slava (3 Replies)
Discussion started by: spavlov
3 Replies

4. UNIX for Dummies Questions & Answers

help..Environment variables...

hi, 1). i would like to know what is meant by environment variables? 2). is the number of envi variables is a constant number for unix systems? 3). how to see the list of envi variables (and the values of the envi variables)in a single command? 4). if this questions were already asked... (3 Replies)
Discussion started by: sekar sundaram
3 Replies

5. Programming

environment variables

hi, I want to create a new EV(Environment Variable) through a c program and I done this thing through setenv() method. But the newly created EV is not permanent, i.e. when I exit from the program the EV also no longer lives. But I want to make it a permanent EV for the current user. Actually I... (6 Replies)
Discussion started by: sumsin
6 Replies

6. Shell Programming and Scripting

environment variables

Hi, If i have a variable set and exported in my pofile file will that variable be available in all shell scripts created. Thanks, Radhika. (3 Replies)
Discussion started by: radhika03
3 Replies

7. Homework & Coursework Questions

Environment Variables

1. The problem statement: What is the mesg value set for your environment? If it is on, how would you turn off your current session? How would you set it permanently? 3. The attempts at a solution : Read Unix The textbook. 3rd chapter has many things like environment variables and... (5 Replies)
Discussion started by: mahinkhan22
5 Replies

8. Shell Programming and Scripting

Grep correct pattern with special character and variables

cat file time="north_south_east_west_08:00" location="A" start="left" status="ok" end="north" time="north_south_east_west_12:00" location="C" start="right" status="ok" end="south" time="north_south_east_west_23:00" location="G" start="left" status="ok" end="east"... (7 Replies)
Discussion started by: ctphua
7 Replies

9. HP-UX

Environment Variables

Hi All, I need to understand following three environment variables and their usages in HP Unix. _M_ARENA_OPTS _M_CACHE_OPTS PTHREAD_SCOPE_SYSTEM How does these environment variables influence multi threaded applciation and how do we decide the value of these variables? Is there... (0 Replies)
Discussion started by: angshuman
0 Replies

10. Shell Programming and Scripting

Passing variables to functtion - $@ is correct but $1 is not

Hello I have a problem in a calling function. #!/bin/bash # function SEARCH_IN_CURRENT_ITEM () { echo ° echo ° echo ° echo "PARAM : $@" local B_ITEM_A local B_ITEM_B B_ITEM_A="${1}" echo "B_ITEM_A : $B_ITEM_A" B_ITEM_B="$1" echo "B_ITEM_B :... (7 Replies)
Discussion started by: jcdole
7 Replies
mpicxx(1)							     Open MPI								 mpicxx(1)

NAME
mpicxx -- Open MPI C++ wrapper compiler SYNTAX
mpicxx [-showme|-showme:compile|-showme:link] ... OPTIONS
-showme Do not invoke the underlying compiler. Instead, show the command line that would be executed to compile the program. NOTE: If a non-filename argument is passed on the command line, the -showme option will not display any additional flags. For example, both "mpicxx --showme" and "mpicxx --showme my_source.c" will show all the wrapper-supplied flags. But "mpicxx -showme -v" will only show the underlying compiler name and "-v". -showme:compile Do not invoke the underlying C++ compiler. Instead, show the compiler flags that would be supplied to the C++ compiler. -showme:link Do not invoke the underlying C++ compiler. Instead, show the linker flags that would be supplied to the C++ compiler. See the man page for your underlying compiler for other options that can be passed through mpicxx DESCRIPTION
Conceptually, the role of these commands is quite simple: transparently add relevant compiler and linker flags to the user's command line that are necessary to compile / link Open MPI programs, and then invoke the underlying compiler to actually perform the command. As such, these commands are frequently referred to as "wrapper" compilers because they do not actually compile or link applications them- selves; they only add in command line flags and invoke the back-end compiler. Background Open MPI is comprised of three software layers: OPAL (Open Portable Access Layer), ORTE (Open Run-Time Environment), and OMPI (Open MPI). There are wrapper compilers for each layer; each layer's wrapper only links in the libraries relevant for that layer. Specifically, each layer provides the following wrapper compilers: OPAL opalcc and opalc++ ORTE ortecc and ortec++ OMPI mpicc, mpic++, mpicxx, mpiCC (only on systems with case-senstive file systems), mpif77, and mpif90. Note that mpic++, mpicxx, and mpiCC all invoke the same underlying C++ compiler with the same options. All are provided as compatibility with other MPI implementa- tions. The Fortran wrapper compilers for MPI (mpif77 and mpif90) will be inoperative and will return an error on use if Fortran 77 / Fortran 90 support was not built into the MPI layer. Overview mpicxx is a convenience wrappers for the underlying C++ compiler. Translation of an Open MPI program requires the linkage of the Open MPI- specific libraries which may not reside in one of the standard search directories of ld(1). It also often requires the inclusion of header files what may also not be found in a standard location. mpicxx passes its arguments to the underlying C++ compiler along with the -I, -L and -l options required by Open MPI programs. The Open MPI Team strongly encourages using the wrapper compilers instead of attempting to link to the Open MPI libraries manually. This allows the specific implementation of Open MPI to change without forcing changes to linker directives in users' Makefiles. Indeed, the specific set of flags and libraries used by the wrapper compilers depends on how Open MPI was configured and built; the values can change between different installations of the same version of Open MPI. Indeed, since the wrappers are simply thin shells on top of an underlying compiler, there are very, very few compelling reasons not to use mpicxx. When it is not possible to use the wrappers directly, the -showme:compile and -showme:link options should be used to determine what flags the wrappers would have used. For example: shell$ cc -c file1.c `mpicc -showme:compile` shell$ cc -c file2.c `mpicc -showme:compile` shell$ cc file1.o file2.o `mpicc -showme:link` -o my_mpi_program NOTES
It is possible to make the wrapper compilers multi-lib aware. That is, the libraries and includes specified may differ based on the com- piler flags specified (for example, with the GNU compilers on Linux, a different library path may be used if -m32 is seen versus -m64 being seen). This is not the default behavior in a standard build, but can be activated (for example, in a binary package providing both 32 and 64 bit support). More information can be found at: https://svn.open-mpi.org/trac/ompi/wiki/compilerwrapper3264 FILES
The string that the wrapper compilers insert into the command line before invoking the underlying compiler are stored in a text file cre- ated by Open MPI and installed to $pkgdata/mpicxx-wrapper-data.txt, where $pkgdata is typically $prefix/share/openmpi, and $prefix is the top installation directory of Open MPI. It is rarely necessary to edit this file, but it can be examined to gain insight into what flags the wrappers are placing on the command line. ENVIRONMENT VARIABLES
By default, the wrappers use the compilers that were selected when Open MPI was configured. These compilers were either found automati- cally by Open MPI's "configure" script, or were selected by the user in the CC, CXX, F77, and/or FC environment variables before "config- ure" was invoked. Additionally, other arguments specific to the compiler may have been selected by configure. These values can be selectively overridden by either editing the text files containing this configuration information (see the FILES sec- tion), or by setting selected environment variables of the form "OMPI_value". Valid value names are: CPPFLAGS Flags added when invoking the preprocessor (C or C++) LDFLAGS Flags added when invoking the linker (C, C++, or Fortran) LIBS Libraries added when invoking the linker (C, C++, or Fortran) CC C compiler CFLAGS C compiler flags CXX C++ compiler CXXFLAGS C++ compiler flags F77 Fortran 77 compiler FFLAGS Fortran 77 compiler flags FC Fortran 90 compiler FCFLAGS Fortran 90 compiler flags OMPI
Open MPI mpicxx(1)
All times are GMT -4. The time now is 01:32 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy