This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
>To: address@hidden (netCDF support) >From: "Daniel S. Schaffer" <address@hidden> >Subject: netCDF on T3E >Organization: NOAA/FSL >Keywords: 200108081441.f78Ef3125942 Hi Dan, > My colleague Tom Henderson and I have been in contact > with Russell. I recently have run into a problems with > netCDF on a T3E. I am executing the following code within > an MPI program: > > status=nf_open ('cgoa_grid_2.nc',nf_nowrite,ncid) > print *, 'got to 2' > status=nf_inq_att (ncid,nf_global,'type',attype,ltype) > print *, 'called nf_inq_att ', ncid, attype, ltype, status > > > While I have not yet been able to isolate the problem completely, > I get one of two behaviors depending on the rest of the code. > Either I get: > NC_SHARE not implemented for ffio > in the call to nf_open First, is it possible you have not included the "netcdf.inc" include file in this subroutine, so the parameters "nf_nowrite" and "nf_global" are not initialized? That would explain the symptoms. Also looking at the src for libsrc/ffio.c, it appears as if the message NC_SHARE not implemented for ffio will only be printed if the "nf_share" mode bit has been set on open, but since you are opening with "nf_nowrite" mode, that doesn't seem to make sense. The "nf_nowrite" parameter is initialized in the netcdf.inc file as 0, whereas "nf_share" is initialized to be 2048. Does another thread also open the file and set the "nf_share" flag first? If so, I don't think that will work; for the T3E parallel netCDF used from multiple threads, you should instead be using the "underbar underbar" functions like nc__open(). See the Fortran netcdf man page for descriptions of these, which were explicitly added for the T3E. > or I get status -49 in the call to nf_inq_att > > Any ideas what might be going on here? The status -49 for the Fortran interface is defined in the netcdf.inc include file: parameter (nf_enotvar = -49) which means "Variable not found" if you use the nf_strerror() to convert it to an error message. The variable id you supply, "nf_global", is the ID of the global pseudo-variable and as a parameter is assigned the value 0 in the netcdf.inc include file. This should always be "found". Is it possible you have not included the netcdf.inc file in this subroutine, so nf_global is uninitialized? --Russ _____________________________________________________________________ Russ Rew UCAR Unidata Program address@hidden http://www.unidata.ucar.edu