ERROR in subroutine READNML

Thanks a lot for your Reply

Yes, I am using the mcip script from the version 5.0, indeed, there are some differences between script versions.

Thanks for the list. Where did you find it?

You have 5010 LIBERROR_READ_VALUE which means that there is probably what gfortran thinks is a formatting-error somewhere in the list – maybe an extra comma or decimal point. Check it character-by-character; these things are notoriously hard to find (which is one of the reasons the I/O API encourages environment variables instead of namelists…)

…and the gfortran authors have a particularly idiosyncratic way of reading the Fortran standard ;-(

Hi!

I got it from http://www.hep.manchester.ac.uk/u/samt/misc/gfortran_errors.html
I checked the namelist.mcip and compared with namelist in previous versions that I have run and everything seems to be ok.

Can I run mcip 4.2 with WRF4.1? I made a proof but it seems that not recognize wrf 4.

@cristianarango2

I’m sorry you’re experiencing this issue with MCIPv5.0. There is another user with the same issue, so I’d like to get more information to solve the problem. I tested with GFortran on my system, and I did not encounter any errors. Can you please attach your namelist that was generated from your MCIPv5.0 run?

You cannot use MCIPv4.2 with WRFv4.0+. Only MCIPv5.0 is set up for WRFv4.0+ at this time.

–Tanya

Hi Tanya, thanks a lot for your help.

Below my namelist.mcip and the script tha generates it is attached

&FILENAMES
file_gd = “/SIMCAB/meteorologia/mcip5/d01/GRIDDESC”
file_mm = “/SIMCAB/meteorologia/WRF/WRFV4/run/wrfout_d01_2019-08-30_00:00:00”,
file_ter = “/SIMCAB/meteorologia/WRF/WPSV4/geo_em.d01.nc”
ioform = 1
&END

&USERDEFS
lpv = 0
lwout = 0
luvbout = 1
mcip_start = “2019-08-30-00:00:00.0000”
mcip_end = “2019-08-31-00:00:00.0000”
intvl = 60
coordnam = “Colombia”
grdnam = “CMAQBogota”
btrim = -1
lprt_col = 0
lprt_row = 0
wrf_lc_ref_lat = 40.0
&END

&WINDOWDEFS
x0 = 1
y0 = 1
ncolsin = 179
nrowsin = 154
&ENDrun_mcip.csh (18.7 KB)

@cristianarango2

Thank you for providing your namelist. This is just a guess, but I’d like you to try it. Please edit namelist.mcip to remove the comma after the first element of “file_mm”. Then execute mcip.exe. If you cannot execute mcip.exe without your script, edit your script so that you do not overwrite namelist.mcip (for example) by temporarily changing “cat namelist.mcip >> !” to “cat junk >> !”.

Please let me know if that works.

–Tanya

Hi Tanya

Yes, we already try it modifying the run_mcip.csh part that generates the namelist.mcip, but it doesn´t work.

Thanks for your help!

I am using PGI and meet the same problem. Have you found the solution? Thanks.


*** SUBROUTINE: READNML
*** ERROR READING NAMELIST FILE ON UNIT 8
*** NAMELIST FILE NAME = namelist.mcip
*** NAMELIST = filenames
*** IOSTAT = 239


 *** ERROR ABORT in subroutine READNML
 ABNORMAL TERMINATION IN READNML

Error running mcip

Hello @cristianarango2 @tlspero @mtchuang100

I checked the run_mcip file posted, and it uses IfGeo = “T”.
Please, check the post below. Maybe it can help…

Hi all,

I had the same issue and am using gfortran (from gccv7.3.0). I removed the comma from the MCIP run script (where file_mm is defined and written, around line 360) but this did not resolve the issue. Changing ‘IfGeo = “T”’ to ‘IfGeo = .TRUE.’ makes the program run further, but this is because the corresponding if statements (there are 3 of them, around lines 295, 335, 375) are only checking for “T”. When they’re revised to check for .TRUE., the original READNML error appears. I’m able to view my geo_em file from WRFv4.1.2 in VERDI, so I believe it was generated successfully.

Please let me know if a solution is found.

Thank you,
Elyse


*** SUBROUTINE: READNML
*** ERROR READING NAMELIST FILE ON UNIT 8
*** NAMELIST FILE NAME = namelist.mcip
*** NAMELIST = filenames
*** IOSTAT = 19


 *** ERROR ABORT in subroutine READNML
 ABNORMAL TERMINATION IN READNML

We are using WRF 4.0, and MCIP 5.0, this is the error that we are facing, we tried all the possible solutions mentioned in the thread, but none worked, can you guys help in anyway, because it is creating a big problem to the research.
A possible bypass solution to this was to use geogrid.exe,ungrib.exe and metgrid.exe in WRF4.0 but run realtime.exe and wrf.exe with older WRF version and use old mcip and CMAQ for the computing, it works!! :slight_smile: but the problem is we want to use CMAQv5.3, because of its easy coupled compatibility with WRF. Please if someone can help, that would be appreciable. Thank you!

Shivang –
Are you using the MCIP script as it is provided on GitHub, or did you modify it? Post your namelist.mcip file, so that we can verify that it was generated correctly.

What compiler and version are you using?

Hi Chris,
We are using the script (run_mcip.csh) as it is, we did not modify it, and we are using GCC 4.8.5 compiler.
namelist.mcip::

&FILENAMES
file_gd = “/home/hpc5/WRF4.0/Build_WRF/WRF/test/em_real/mcip_trial/GRIDDESC”
file_hdr = “/home/hpc5/WRF4.0/Build_WRF/WRF/test/em_real/mcip_trial/mmheader.d01_3DINDIA_20191102” #added from old mcip run file
file_mm = “/home/hpc5/WRF4.0/Build_WRF/WRF/test/em_real/wrfout_d01_2019-11-02_00:00:00”,
“/home/hpc5/WRF4.0/Build_WRF/WRF/test/em_real/wrfout_d01_2019-11-02_00:00:00”,
“/home/hpc5/WRF4.0/Build_WRF/WRF/test/em_real/wrfout_d01_2019-11-03_00:00:00”,
file_ter = “/home/hpc5/WRF4.0/Build_WRF/WRF/test/em_real/geo_em.d01.nc”
ioform = 1
&END

&USERDEFS
lpv = 0
lwout = 0
luvbout = 1
mcip_start = “2019-11-02_00:00:00.0000”
mcip_end = “2019-11-03_00:00:00.0000”
intvl = 60
coordnam = “3DINDIA”
grdnam = “3DINDIA”
btrim = 5
lprt_col = 0
lprt_row = 0
wrf_lc_ref_lat =
&END

&WINDOWDEFS
x0 =
y0 =
ncolsin =
nrowsin =
&END

We would be glad if you could help us.

The script run_mcip.csh generates namelist.mcip. The namelist you have provided does not look like what would be produced by the script.
In particular, you have an embedded comment (line beginning with a #) in the &FILENAMES namelist. I believe this is not legal in Fortran90, and that is exactly what your error message is telling you.
There are other differences as well between your namelist.mcip and the version generated by the script. The structure of namelist.mcip that is required may vary from one version of MCIP to another. As noted in the release notes, the source code to readnml.f90 has changed; there is no longer a file_hdr variable.
I suggest you try the version “out of the box” with the tutorial case, verify that works, then modify for your application.

@Catalyst2682, @cristianarango2, @mtchuang100, @epenning, @Shivang

I think I finally figured out the issue with the script and MCIPv5.0. I believe I introduced an error in the MCIP script when I removed the MM5 processing. Inside MCIP, I changed the name of the file that we used to load either TERRAIN (from MM5) or Geogrid (from WRF) output from “file_ter” to “file_geo” to be more reflective of the WRF input that we use. However, I forgot to change its setting in the MCIP script where the namelist is generated. Unfortunately, I never used that part of the script in my testing because I already had the fractional land use in the wrfout files…so I never ran into this issue.

Please see: https://github.com/USEPA/CMAQ/blob/master/PREP/mcip/scripts/run_mcip.csh

In line 377, please change “file_ter” to “file_geo”. That will hopefully solve the issue.

I apologize for the inconvenience. The script will be updated in the next release. Please let me know in this thread if the solution I proposed here works for you.

Thanks, also, to @cjcoats and @cgnolte for weighing in on this issue.

–Tanya

3 Likes

@tlspero, MCIP ran successfully with this fix. Thank you!

Hi @tlspero

thanks for your solution, It works well. Now I have a segmentation fault. I already have try ulimit -s unlimited and diferent versions of WRF. when I run mcip 4.2 with WRFV3 works, but it doesn’t wor with mcip5.0.

the output is:

Program received signal SIGSEGV: Segmentation fault - invalid memory reference.

Backtrace for this error:
#0 0x2ac3cf493d8a in ???
#1 0x2ac3cf492fb3 in ???
#2 0x2ac3d007b33f in ???
#3 0x428f43 in ???
#4 0x403f2b in ???
#5 0x403d8c in ???
#6 0x2ac3d0067494 in ???
#7 0x403dbc in ???
#8 0xffffffffffffffff in ???
Segmentation fault
Error running mcip

I appreciate any help.

@cristianarango2

Two things. First, please try using MCIPv5.1 (which just came out with CMAQv5.3.1). I don’t necessarily think this will solve the problem, but I want to make sure that this error is not caused by one of the minor bug fixes between 5.0 and 5.1. Second, please change your compiler options to use the equivalent of the “traceback” so that we can get more specific information about the error. The information provided in your last post is not helpful…other than there is a segmentation fault. The traceback (or whatever it’s called with your compiler) will give you the subroutine and sometimes the specific line in the code where there is a memory violation.

–Tanya

1 Like

@cristianarango2

Did you ever resolve this issue?

–Tanya