Changeset 4018
- Timestamp:
- Nov 24, 2021, 12:16:45 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
BOL/script_install/install_lmdz.sh
r3983 r4018 34 34 ########################################################################### 35 35 36 echo install .sh DEBUT `date`36 echo install_lmdz.sh DEBUT `date` 37 37 38 38 set -e … … 81 81 # - NONE: bucket scheme (default) 82 82 # - CMIP6: orchidee version used in CMIP exercise, rev 5661 83 # - number: orchidee version number (not yet implemented)83 # - number: orchidee version number 84 84 veget=NONE 85 85 # choose the resolution for the bench runs … … 380 380 echo 'Please choose a new one (ifort) and change the line' 381 381 echo compiler=xxx 382 echo in the install .sh script and rerun it382 echo in the install_lmdz.sh script and rerun it 383 383 if [ `which gfortran44 | wc -w` -ne 0 ] ; then 384 384 gfortran=gfortran44 … … 559 559 cd $MODEL 560 560 myget src/modipsl_orc_cmip6.$version.tar.gz 561 echo install .sh wget_OK `date`561 echo install_lmdz.sh wget_OK `date` 562 562 gunzip modipsl_orc_cmip6.$version.tar.gz 563 563 tar xvf modipsl_orc_cmip6.$version.tar 564 564 \rm modipsl_orc_cmip6.$version.tar 565 565 fi 566 567 echo OK1568 566 569 567 if [ $netcdf = 1 ] ; then … … 607 605 fi 608 606 fi # of if [ "$with_xios" = "n" ] 609 echo install .sh netcdf_OK `date`607 echo install_lmdz.sh netcdf_OK `date` 610 608 fi # of if [ $netcdf = 1 ] 611 609 612 610 #====================================================================================== 613 echo OK 2ioipsl=$ioipsl611 echo OK ioipsl=$ioipsl 614 612 echo '##########################################################' 615 613 echo 'Installing MODIPSL, the installation package manager for the ' 616 614 echo 'IPSL models and tools' 617 615 echo '##########################################################' 616 echo `date` 618 617 619 618 if [ $netcdf = 0 -o $netcdf = 1 ] ; then … … 671 670 fi # of if [ "$use_shell" = "ksh" ] 672 671 672 echo install_lmdz.sh MODIPSL_OK `date` 673 673 #======================================================================================= 674 674 cd $MODEL/modipsl/modeles/IOIPSL/src … … 677 677 echo 'Compiling IOIPSL, the interface library with Netcdf' 678 678 echo '##########################################################' 679 echo `date` 679 680 echo log file : $ioipsllog 680 681 … … 724 725 725 726 fi 726 echo install .sh ioipsl_OK `date`727 echo install_lmdz.sh ioipsl_OK `date` 727 728 fi # of if [ $ioipsl = 1 ] 728 729 # Saving ioipsl lib for possible parallel compile … … 737 738 cd $MODEL/modipsl/modeles 738 739 xioslog=`pwd`/xios.log 739 echo "log file: $xioslog"740 740 #wget http://www.lmd.jussieu.fr/~lmdz/Distrib/install_xios.bash 741 741 myget import/install_xios.bash 742 742 chmod u=rwx install_xios.bash 743 744 # echo 'Need to work on install_xios implementation for jean-zay' 745 # exit 746 svn co http://forge.ipsl.jussieu.fr/ioserver/svn/XIOS/branchs/xios-2.5 XIOS747 cd XIOS/arch748 svn update749 cd ..750 ./make_xios --prod --arch $arch --job 4 > xios.log 2>&1751 743 if [ ${hostname:0:5} = jean- ] ; then 744 svn co http://forge.ipsl.jussieu.fr/ioserver/svn/XIOS/branchs/xios-2.5 XIOS 745 cd XIOS/arch 746 svn update 747 cd .. 748 echo "Compiling XIOS, start" `date` "(it takes about 20 min on Jean-Zay)" 749 echo "log file: $xioslog" 750 ./make_xios --prod --arch $arch --job 4 > xios.log 2>&1 751 else 752 752 ./install_xios.bash -prefix $MODEL/modipsl/modeles \ 753 753 -netcdf ${ncdfdir} -hdf5 ${ncdfdir} \ 754 754 -MPI $root_mpi -arch $arch > xios.log 2>&1 755 fi 756 if [ -f XIOS/lib/libxios.a ] ; then 757 echo "OK, XIOS library successfully generated" 758 fi 755 fi # of case Jean-Zay 756 if [ -f XIOS/lib/libxios.a ] ; then 757 echo "XIOS library successfully generated" 758 echo install_lmdz.sh XIOS_OK `date` 759 fi 759 760 fi 760 761 … … 778 779 orcbranch=`svn log -v -q svn://forge.ipsl.jussieu.fr/orchidee/ -r $veget |grep ORCHIDEE |head -1| sed -e 's:ORCHIDEE/.*$:ORCHIDEE:' | awk '{print $2}'` 779 780 # switch to that branch 781 echo IF YOU INSTALL ORCHIDEE THE VERY FIRST TIME, ASK for PASSWORD at orchidee-help@listes.ipsl.fr 780 782 svn switch -r $veget --accept theirs-full svn://forge.ipsl.jussieu.fr/orchidee/$orcbranch 781 783 svn log -r $veget | grep $veget … … 793 795 orchideelog=`pwd`/orchidee.log 794 796 echo '########################################################' 795 echo 'Compiling ORCHIDEE, the continental surface smodel '797 echo 'Compiling ORCHIDEE, the continental surface model ' 796 798 echo '########################################################' 799 echo Start of the first compilation of orchidee, in sequential mode: `date` 797 800 echo log file : $orchideelog 801 798 802 export ORCHPATH=`pwd` 799 803 xios_orchid="-noxios" … … 828 832 echo 'XIOS_LIBDIR="${ORCHDIR}/../XIOS/lib -lxios"' >> arch-local.path 829 833 cd ../ 830 # compiling ORCHIDEE sequential mode 831 834 835 echo ./makeorchidee_fcm -j $xios_orchid $opt_orc -parallel none -arch $arch 832 836 ./makeorchidee_fcm -j 8 $xios_orchid $opt_orc -parallel none -arch $arch > $orchideelog 2>&1 833 echo ./makeorchidee_fcm -j $xios_orchid $opt_orc -parallel none -arch $arch 834 echo End of the first compilation of orchidee ; pwd 835 else 837 pwd 838 else # of "if [ -d tools ]" 836 839 if [ -d src_parallel ] ; then 837 840 liste_src="parallel parameters global stomate sechiba driver" … … 846 849 cd .. 847 850 done 848 fi 849 echo install .sh orchidee_OK `date`850 fi # of if [ "$veget" = 1 ]851 fi # of "if [ -d tools ]" 852 echo install_lmdz.sh orchidee_compil_seq_OK `date` 853 fi # of if [ "$veget" != 'NONE' ] 851 854 852 855 … … 854 857 # Ehouarn: the directory name LMDZ* depends on version/tar file... 855 858 if [ -d $MODEL/modipsl/modeles/LMD* ] ; then 856 echo '########################################################## '857 echo ' Compiling LMDZ'858 echo '########################################################## '859 echo '###############################################################' 860 echo 'Preparing LMDZ compilation : arch file, svn switch if needed...' 861 echo '###############################################################' 859 862 cd $MODEL/modipsl/modeles/LMD* 860 863 LMDZPATH=`pwd` … … 930 933 931 934 echo '##################################################################' 932 echo Compile LMDZ 935 echo "Preparing script compile.sh for LMDZ compilation" 936 echo "It will only be run automatically if bench=1" 937 echo Here bench=$bench 933 938 echo '##################################################################' 934 echo log file : $lmdzlog935 939 936 940 if [ "$env_file" != "" ] ; then mv arch/arch-${arch}.env arch/arch-${arch}.orig ; \cp -f $env_file arch/arch-${arch}.env ; fi 937 941 938 echo install.sh avant_compilation `date`939 942 if [ $compile_with_fcm = 1 ] ; then makelmdz="makelmdz_fcm $optim -arch $arch -j 8 " ; else makelmdz="makelmdz $optim -arch $arch" ; fi 940 943 941 # sequential compilation and bench944 # sequential compilation 942 945 if [ "$sequential" = 1 ] ; then 943 echo "./$makelmdz $optim $OPT_MAKELMDZ $optim $opt_rad $opt_cosp -d ${grid_resolution} -v $veget_version gcm " >> compile.sh 944 chmod +x ./compile.sh 945 if [ $bench != 0 ] ; then ./compile.sh > $lmdzlog 2>&1 ; fi 946 echo install.sh apres_compilation `date` 947 948 946 echo Sequential compilation command, saved in compile.sh: 947 echo "./$makelmdz $optim $OPT_MAKELMDZ $optim $opt_rad $opt_cosp -d ${grid_resolution} -v $veget_version gcm " 948 echo "./$makelmdz $optim $OPT_MAKELMDZ $optim $opt_rad $opt_cosp -d ${grid_resolution} -v $veget_version gcm " >> compile.sh 949 chmod +x ./compile.sh 950 if [ $bench != 0 ] ; then 951 echo install_lmdz.sh start_lmdz_seq_compilation `date` 952 echo log file: $lmdzlog 953 ./compile.sh > $lmdzlog 2>&1 954 echo install_lmdz.sh end_lmdz_seq_compilation `date` 955 fi 949 956 fi # fin sequential 950 951 952 957 953 958 # compiling in parallel mode … … 956 961 echo ' Parallel compile ' 957 962 echo '##########################################################' 958 # saving the sequential libs and binaries963 echo "(after saving the sequential libs and binaries)" 959 964 cd $MODEL/modipsl 960 965 tar cf sequential.tar bin/ lib/ … … 978 983 mv tmp.fcm arch-local.fcm 979 984 cd ../ 980 echo compiling ORCHIDEE parallel mode985 echo Compiling ORCHIDEE in parallel mode `date` 981 986 echo logfile $orchideelog 987 echo "NOTE : to recompile it when necessary, use ./compile_orc.sh in modipsl/modeles/ORCHIDEE" 988 echo ./makeorchidee_fcm -j 8 -clean $xios_orchid $opt_orc -parallel $parallel -arch $arch > compile_orc.sh 989 echo ./makeorchidee_fcm -j 8 $xios_orchid $opt_orc -parallel $parallel -arch $arch >> compile_orc.sh 990 echo echo Now you must also recompile LMDZ, by running ./compile.sh in modeles/LMDZ >> compile_orc.sh 991 chmod u+x compile_orc.sh 982 992 ./makeorchidee_fcm -j 8 -clean $xios_orchid $opt_orc -parallel $parallel -arch $arch > $orchideelog 2>&1 983 993 ./makeorchidee_fcm -j 8 $xios_orchid $opt_orc -parallel $parallel -arch $arch >> $orchideelog 2>&1 984 echo ./makeorchidee_fcm -j 8 -clean $xios_orchid $opt_orc -parallel $parallel -arch $arch 985 echo ./makeorchidee_fcm -j 8 $xios_orchid $opt_orc -parallel $parallel -arch $arch 994 echo End of ORCHIDEE compilation in parallel mode `date` 986 995 elif [ $veget != 'NONE' ] ; then 987 996 echo '##########################################################' … … 990 999 echo '##########################################################' 991 1000 exit 992 fi # of if [ -d src_parallel ] 1001 fi # of [ -d src_parallel -a $veget != 'NONE' ] 1002 993 1003 # LMDZ 994 1004 cd $LMDZPATH … … 1010 1020 echo resol=${grid_resolution} >> compile.sh 1011 1021 if [ ${hostname:0:5} = jean- -a "$cosp" = "v2" ] ; then 1012 echo ATTENTION le probleme de cospv2 sur jean-zay en mode prod n est pas corrige 1022 1023 echo LMDZ compilation command in parallel mode, saved in compile.sh, is : 1024 echo "(ATTENTION le probleme de cospv2 sur jean-zay en mode prod n est pas corrige ! )" 1013 1025 # ATTENTION le probleme de cospv2 sur jean-zay en mode prod n est pas corrige 1014 1026 echo ./$makelmdz -dev $optim $OPT_MAKELMDZ $opt_rad $opt_cosp $opt_makelmdz_xios -d \$resol -v $veget_version -mem -parallel $parallel gcm >> compile.sh … … 1019 1031 fi 1020 1032 chmod +x ./compile.sh 1021 if [ $bench != 0 ] ; then ./compile.sh > $lmdzlog 2>&1 ; fi 1022 1023 echo "Compilation finished" 1033 1034 if [ $bench != 0 ] ; then 1035 echo Compiling LMDZ in parallel mode `date` 1036 echo LMDZ log file: $lmdzlog 1037 ./compile.sh > $lmdzlog 2>&1 1038 fi 1024 1039 1025 1040 fi # of if [ $parallel != "none" ] … … 1045 1060 else 1046 1061 echo '##########################################################' 1047 echo 'Compilation successfull !! ' 1062 echo 'Compilation successfull !! ' `date` 1048 1063 echo '##########################################################' 1049 1064 echo The executable is $gcm … … 1062 1077 \rm -rf BENCH${grid_resolution} 1063 1078 bench=bench_lmdz_${grid_resolution} 1064 echo install .sh before bench download `date`1079 echo install_lmdz.sh before bench download `date` 1065 1080 #wget http://www.lmd.jussieu.fr/~lmdz/Distrib/$bench.tar.gz 1066 1081 myget 3DBenchs/$bench.tar.gz 1067 echo install .sh after bench download `date`1082 echo install_lmdz.sh after bench download `date` 1068 1083 tar xvf $bench.tar.gz 1069 1084
Note: See TracChangeset
for help on using the changeset viewer.