Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

Problems with geogrid and metgrid

This post was from a previous version of the WRF&MPAS-A Support Forum. New replies have been disabled and if you have follow up questions related to this post, then please start a new thread from the forum home page.

cfbalseiro

New member
Hello,

I'm trying to compile WRF4 in a Ubuntu machine (16.04). I'm using gfortran compilers (v5.4.0). I'm able to compile WRF model, but when I'm trying to compile WPS (using option 1 of configure) metgrid and geogrid fail (Just obtain ungrib.exe)

With WRF3.8 I hadn't any problems with WPS compilation.

Would you know where is the problem? Attaching compile.log and configure.wps

Many thanks in advance!
 

Attachments

  • compile.log
    135.7 KB · Views: 1,725
  • configure.wps
    3.7 KB · Views: 167
Thank you for sending that. Because WPS makes use of the external I/O libraries in the WRF/external/ directory, and because you compiled WRF with the smpar option, you just need to add one extra piece to your configure.wps file. Before you do, from the WPS/ directory issue:
./clean -a

Then reconfigure. Once you do that, look in the configure.wps file and find the line 'WRF_LIB.' It should look something like:
WRF_LIB = -L$(WRF_DIR)/external/io_grib1 -lio_grib1 \
-L$(WRF_DIR)/external/io_grib_share -lio_grib_share \
-L$(WRF_DIR)/external/io_int -lwrfio_int \
-L$(WRF_DIR)/external/io_netcdf -lwrfio_nf \
-L$(NETCDF)/lib -lnetcdff -lnetcdf

Add '-lgomp' to the end of that, so that the bottom line is now:
-L$(NETCDF)/lib -lnetcdff -lnetcdf -lgomp

You'll then need to save this configure file and recompile. Let me know if that works!
 
Many thanks for your answer, but unfortunately it doesn't work.

It was a problem related with NETCDF library. I'm not sure the exact reason, but if I use an old version of NETCDF it works.

I must apologize for disturbing you like this! ;(
 
No worries! I'm glad that you were able to get it figured out. Thank you for letting me know.
 
The user probably meant installing NETCDF 3.x instead of NETCDF 4.x.

NETCDF4 introduces many complications, depending on how it was built.
 
Hello everyone. So I was having the same problem. geogrid.exe and metgrid.exe were absent after compiling. I compiled WRF on gfortran compiler with dmpar option and when I tried to compile WPS with dmpar option, this problem came up. But when I switched to smpar during WPS compiling, everything went smooth. I don't know why. I am still learning.
 
Hi asyed6,
Can you please attach the following files?

configure.wrf
wrf compile log
configure.wps
wps compile log
 
I was having the same problem that there was only ungrib.exe after compiling. I have compiled WRF on gfortran compiler with dmpar option successfully. But when I tried to compile WPS with dmpar option, this problem came up. The configure.wps and log.compile are as follows. Looking forward to reply!
 

Attachments

  • 1.jpg
    1.jpg
    12 MB · Views: 2,599
  • 2.jpg
    2.jpg
    11.4 MB · Views: 2,595
  • 3.jpg
    3.jpg
    11.5 MB · Views: 2,595
  • 4.jpg
    4.jpg
    11.3 MB · Views: 2,595
  • log.compile
    69.4 KB · Views: 77
Hi Z_wenky,

At the top of your compile.log file, it shows this error:
***************************************************************************************
Error : Not building geogrid. Check whether WRF is compiled in /home/wenky/model/WPSV4.0.TAR/WPS/../WRF
***************************************************************************************

Typically this means that either the WRF directory is not actually in this location, or that you have renamed the WRF directory to something else. You'll need to make sure that you have WRF_DIR set correctly in your configure.wps file before trying to compile WPS. Issue a 'clean -a', reconfigure, make modifications to your configure.wps file, save that file, and then try to recompile. If you run into more problems, please attach the new compile.log, and please just attach the new configure.wps file, instead of attaching the pictures of the screen. Thanks!
 
Many thanks! I have made modifications to the configure.wps, and the WPS compiled successfully. Sorry about the pictures of configure.wps and I will attach files in the future problems. Thank you for reminding me!
 
I'm glad to hear that you were able to successfully compile! Thank you for updating the post.
 
Dear all,
I also had the same problem that only ungrib.exe is created after compiling. I have compiled WRF with the option ( 15. (dmpar) INTEL (ifort/icc)) successfully. But it failed when I tried to compile WPSV4.1 with dmpar option(19. Linux x86_64, Intel compiler (dmpar)). It can only be successfully compiled when I choose 17. Linux x86_64, Intel compiler (serial). It is also successfully compiled when I worked on WPSV4.0.
I attached the configure.wps and log.compile are as follows. Any suggestions or help will be appreciated.
 

Attachments

  • configure.wps
    3.3 KB · Views: 32
  • configure.wrf
    23.2 KB · Views: 26
  • WPS_compile.log
    166.1 KB · Views: 25
  • WRF_log.compile
    2 MB · Views: 23
@linnick20628,
Is there a reason why you need to compile WPS with dmpar? We rarely recommend that unless you plan to have extremely large domains (1000's x 1000's of grid cells). The WPS program is so quick that it's not that beneficial to compile it in parallel. If you don't need it, then it's perfectly fine to compile it serially, even when you compiled WRF with a distributed memory option.
 
Top