[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 20010808: netCDF on T3E
- Subject: Re: 20010808: netCDF on T3E
- Date: Wed, 08 Aug 2001 16:25:22 -0600
>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