Main menu

Navigation

SCAM can't find libpgmp libraries on CGD systems

3 posts / 0 new
Last post
rneale
SCAM can't find libpgmp libraries on CGD systems

I am trying to build and run SCAM from cesm1_3_beta02 on cgd systems (logan, harmon). Running the cam executable fails as it cannot find the library shared object libpgmp.so. Do I need to get this library installed (I don't know what it's for, something parallel I'm guessing) or can I run w/o it?
Thanks!
Rich

Richard Neale CESM AMWG Co-chair eval(unescape('%64%6f%63%75%6d%65%6e%74%2e%77%72%69%74%65%28%27%3c%61%20%68%72%65%66%3d%22%6d%61%69%6c%74%6f%3a%72%6e%65%61%6c%65%40%75%63%61%72%2e%65%64%75%22%20%63%6c%61%73%73%3d%22%62%62%2d%65%6d%61%69%6c%22%3e%72%6e%65%61%6c%65%40%75%63%61%72%2e%65%64%75%3c%2f%61%3e%27%29%3b')) http://www.cgd.ucar.edu/cms/rneale Atmosphere Modeling and Predictability Section, AMP, NCAR Tel (303) 497-1380 Fax (303) 497-1324

jet
Hi Rich: You need to add a directory path to your LD_LIBRARY_PATH variable.  When the Portland Group compiler was upgraded the dynamic libraries were split out into a new directory. For instance if the error you are seeing at runtime is a missing library (libpgmp or libpghpf or something like that) then you need to find out where that library exists on your system and add that directory to the LD_LIBRARY_PATH.ex.

1111> locate libpgmp.so
/usr/local/pgi-pgcc-pghf-13.10/linux86-64/13.10/REDIST/libpgmp.so
/usr/local/pgi-pgcc-pghf-13.10/linux86-64/13.10/libso/libpgmp.so
/usr/local/pgi-pgcc-pghf-14.1/linux86-64/14.1/REDIST/libpgmp.so
/usr/local/pgi-pgcc-pghf-14.1/linux86-64/14.1/libso/libpgmp.so

If you are using the 14.1 version of portland group compiler then the command to add the directory is:

setenv LD_LIBRARY_PATH=/usr/local/pgi-pgcc-pghf-14.1/linux86-64/14.1/libso:${LD_LIBRARY_PATH}
You want to put the new directory first in the directory path because often times the existing LD_LIBRARY_PATH will contain a pointer to /usr/local/lib higher up in the path and the executable will then pick up the wrong dynamic library.   You can use the ldd command to see what dynamic libraries are being loaded by the executable
ldd cam

You should see a print out of all resolved libraries.  If it is showing you something like

        libpgmp.so => not found
        libpgf90.so => not found
        libpgf90_rpm1.so => not found
then you are missing a directory entry in your LD_LIBRARY_PATH

The path could also say something like libpgmp.so =>/usr/local/lib

Which although it found a library in /usr/local/lib it most likely isn't the one you need for running.  If it is the wrong library the model will fail during the run when it tries to make a netcdf call to open a file.

 

jt

jet

Hi Rich:


Brian stopped by and let me know that the CGD machines now support the modules utlity that manage a user's environment variables.  It is an excellent way of keeping all these paths and environment variables consistent.  You can find further information on the Modules web page http://modules.sourceforge.net/ or by typing

module help

For your particular case where you need to have your environment set up correctly for the PGI compiler you would find the appropriate module to load by typing

module avail

And then load the appropriate module ...

module load compiler/pgi/14.1

Our systems's group let me know that when any compiler is loaded, the appropriate netcdf libraries that can be used with that compiler are loaded at the same time.

Lastly, you should take some time to look at the entire list of available modules and clean up your startup scripts (ex .login, .cshrc, etc.) by removing any commands which are directly modifying environment variables for the listed modules.  Its much cleaner and safer to execute module load commands in your startup scripts for any packages you want loaded by default.

jt

Log in or register to post comments

Who's new

  • m.kliphuis@...
  • ddc3061993@...
  • hui.ding@...
  • zhouc@...
  • arianna.valmass...