Re: [DuMuX] Turn off MPI support for the dune-uggrid module

2018-03-08 Thread Håkon Hægland

Hi Timo,

thanks for your advice!

I think the server is running Ubuntu 14.04, so then the system
is approximately 4 years old I guess?

By the way I am using DUNE modules

dune-common, dune-istl, dune-grid, dune-uggrid, dune-geometry, and 
dune-localfunctions


all version 2.5.1 together with DuMuX
version 2.12.0, and the master branch of dumux-devel; all cloned by
git from

https://github.com/dune-project/ and
https://git.iws.uni-stuttgart.de/dumux-repositories/

except for dune-uggrid, which was cloned from

https://github.com/dune-mirrors/dune-uggrid.git

I create and issue at the dune-uggrid repository:

https://gitlab.dune-project.org/staging/dune-uggrid/issues/39

Best regards,
Håkon

___
Dumux mailing list
Dumux@listserv.uni-stuttgart.de
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux


Re: [DuMuX] Turn off MPI support for the dune-uggrid module

2018-03-07 Thread Timo
Hi Håkon,

I think you are going in the right direction of trying to compile on the 
cluster, which should give you less headache then linker issues.

Out of interest, is the server running macOS? I never heard of such 
difficulties installing a C++ 14 conforming compiler with the 
corresponding standard library implementation.

Often compiler packages include the right standard library implementation.

The UGGrid error might be related to a missing BLAS library. However, UG 
should handle this I think. Would you post your problem on the dune 
mailing list? Or open an issue on the dune-uggrid repository with the 
error message when compiling "dune-uggrid/np/algebra/blasm.cc".

You can also try dune-alugrid if you just want an unstructured grid 
implementation.


Best wishes
Timo

On 07.03.2018 11:48, Håkon Hægland wrote:
> Hi Timo,
>
> here follows a short update on my previous post.
>
> By investigating the the cmake module CheckCXXFeatures.cmake, it was 
> found
> that libc++abi was missing on the server. After installing the package 
> libc++abi-dev
> on the server, dune-control actually made some progress in the 
> build-process.
>
> It was able to build the dune-common module, then it started on
> dune-uggrid:
>
> [...]
> [ 83%] Building CXX object np/algebra/CMakeFiles/algebra2.dir/blasm.cc.o
> /scratch/fcihh/dune/dune-uggrid/np/algebra/blasm.cc:408:19: warning: 
> cast from 'char *' to 'DOUBLE *' (aka 'double *') increases required 
> alignment from 1 to 8 [-Wcast-align]
>   M_ptr = (DOUBLE *) ((char *) mat + M_start_off_D);
>   ^
> [...]
> /scratch/fcihh/dune/dune-uggrid/np/algebra/blasm.cc:1237:36: error: 
> unexpected type name 'MATRIX': expected expression
>   M_start_off[type] = offsetof(MATRIX, value)
>
>
> And there follows several errors regarding unexpected type name for
> MATRIX or VECTOR..
>
> Then dune control aborts with the message:
>
> 61 warnings and 14 errors generated.
> make[2]: *** [np/algebra/CMakeFiles/algebra2.dir/blasm.cc.o] Error 1
> make[1]: *** [np/algebra/CMakeFiles/algebra2.dir/all] Error 2
> make: *** [all] Error 2
> --- Failed to build dune-uggrid ---
> Terminating dunecontrol due to previous errors!
>
>
> Best regards,
> Håkon Hægland
>
> ___
> Dumux mailing list
> Dumux@listserv.uni-stuttgart.de
> https://listserv.uni-stuttgart.de/mailman/listinfo/dumux

___
Dumux mailing list
Dumux@listserv.uni-stuttgart.de
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux


Re: [DuMuX] Turn off MPI support for the dune-uggrid module

2018-03-07 Thread Håkon Hægland

Hi Timo,

here follows a short update on my previous post.

By investigating the the cmake module CheckCXXFeatures.cmake, it was 
found
that libc++abi was missing on the server. After installing the package 
libc++abi-dev
on the server, dune-control actually made some progress in the 
build-process.


It was able to build the dune-common module, then it started on
dune-uggrid:

[...]
[ 83%] Building CXX object np/algebra/CMakeFiles/algebra2.dir/blasm.cc.o
/scratch/fcihh/dune/dune-uggrid/np/algebra/blasm.cc:408:19: warning: 
cast from 'char *' to 'DOUBLE *' (aka 'double *') increases required 
alignment from 1 to 8 [-Wcast-align]

  M_ptr = (DOUBLE *) ((char *) mat + M_start_off_D);
  ^
[...]
/scratch/fcihh/dune/dune-uggrid/np/algebra/blasm.cc:1237:36: error: 
unexpected type name 'MATRIX': expected expression

  M_start_off[type] = offsetof(MATRIX, value)


And there follows several errors regarding unexpected type name for
MATRIX or VECTOR..

Then dune control aborts with the message:

61 warnings and 14 errors generated.
make[2]: *** [np/algebra/CMakeFiles/algebra2.dir/blasm.cc.o] Error 1
make[1]: *** [np/algebra/CMakeFiles/algebra2.dir/all] Error 2
make: *** [all] Error 2
--- Failed to build dune-uggrid ---
Terminating dunecontrol due to previous errors!


Best regards,
Håkon Hægland

___
Dumux mailing list
Dumux@listserv.uni-stuttgart.de
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux


Re: [DuMuX] Turn off MPI support for the dune-uggrid module

2018-03-05 Thread Håkon Hægland

Hello Timo!

Thanks for the support.

The problem with compiling DuMuX on the computational server seems to
be that it is running an old version of Ubuntu (and an old version of 
gcc).


When I try the following command on the computation server:

$ ./dune-common/bin/dunecontrol --opts=dumux/debug.opts all
[...]
CMake Error at cmake/modules/CheckCXXFeatures.cmake:117 (message):
  dune-common requires compiler support for C++14, but your compiler 
only

  supports C++11.

It aborts due to too old version of the compiler. I had the server
admin install clang-3.9 and libc++-dev on the server and then tried
again using clang instead of gcc. I used these flags with dune-control:

CMAKE_FLAGS="\
  -DCMAKE_CXX_COMPILER=clang++-3.9 \
  -DCMAKE_C_COMPILER=clang-3.9 \
  -DCMAKE_CXX_FLAGS=\"$GXX_WARNING_OPTS $GXX_OPTS -stdlib=libc++\" \
  "

However, still the test for C++14 fails (even if the clang compiler
itself supports C++14) in dune-control.

So now I tried instead to compile the binary on my laptop and then copy
the binary and some shared libraries onto the server. This worked
well for structured grid (YaspGrid) but for UGGrid I got the following
error message when I tried to run the executable:


It looks like opal_init failed for some reason; your parallel process is
likely to abort.  There are many reasons that a parallel process can
fail during opal_init; some of which are due to configuration or
environment problems.  This failure appears to be an internal failure;
here's some additional information (which may only be relevant to an
Open MPI developer):
  opal_shmem_base_select failed
  --> Returned value -1 instead of OPAL_SUCCESS
[...]
*** An error occurred in MPI_Init
*** on a NULL communicator
*** MPI_ERRORS_ARE_FATAL (processes in this communicator will now abort,
***and potentially your MPI job)
[cipr-cmg-sim:67060] Local abort before MPI_INIT completed completed 
successfully, but am not able to aggregate error messages, and not able 
to guarantee that all other processes were killed!



So this is the reason why I am trying to compile uggrid without MPI
support.

Best regards,
Håkon Hægland

___
Dumux mailing list
Dumux@listserv.uni-stuttgart.de
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux


Re: [DuMuX] Turn off MPI support for the dune-uggrid module

2018-03-05 Thread Timo Koch

Hi Håkon,

if MPI is found on your system then MPI support will be enabled per 
default, no matter if you use YaspGrid or UGGrid.


The standard option is also that all libraries that are found will be 
linked to the executable which is why you can see the libs when you run 
"ldd executable" in there.


The problem is also most likely not only MPI but other linked libraries 
too. As you link the libraries of your laptop when compiling, you will 
usually not be able use an executable compiled on your laptop and run it 
on another machine.


However, you seem to be able to copy your executable to your cluster. So 
can't you copy the Dune/Dumux source files there and compile it on the 
cluster?


AFAIK, this is the standard way to do it.

If you are using a workflow where you install the dune modules, you can 
also install it locally by setting the CMAKE_INSTALL_PREFIX variable. If 
you are using the Dune Debian packages, you either have to convince your 
administrator to install them on the cluster, or switch to an 
installation from source (works just like you configured/compiled Dumux 
in that case).


I'll move the discussion to the mailing list. Please answer there if 
possible so that others can profit from the discussion.


Best wishes
Timo

--
___

Timo Koch  phone: +49 711 685 64676
IWS, Universität Stuttgart fax:   +49 711 685 60430
Pfaffenwaldring 61email: timo.k...@iws.uni-stuttgart.de
D-70569 Stuttgarturl: www.hydrosys.uni-stuttgart.de
___

___
Dumux mailing list
Dumux@listserv.uni-stuttgart.de
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux