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

ERROR in build MPAS

sunweihao

New member
Dear scientists,
I got an error when I build MPAS atmosphere model.

When I input: make ifort CORE=init_atmosphere

Here is error message:

make[1]: Entering directory `/public1/home/lym/swh/MPAS-Model'
Checking for a usable PIO library...
************ ERROR ************
Failed to compile a PIO test program
Please ensure the PIO environment variable is set to the PIO installation directory
************ ERROR ************
make[1]: *** [pio_test] Error 1
make[1]: Leaving directory `/public1/home/lym/swh/MPAS-Model'
make: *** [ifort] Error 2

the PIO I used is version 1.7.1 and version of MPAS is v7.3. I wonder if I have error in install pio, and I check the $PIO I have set to the path where it installed.
When I input: ls ${PIO}/lib
1656162814650.png

When I input: ls ${PIO}/include
1656162862239.png

it seems the pio has been correctly installed, can someone help me? Thanks!
 
try adding this...

make ifort CORE=init_atmosphere USE_PIO2=true
 
Dear scientists,
I got an error when I build MPAS atmosphere model.

When I input: make ifort CORE=init_atmosphere

Here is error message:

make[1]: Entering directory `/public1/home/lym/swh/MPAS-Model'
Checking for a usable PIO library...
************ ERROR ************
Failed to compile a PIO test program
Please ensure the PIO environment variable is set to the PIO installation directory
************ ERROR ************
make[1]: *** [pio_test] Error 1
make[1]: Leaving directory `/public1/home/lym/swh/MPAS-Model'
make: *** [ifort] Error 2

the PIO I used is version 1.7.1 and version of MPAS is v7.3. I wonder if I have error in install pio, and I check the $PIO I have set to the path where it installed.
When I input: ls ${PIO}/lib
View attachment 6737

When I input: ls ${PIO}/include
View attachment 6739

it seems the pio has been correctly installed, can someone help me? Thanks!
Did you get it to work?
 
As Whatheway said, it may be worth trying the latest PIO release (2.5.7 as of the time of writing this post). I know that some of our documentation mentions using PIO 1.7.1, but we should probably update that.

In case you're familiar with switching branches in a Git repository, you can try compiling from the 'develop' branch in the MPAS-Model repository. The 'develop' branch contains better logic for automatically detecting the correct PIO library version, and it also includes better diagnostic messages when the PIO library detection fails. This might help in debugging the PIO issue, but once that's resolved, I'd recommend switching back to the v7.3 release code for any science runs with MPAS-Atmosphere.
 
Thanks for your reply, but it still does not work. Add "USE_PIO2=true" can not help resolve it

Because Pio version I used is 1.7, I'm afraid this set can do nothing with it
Were you able to get this fixed?
 
I also have the same problem. The mpas version I tried is 7.3 and the latest version on github. I use PIO1.7.1. It seems install IPO2.xx is difficult, and I don't need parallel netcdf. My installation of pio1.7.1 seems successful as I can see include and lib in the folder. I also set PIO environment variable. But this error is still there. Can anyone give more suggestion? Thank you very much

Here are my pio1.7.1, I have much less files compared to 'sunweihao'

include/
alloc_mod.mod iompi_mod.mod pio_kinds.mod pio_msg_mod.mod pionfread_mod.mod pio_support.mod
box_rearrange.mod ionf_mod.mod piolib_mod.mod pionfatt_mod.mod pio_nf_utils.mod pio_types.mod
calcdecomp.mod nf_mod.mod pio.mod pionfget_mod.mod pionfwrite_mod.mod pio_utils.mod
calcdisplace_mod.mod piodarray.mod pio_mpi_utils.mod pionfput_mod.mod pio_spmd_utils.mod rearrange.mod

lib/
libpio.a
 
Last edited:
As Whatheway said, it may be worth trying the latest PIO release (2.5.7 as of the time of writing this post). I know that some of our documentation mentions using PIO 1.7.1, but we should probably update that.

In case you're familiar with switching branches in a Git repository, you can try compiling from the 'develop' branch in the MPAS-Model repository. The 'develop' branch contains better logic for automatically detecting the correct PIO library version, and it also includes better diagnostic messages when the PIO library detection fails. This might help in debugging the PIO issue, but once that's resolved, I'd recommend switching back to the v7.3 release code for any science runs with MPAS-Atmosphere.
Michael, should I share the script here now?
 
I also have the same problem. The mpas version I tried is 7.3 and the latest version on github. I use PIO1.7.1. It seems install IPO2.xx is difficult, and I don't need parallel netcdf. My installation of pio1.7.1 seems successful as I can see include and lib in the folder. I also set PIO environment variable. But this error is still there. Can anyone give more suggestion? Thank you very much

Here are my pio1.7.1, I have much less files compared to 'sunweihao'

include/
alloc_mod.mod iompi_mod.mod pio_kinds.mod pio_msg_mod.mod pionfread_mod.mod pio_support.mod
box_rearrange.mod ionf_mod.mod piolib_mod.mod pionfatt_mod.mod pio_nf_utils.mod pio_types.mod
calcdecomp.mod nf_mod.mod pio.mod pionfget_mod.mod pionfwrite_mod.mod pio_utils.mod
calcdisplace_mod.mod piodarray.mod pio_mpi_utils.mod pionfput_mod.mod pio_spmd_utils.mod rearrange.mod

lib/
libpio.a
As I mentioned in an earlier post, the 'develop' branch of the MPAS-Model repository contains more robust logic for detecting PIO library versions. Would you be willing to give this a try? All that you'd need to do is to clone the MPAS-Model repository and checkout the 'develop' branch:


Then, you can compile as usual, but without any specification of USE_PIO2. You may also want to do this from a new subdirectory that doesn't already contain an MPAS-Model directory.
 
@mgduda sounds good Ill attach the file to this thread

Good afternoon @music_piano & @sunweihao . Attached as a zip file, you will find a script that is currently in beta review that installs all the libraries and directories needed for installation of MPAS-Atmosphere.

To run the script.
1. unzip and move it to your Desktop
2. cd Desktop
3. enter command chmod 775 *.sh
4. execute the mpas install script.
5. run a test case

Please give it a try and send comments back to me and @mgduda

Thank you.
 

Attachments

  • MPAS-A_Install_Script.zip
    2.7 KB · Views: 61
@Whatheway @mgduda
Thank you very much for your help. I tried it. It was successful on Ubuntu. On the linux cluster, I cannot run the sudo command because I am just a user. I commented these lines and execute the script. The built was failed. Attached is the log file. The NETCDF folder was empty after finishing this script.

I guess the difference of the library version cause this issue. Do you have any suggestions?

Thank you
 

Attachments

  • log.txt
    2.5 MB · Views: 9
@Whatheway @mgduda
Thank you very much for your help. I tried it. It was successful on Ubuntu. On the linux cluster, I cannot run the sudo command because I am just a user. I commented these lines and execute the script. The built was failed. Attached is the log file. The NETCDF folder was empty after finishing this script.

I guess the difference of the library version cause this issue. Do you have any suggestions?

Thank you
I will take a look at it in the morning and see if I can get the script to work without sudo.
 
@Whatheway @mgduda
Thank you very much for your help. I tried it. It was successful on Ubuntu. On the linux cluster, I cannot run the sudo command because I am just a user. I commented these lines and execute the script. The built was failed. Attached is the log file. The NETCDF folder was empty after finishing this script.

I guess the difference of the library version cause this issue. Do you have any suggestions?

Thank you
Good morning @music_piano ,

So these files that are under the sudo command,

Bash:
##############################basic package managment#############################
sudo apt -y update
sudo apt -y upgrade
sudo apt -y install gcc gfortran g++ libtool automake autoconf make m4 default-jre default-jdk csh ksh git python3 python3-dev python2 python2-dev mlocate curl cmake

are required for the script to run. Otherwise you would have to install them all manually which is not an easy task. So what I would suggest is ask the system admin to install these apt packages on your linux cluster and then run the script again.

Once you get these required packages installed you should have access to the MPAS-Atmosphere model without any problems. It should run just like it would on a linux Ubuntu system.

The only other issue that could occur would be if your linux cluster is on CentOS. This script is made for Debian Linux systems and is not compatible with CentOS systems.

Let me know if you are able to get it to work.

Regards,
Will
 
Good morning @music_piano ,

So these files that are under the sudo command,

Bash:
##############################basic package managment#############################
sudo apt -y update
sudo apt -y upgrade
sudo apt -y install gcc gfortran g++ libtool automake autoconf make m4 default-jre default-jdk csh ksh git python3 python3-dev python2 python2-dev mlocate curl cmake

are required for the script to run. Otherwise you would have to install them all manually which is not an easy task. So what I would suggest is ask the system admin to install these apt packages on your linux cluster and then run the script again.

Once you get these required packages installed you should have access to the MPAS-Atmosphere model without any problems. It should run just like it would on a linux Ubuntu system.

The only other issue that could occur would be if your linux cluster is on CentOS. This script is made for Debian Linux systems and is not compatible with CentOS systems.

Let me know if you are able to get it to work.

Regards,
Will
Thank you very much for your help. At this moment, due to some reason, I cannot ask the administrator to install these package for me. But no problem, I will first learn the model in Ubuntu on my computer. In the future, when I have the opportunity, I will use it in the cluster.
 
Thank you very much for your help. At this moment, due to some reason, I cannot ask the administrator to install these package for me. But no problem, I will first learn the model in Ubuntu on my computer. In the future, when I have the opportunity, I will use it in the cluster.
Sounds good please let me or @mgduda know if you have any problems.
 
@mgduda sounds good Ill attach the file to this thread

Good afternoon @music_piano & @sunweihao . Attached as a zip file, you will find a script that is currently in beta review that installs all the libraries and directories needed for installation of MPAS-Atmosphere.

To run the script.
1. unzip and move it to your Desktop
2. cd Desktop
3. enter command chmod 775 *.sh
4. execute the mpas install script.
5. run a test case

Please give it a try and send comments back to me and @mgduda

Thank you.
Dear @mgduda and @Whatheway,
Good morning. Thanks for your advise and help. I am so sorry I missed the mail notification. Although I still can't compile it by myself, using this installation script I have successfully compile MPAS-A in the docker container with ubuntu:20.04. Thank you very much! (BTW, the installation is much more difficult than WRF. I think it will help for future promotion of MPAS if its installation is more friendly)

Regrads
 
Dear @mgduda and @Whatheway,
Good morning. Thanks for your advise and help. I am so sorry I missed the mail notification. Although I still can't compile it by myself, using this installation script I have successfully compile MPAS-A in the docker container with ubuntu:20.04. Thank you very much! (BTW, the installation is much more difficult than WRF. I think it will help for future promotion of MPAS if its installation is more friendly)

Regrads
When you say the installation needs to be more user friendly do you mean the install script or mpas in general?
 
When you say the installation needs to be more user friendly do you mean the install script or mpas in general?
In general, means that starting from dependency library installation.
From my experience it seems problem always appears when compile netcdf-c, netcdf-fortran or PIO using mpi complier, and subsequent MPAS's compling.

Install script is a good tool.
 
Top