mpif90 download on RHEL


 
Thread Tools Search this Thread
Special Forums UNIX and Linux Applications High Performance Computing mpif90 download on RHEL
# 1  
Old 02-16-2009
Tools mpif90 download on RHEL

Hi,
I have installed mpif77 (a parallel wrapper for the fortran compiler g77) on my dual processor dual core workstation which has RHEL 4 as OS. This compiles and runs just fine.

Now I want to install mpif90 which is the f95 version of mpif77 (I think?). At the moment I am using the 'ifort' (which I have also installed) as the base compiler, hoping that it will compile ok. My make file is as follows:

# MAKEFILE FOR PARALELL EXECUTABLE OBJECT FOR "pards".

F90 = ifort
FFLAGS = -u -O3 -i8 -r8 -align all -check -fast -fp-model fast=1 -funroll-loops

#FFLAGS = -O3 -fno-second-underscore -fno-silent -Wimplicit -Wall
#F90 = /usr/local/encap/mpich-1.2.4..8a-intel/bin/mpif90
#F90LINKER = /usr/local/encap/mpich-1.2.4..8a-intel/bin/mpif90

#LIBS= -lencap -liberty -lptcblas -lgm -lcblas -lblacsCinit -lblacs \
# -lblacsF77init -lscalapack

SRC = nrtype.f90 nr.f90 nrutil.f90 parameters_global.f90 chemical_kinetics.f90 loop_counters.f90 \
general_variables.f90 scalar_coefficients.f90 mpinpb.f90 \
setup_mpi.f90 initialise.f90 block_begin.f90 fops.f90 plotout.f90 \
CATALYST_FLOW_P4.f90 config.f90 calcp.f90 mesh.f90 read_data.f90 \
lisolv.f90 sites.f90 numsp.f90 strips.f90 bdycon.f90 flows.f90 \
props.f90 transport.f90 lights.f90 corvel.f90 enth.f90 ststep.f90 \
fndkey.f90 specnum.f90 rates.f90 ratec.f90 comrat.f90 comrac.f90 \
numcon.f90 coefuv.f90 etest.f90 stest.f90 mtest.f90 energy.f90 \
dec.f90 decbt.f90 sol.f90 solbt.f90 sweepc.f90 sweeph.f90 sweepv.f90 \
encoef.f90 stephv.f90 specsol.f90 spcoef.f90 ensour.f90 heatf.f90 \
tridag.f90 unstdy.f90 timept.f90 movie.f90 mread.f90 vread.f90

OBJS =$(SRC:.f90=.o)

# target definitions

.SUFFIXES: .f90
.f90.o:
$(F90) $(FFLAGS) -c $<

pards: $(OBJS)
$(F90) $(OBJS) $(FFLAGS) -o pards



There are several problems:

(1) although I have the basic f95 libraries nrtype.f90, nrutil.f90, nr.f90, I have to copy them into the working directory and compile every time together with my source code. This is unsatisfactory -- how do I get it automatically into my codes?

(2) I get a series of warnings (not errors) regarding subroutines in nr.f90. For example,

ifort -u -O3 -i8 -r8 -align all -check -fast -fp-model fast=1 -funroll-loops -c nr.f90
fortcom: Warning: nr.f90, line 953: The type/rank/keyword signature for this specific procedure match es another specific procedure that shares the same generic-name. [FOUR1_SP]
SUBROUTINE four1_sp(data,isign)
---------------------------^
fortcom: Warning: nr.f90, line 1030: The type/rank/keyword signature for this specific procedure matc hes another specific procedure that shares the same generic-name. [FOURROW_SP]
SUBROUTINE fourrow_sp(data,isign)
---------------------------^


What does this mean?

(3) All my subroutines compile ok; but when it is linking all together I get:

ifort nrtype.o nr.o nrutil.o parameters_global.o chemical_kinetics.o loop_counters.o general_variables.o scalar_coefficients.o mpinpb.o setup_mpi.o initialise.o block_begin.o fops.o plotout.o CATALYST_FLOW_P4.o config.o calcp.o mesh.o read_data.o lisolv.o sites.o numsp.o strips.o bdycon.o flows.o props.o transport.o lights.o corvel.o enth.o ststep.o fndkey.o specnum.o rates.o ratec.o comrat.o comrac.o numcon.o coefuv.o etest.o stest.o mtest.o energy.o dec.o decbt.o sol.o solbt.o sweepc.o sweeph.o sweepv.o encoef.o stephv.o specsol.o spcoef.o ensour.o heatf.o tridag.o unstdy.o timept.o movie.o mread.o vread.o -u -O3 -i8 -r8 -align all -check -fast -fp-model fast=1 -funroll-loops -o pards
ipo: warning #11041: unresolved mpi_init_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_comm_rank_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_comm_split_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_comm_size_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_comm_dup_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_finalize_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_reduce_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_bcast_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: warning #11041: unresolved mpi_barrier_
Referenced in /tmp/ipo_ifortA9f4Bz.o
ipo: remark #11000: performing multi-file optimizations
ipo: remark #11005: generating object file /tmp/ipo_ifortA9f4Bz.o


Clearly, it is not recognising the mpi parallel instructions, like mpi_comm_rank, and mpi_bcast etc. This is very strange because the mpif77 compiles ok and I hve run parallel codes on my workstation.

This is repeated at the very end,

/tmp/ipo_ifortA9f4Bz.o(.text+0xf4d): In function `MAIN__':
: undefined reference to `mpi_finalize_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x5590e): In function `stest_':
: undefined reference to `mpi_reduce_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x55947): In function `stest_':
: undefined reference to `mpi_reduce_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x5597d): In function `stest_':
: undefined reference to `mpi_reduce_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x559b5): In function `stest_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x559ed): In function `stest_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x55a1f): In function `stest_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x68c1c): In function `sweeph_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x68c52): In function `sweeph_':
: undefined reference to `mpi_barrier_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x83633): In function `sweepc_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x83739): In function `sweepc_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x83767): In function `sweepc_':
: undefined reference to `mpi_barrier_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x9c972): In function `sweepv_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x9cb43): In function `sweepv_':
: undefined reference to `mpi_bcast_'
/tmp/ipo_ifortA9f4Bz.o(.text+0x9cb7f): In function `sweepv_':
: undefined reference to `mpi_barrier_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa1c8): In function `setup_mpi_':
: undefined reference to `mpi_init_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa1dd): In function `setup_mpi_':
: undefined reference to `mpi_comm_size_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa1f2): In function `setup_mpi_':
: undefined reference to `mpi_comm_rank_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa2cd): In function `setup_mpi_':
: undefined reference to `mpi_comm_split_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa2f3): In function `setup_mpi_':
: undefined reference to `mpi_comm_size_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa308): In function `setup_mpi_':
: undefined reference to `mpi_comm_dup_'
/tmp/ipo_ifortA9f4Bz.o(.text+0xaa31d): In function `setup_mpi_':
: undefined reference to `mpi_comm_dup_'
make: *** [pards] Error 1


Questions:
What is going wrong?
Do I have to download mpif90? How do I download and install mpif90?
Do I have to swap from lam_mpi to mpich? (Is there much difference.)

Regards
__________________
The_Watcher
LondonSmilie
# 2  
Old 02-17-2009
Ack!!!

First, (or last) LAM is completely different than MPI. There may be some kind of forward compatibility library, but only for the simplest of programs.

Second, (or "(3)") mpif77/mpif90 are essentially MPI macros for running different compilers that you have on your system. What program "mpif77" runs is dependent on your local configuration and some environment variables. Presumably you can change some environment variables to use ifort or f90. But that's not necessary -- just pass ifort the correct options for your MPI fortran header files and library. Doesn't your compute cluster have a local system administrator??

The answer to (1) is simple: you compile your f90 code once, and put the resulting .o files in a directory, say $HOME/objs. Then to include them, pass them to the full paths to the ifort command...
Code:
 ifort something.o another.o $HOME/objs/nrutil.o -o f77-prog

Now maybe you need one version for each compiler version. So you put the F90 version in $HOME/objs/f90/ and use this:
Code:
 ifort something.o another.o $HOME/objs/f90/nrutil.o -o f90-prog

Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

Is it possible to install RHEL 7 on top of RHEL 6?

Hi We have RHEL 6.7 on an HP physical server and want to install RHEL 7 (not upgrade) on top of it by means of virtualization. Is it possible to install/configure RHEV/KVM virtualization on base RHEL 6.7 OS instance and then install RHEL 7 as a VM guest on it? If yes, could you please guide me... (1 Reply)
Discussion started by: magnus29
1 Replies

2. UNIX for Dummies Questions & Answers

Windows->RHEL->RHEL X11 Forwarding?

I know this question might have been asked a lot but couldn't find anything that worked. From a windows machine 'A' I can only SSH into Linux server 'B' from where I can SSH into another Linux server 'C'. I need to be able to run GUI interfaces on server C which run on my Windows machine. I... (3 Replies)
Discussion started by: hr.prasan
3 Replies

3. Red Hat

RHEL 6, Spacewalk 2.3 unable to download RHEL 5 repo data

Hello all, I am having a bit of an issue on my Spacewalk installation. Some amplifying information is that it is Spacewalk 2.3 installed on a RHEL 6 machine and I am attempting to install/update a RHEL 5 channel/repository. I am fairly new to Spacewalk so I am still learning but this is what I... (3 Replies)
Discussion started by: jstone4646
3 Replies

4. Red Hat

RHEL Package download

Hi All, I am a Solaris administartor. I got in to a probelm with RHEL. I thought someone can help me on this forum .. Can we download/install packages on a Redhat server with yum with out registering on RHEL network or website ? (1 Reply)
Discussion started by: sri243
1 Replies

5. Red Hat

Error throwing while installing vsftpd package in rhel 6. using rhel 6 dvd.

Hi all, Im studying rhcsa as of now, so yum installation and dependencies are messing me to not workit out. i have dual os, win 7 & rhel 6. i have tried this installation of vsftpd package with rhel 6 dvd in VM rhel 6 in win 7 as well as host rhel 6.still the same issue. below error... (6 Replies)
Discussion started by: redhatlbug
6 Replies

6. Red Hat

RHEL 5.0 vs RHEL 6.0

marching into the new version of RHEL 6.0... other than ext4 and /boot can be ext4 and "/" root filesystem can be encrypted...I can't see much more new features that are quite significant and practical than RHEL 5.0, kernel is still 2.6.18.xxxx I wonder if it has newer tools to manage... (4 Replies)
Discussion started by: ppchu99
4 Replies

7. Red Hat

Does RHEL 5 provide a command to collect RHEL system log in single compress file?

Hi, I heard a command that can collect all RHEL 5 log in a single compress file before I forget. Does any body know...What the command is ? Thanks. (4 Replies)
Discussion started by: nnnnnnine
4 Replies

8. Red Hat

cannot ssh (use NFS) on RHEL box, but can mount external & ssh out of RHEL box

Ok, Im trying to get NFS working on my RHEL 5 box, apparently i can use the box as a client, but not as a server. If it helps i cant ssh into the box (server), but as a client ssh works fine. Ive configured server: /etc/hosts.allow: all : all all :all@all setup my /etc/exports file... (4 Replies)
Discussion started by: drs.grid
4 Replies

9. Red Hat

Questions About RHEL 6, CentOS 5.5 download and install

Hi, I have some questions about RHEL and CentOS download and installation. (1) Is RHEL6.0 x86_64 beta downloaded from Red Hat site working fine? (2) Where to download CentOS 5.5 DVD iso without using BitTorrent? (3) What are the differences between these two images - CentOS 5.5 i386 and... (6 Replies)
Discussion started by: aixlover
6 Replies

10. Red Hat

Difference between RHEL 3 AND RHEL 4

Anybody, let me know major differences between RHEL 3 & 4 . (2 Replies)
Discussion started by: sakthi_13
2 Replies
Login or Register to Ask a Question