nc_test

Jianwei Li jianwei at pop.ece.nwu.edu
Fri Feb 28 16:36:27 CST 2003


>
>hi guys.
>
>the test/nc_test is a test from the serial netcdf distribution.  I've
>gotten it to build under parallel-netcdf, but it doesn't get very far.
>
>I'm working on some other stuff right now and unfortunatly cannot
>focus on this hard enough to find a fix, but the nc_test -c (create a
>netcdf file) fails like this:
>
>FAILURE at line 631 of 
/homes/robl/projects/parallel-netcdf/test/nc_test/util.c:
>ncmpi_put_att_text: Operation not allowed in collective data mode

	hi, rob,

	"util.c" line 631 seems to have called ncmpi_put_vara_double().
	The parallel-netcdf library is designed so that the default data
	I/O is collective I/O, and if you want to call independent I/O
	functions to get/put variables (ie. functions w/o "_all" suffix),
	you will need to call ncmpi_begin_indep_data() to enter independent
	data I/O mode and after you are done with independent I/O,
	you may call ncmpi_end_indep_data() to exit this mode.
	This is the major different between serial netcdf and parallel-netcdf
	and is described in detail in the API doc.
	So the problem you met is probably cause by calling 
	ncmpi_put_vara_double or whatever independent get/put variable 
	functions before ncmpi_begin_indep_data(). 

	Somehow, your error message is strange, it should look like:
	"ncmpi_put_vara_double: Operation not allowed in collective data mode"
	instead of:
	"ncmpi_put_att_text: Operation not allowed in collective data mode"
	or the header of the error message is improperly prefixed by your code:<
	
	Hope this would help you through the test. 
	
	--
	Jianwei




More information about the parallel-netcdf mailing list