Writing to subsequent history files in ROMS 3.4

Bug reports, work arounds and fixes

Moderators: arango, robertson

Post Reply
Message
Author
Johannes
Posts: 7
Joined: Mon Mar 01, 2010 2:11 pm
Location: Norwegian Meteorological Institute
Contact:

Writing to subsequent history files in ROMS 3.4

#1 Unread post by Johannes »

Using ROMS 3.4 (r550), I have the problem that the history output file is not getting initialized when I specify NDEFHS != 0 (writing the output to subsequent history files).

The error I get looks like this:

Code: Select all

NETCDF_PUT_FVAR_1D - error while writing variable:  ocean_time
                      in input file:  ocean_his.nc
                      call from:  wrt_his.F

ERROR: Abnormal termination: NetCDF OUTPUT.
REASON: NetCDF: Not a valid ID             
This has worked with ROMS 3.2 and the problem doesn't appear if the output is written to one single history file. I have updated my ocean.in file for ROMS 3.4. I told ROMS to output ncHISid(ng), which turned out to be -1 just before writing to the file. I guess this shouldn't be ? It seems like the file is not getting created.

Are there any further parameters or cpp options I have to set to be able to write to subsequent output files since ROMS 3.4?

Johannes
Posts: 7
Joined: Mon Mar 01, 2010 2:11 pm
Location: Norwegian Meteorological Institute
Contact:

Re: Writing to subsequent history files in ROMS 3.4

#2 Unread post by Johannes »

Does anyone know if this problem could be related to:
https://www.myroms.org/projects/src/ticket/510 ?

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Writing to subsequent history files in ROMS 3.4

#3 Unread post by kate »

What is your NDEFHIS and what timestep are you trying to restart on? I'm not having a problem if I create a new history file for each history record.

Johannes
Posts: 7
Joined: Mon Mar 01, 2010 2:11 pm
Location: Norwegian Meteorological Institute
Contact:

Re: Writing to subsequent history files in ROMS 3.4

#4 Unread post by Johannes »

I use:

NDEFHIS=1440

and do not restart the model. This still works with ROMS 3.2. with no other changes than the ROMS version.

I updated the ocean.in file but not the makefile. could this be a problem?

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Writing to subsequent history files in ROMS 3.4

#5 Unread post by kate »

Have you updated since that trac ticket was fixed?

Johannes
Posts: 7
Joined: Mon Mar 01, 2010 2:11 pm
Location: Norwegian Meteorological Institute
Contact:

Re: Writing to subsequent history files in ROMS 3.4

#6 Unread post by Johannes »

No, I didn't update to ROMS 3.5 because 3.4 was announced to be stable and 3.5 has gotten "major changes". However, I'll try that later on and will report if it helps.

User avatar
arango
Site Admin
Posts: 1367
Joined: Wed Feb 26, 2003 4:41 pm
Location: DMCS, Rutgers University
Contact:

Re: Writing to subsequent history files in ROMS 3.4

#7 Unread post by arango »

Not enough information is provided here for us to diagnose what it is going on. These is an ouput problem. I don't understand the attempt to change ocean_time. This doesn't have nothing to so with the error. It is telling you that cannot write to the history file because ncid is not a valid file NetCDF ID. Probably, the file has not been created yet. You must be doing something wrong. More details needs to be provided to see if we can reproduce the problem.

In major updates of ROMS we need to update everything including input scripts, header files, analytical files, makefile, build script, etc. I have mentioned several times that user should not modify the makefile to compile the application. Everybody should use the build script instead. This is very clear in :arrow: wikiROMS. I assume that we are going to repeat this over and over...

Post Reply