Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

(RESOLVED) GEOGRID PROBLEM: WRF_DEBUG: NetCDF error: NetCDF: Not a valid ID

This post was from a previous version of the WRF&MPAS-A Support Forum. New replies have been disabled and if you have follow up questions related to this post, then please start a new thread from the forum home page.

lslrsgis

Member
Dear WRF community,

I'm writing for a problem with geogrid.

I have successfully compiled both WRF and WPS (all executables are made). But when I run ./geogrid.exe, errors prompted on the screen as follows:

NOTED: I changed debug_level=1000 (to get more debug info), and opt_output_from_geogrid_path = '/home/slliu/project/WRF/WPS_TEST/' (to ensure I have permission). The detailed debug error comes:

INFORM: Using default data source for SANDFRAC.
INFORM: Could not read 'index' file /home/slliu/project/WRF/GEOG/WPS_GEOG_HIGH_RES/sandfrac_5m/index for field SANDFRAC
INFORM: This field is optional and will not be processed.
Processing XLAT and XLONG
WRF_DEBUG: NetCDF error: NetCDF: Not a valid ID
WRF_DEBUG: NetCDF error in ext_ncd_open_for_write_begin wrf_io.F90, line
1382
ERROR: Error in ext_pkg_open_for_write_begin.
Abort(48891744) on node 0 (rank 0 in comm 0): application called MPI_Abort(MPI_COMM_WORLD, 48891744) - process 0

Then, a geo_em.d01.nc file is generated. However, this file is boken and nearly empty (0B).

When I changed io_form_geogrid=2 to io_form_geogrid=1, ./geogrid.exe can be successfully executed. I guess that it might be something relative to netCDF. It seems that the program can not write netCDF files.

namelist.wps, geogrid.log, execution ./geogrid log are attached.
 

Attachments

  • namelist.wps
    1.3 KB · Views: 73
  • log.geogrid.serial.txt
    132 bytes · Views: 62
  • geogrid.log
    10.5 KB · Views: 83
If you are unable to write NetCDF files, then it is a problem with your particular system/environment, as we are not able to reproduce the problem, and have received no other complaints about this. Please take this problem to the systems administrator at your institution to try to determine why NetCDF files are not able to be written out to your directory.
 
Thanks Kelly. I am communicating with our HPC administration for the cause and solution.

By the way, may I know the correct compilation options for netcdf C/fortran libraries?

For example, I am using the following commands (not sure they are correct and complete) :
cd ~/Downloads/WRF-INSTALL/netcdf-4.6.1
sudo CPPFLAGS="-I/usr/local/lib/hdf5-1.10.4/include/ -I/usr/local/lib/curl-7.62.0/include/ -I/usr/local/lib/zlib-1.2.11/include" LDFLAGS="-L/usr/local/lib/hdf5-1.10.4/lib/ -L/usr/local/lib/curl-7.62.0/lib/ -L/usr/local/lib/zlib-1.2.11/lib/" ./configure --prefix=/usr/local/lib/netcdf --disable-dap --enable-netcdf-4 --disable-shared
sudo make
sudo make install

cd ~/Downloads/WRF-INSTALL/netcdf-fortran-4.4.4
sudo CPPFLAGS="-I/usr/local/lib/netcdf/include/" LDFLAGS="-L/usr/local/lib/netcdf/lib/" ./configure --prefix=/usr/local/lib/netcdf --enable-fortran --enable-large-file-test
sudo make
sudo make install

LSL
 
Hi,

We have the instructions for installing NetCDF in the 'Installing Libraries' section of this web page:
http://www2.mmm.ucar.edu/wrf/OnLineTutorial/compilation_tutorial.php

These instructions are for a very basic installation, which should be all you need if you aren't planning to use any of the netcdf-4 capabilities (like compression), but we don't have any information on installing the compilers. I do know that you'll need to have a fortran compiler and C compiler in place, prior to installing netCDF (because you need to make sure that netCDF is installed with the same compiler that you intend to use to compile WRF). The instructions are just an attempt for us to walk users through building the libraries, but unfortunately we don't have the resources available to support the libraries and compilers, so this will also need to be a question for your systems administrator.
 
Thanks. The problem was caused by our special cluster file system (lustre) confirmed with our HPC administrator. We tested the WPS/WRF in other file systems, they are working well.

It seems that NetCDF option within WPS/WRF would encounter a problem in Lustre.
 
I am glad to hear that you were able to solve the problem! Thank you for updating the post.
 
Top