Scheduled Downtime
On Tuesday 24 October 2023 @ 5pm MT the forums will be in read only mode in preparation for the downtime. On Wednesday 25 October 2023 @ 5am MT, this website will be down for maintenance and expected to return online later in the morning.
Normal Operations
The forums are back online with normal operations. If you notice any issues or errors related to the forums, please reach out to help@ucar.edu

Porting error, CESM2.1.3

Dear all,

I am trying to set up CESM2.1.3 on a new cluster.

Because I kept seeing the "NetCDF was not complied by the same version ..." error, I re-installed the NetCDF-c and Netcdf-fortran using the intel compiler.

However, I now see a new error that says: "/central/groups/carnegie_poc/leiduan_memex/CESM/my_cesm_sandbox/cime/src/externals/pio1/pio/pio_types.F90(13): error #7002: Error in opening the compiled module file. Check INCLUDE paths. [NETCDF]"

Here is part of the error message:

Code:
[ 40%] Building Fortran object pio/CMakeFiles/pio.dir/pio_types.F90.o

cd /central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/pio/pio1/pio && /central/software/Intel/2018.1/compilers_and_libraries_2018.1.163/linux/mpi/intel64/bin/mpiifort -D_NETCDF -D_NOPNETCDF -D_NOUSEMCT -D_USEBOX -I/central/groups/carnegie_poc/leiduan_memex/CESM/my_cesm_sandbox/cime/src/externals/pio1/pio -I/central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/pio/pio1/pio -I/usr/include -qno-opt-dynamic-align  -convert big_endian -assume byterecl -ftz -traceback -assume realloc_lhs -fp-model source    -O2 -debug minimal  -DTIMING -DLINUX -DNDEBUG -DHAVE_MPI -DPIO1  -DFORTRANUNDERSCORE -DCPRINTEL  -DFORTRANUNDERSCORE -DCPRINTEL -DHAVE_SLASHPROC -D_NO_MPI_RSEND -I. -I/central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/include -I/central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/mct/noesmf/c1a1l1i1o1r1g1w1e1/include -I/home/leiduan/lei_netcdf/netcdf4.6-intelf//include -I/central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/include -c /central/groups/carnegie_poc/leiduan_memex/CESM/my_cesm_sandbox/cime/src/externals/pio1/pio/pio_types.F90 -o CMakeFiles/pio.dir/pio_types.F90.o

make[2]: Leaving directory `/central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/pio/pio1'

make[1]: Leaving directory `/central/scratch/leiduan/test44/bld/intel/mpich/nodebug/nothreads/pio/pio1'

/central/groups/carnegie_poc/leiduan_memex/CESM/my_cesm_sandbox/cime/src/externals/pio1/pio/pio_types.F90(13): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [NETCDF]

     use netcdf                                  ! _EXTERNAL

---------^

/central/groups/carnegie_poc/leiduan_memex/CESM/my_cesm_sandbox/cime/src/externals/pio1/pio/pio_types.F90(383): error #6592: This symbol must be a defined parameter, an enumerator, or an argument of an inquiry function that evaluates to a compile-time constant.   [NF90_GLOBAL]

   integer, public, parameter :: PIO_global = nf90_global

----------------------------------------------^

/central/groups/carnegie_poc/leiduan_memex/CESM/my_cesm_sandbox/cime/src/externals/pio1/pio/pio_types.F90(384): error #6592: This symbol must be a defined parameter, an enumerator, or an argument of an inquiry function that evaluates to a compile-time constant.   [NF90_UNLIMITED]

   integer, public, parameter :: PIO_unlimited = nf90_unlimited[/ICODE]


It seems the model cannot find the netcdf (is this correct?) However, I think I have link it where in the .bash* I have:


Code:
export NETCDF_C=/home/leiduan/lei_netcdf/netcdf4.4-c
export NETCDF_C_LIB=$NETCDF_C/lib
export NETCDF_C_INC=$NETCDF_C/include
export PATH=$NETCDF_C/bin:$PATH
export LD_LIBRARY_PATH=$NETCDF_C/lib:$LD_LIBRARY_PATH

export NETCDF_F=/home/leiduan/lei_netcdf/netcdf4.6-intelf
export NETCDF_F_LIB=$NETCDF_F/lib
export NETCDF_F_INC=$NETCDF_F/include
export PATH=$NETCDF_F/bin:$PATH
export LD_LIBRARY_PATH=$NETCDF_F/lib:$LD_LIBRARY_PATH

In config_machine.xml I have:

Code:
<mpirun mpilib="mpich">
      <executable>mpirun</executable>
      <arguments>
        <arg name="num_tasks"> -n {{ total_tasks }} </arg>
        <arg name="lib">-genv LD_LIBRARY_PATH /home/leiduan/lei_netcdf/netcdf4.6-intelf/lib:$LD_LIBRARY_PATH</arg>
      </arguments>
    </mpirun>
    <module_system type="none">
    </module_system>
    <environment_variables>
      <env name="NETCDFROOT">/home/leiduan/lei_netcdf/netcdf4.6-intelf</env>
      <env name="OMP_STACKSIZE">64M</env>
    </environment_variables>

And in config_compiler.xml I have:

Code:
<NETCDF_PATH>/home/leiduan/lei_netcdf/netcdf4.6-intelf/</NETCDF_PATH>
  <SLIBS>
    <base> -L${NETCDF_PATH}/lib -I${NETCDF_PATH}/include -lnetcdf -lnetcdff -L$ENV{MKL_PATH} -lmkl_rt </base>
    <append MPILIB="mpich"> -mkl=cluster </append>
  </SLIBS>


Any idea how to solve this would be much appreciated.

Best regards,
Lei
 
I solved it by re-installing an earlier version of NetCDF-c and NetCDF-f. It appear to me that the lastest one (4.9 for netcdf-c and 4.6 for netcdf-f) lacks some components that will be used during the building.

Now I can successfully build the case.
 
Top