Problems with beagle/beast (Unable to load CPU plugin)

96 views
Skip to first unread message

Oliver Stueker

unread,
Nov 15, 2018, 3:02:56 PM11/15/18
to beast-users
Hi,

I'm trying to install Beast and beagle-lib for our HPC clusters and I'm having problems with that.

I'm first installing beagle-lib/3.1.0 into one directory. The environment module sets the BEAGLE_LIB variable to it's .../beagle-lib/3.1.0/lib directory.
Then I'm installing beast/2.5.1 into a different directory and create the environment module, which sets BEAST_LIB to .../beast/2.5.1/lib

So far so good.

However when I'm running "beast -beagle_info" , I'm getting:
Unable to load CPU plugin!
Please check for proper libhmsbeagle installation.

(see full output below).
  
  • Java and other dependencies are obviously there.
  • The "make check" of beagle-lib is also successful.
  • "ldd $BEAGLE_LIB/libhmsbeagle-jni.so"  shows it finds all it's linked libs.
  • The same happens with a combination of beast/2.4.8 and beagle-lib/3.0.2 .


Before setting BEAGLE_LIB, Beast couldn't find hmsbeagle-jni in java.library.path, but that was an easy fix.
On an older cluster I have beast/2.3.1 and beagle/2.1.2 and there I'm getting a proper output of "beast -beagle_info",  but those versions are rather old.



Does anyone have any ideas what I'm doing wrong?


Cheers,
Oliver


$ module purge
The following modules were not unloaded:
  (Use "module --force purge" to unload all):

  1) nixpkgs/16.09    3) icc/.2016.4.258     5) intel/2016.4      7) openmpi/2.1.1
  2) gcccore/.5.4.0   4) ifort/.2016.4.258   6) imkl/11.3.4.258   8) StdEnv/2016.4
$ module load beast/2.5.1

$ module list
Currently Loaded Modules:
  1) nixpkgs/16.09   (S)   4) ifort/.2016.4.258 (H)      7) openmpi/2.1.1  (m)  10) beagle-lib/3.1.0 (bio)
  2) gcccore/.5.4.0  (H)   5) intel/2016.4      (t)      8) StdEnv/2016.4  (S)  11) beast/2.5.1      (bio)
  3) icc/.2016.4.258 (H)   6) imkl/11.3.4.258   (math)   9) java/1.8.0_121 (t)

$ beast -beagle_info
[/cvmfs/soft.computecanada.ca/easybuild/software/2017/Core/java/1.8.0_121/bin/java, -Xms8g, -Xms256m, -Djava.library.path=/home/stuekero/.local/easybuild/software/2017/avx2/Compiler/intel2016.4/beagle-lib/3.1.0/lib, -cp, ::/home/stuekero/.beast/2.5/BEAST/lib/beast.jar:/home/stuekero/.beast/2.5/BEAST/lib/beast.src.jar, beast.app.beastapp.BeastMain, -beagle_info]

                        BEAST v2.5.1, 2002-2018
             Bayesian Evolutionary Analysis Sampling Trees
                       Designed and developed by
 Remco Bouckaert, Alexei J. Drummond, Andrew Rambaut & Marc A. Suchard
                                    
                     Department of Computer Science
                         University of Auckland
                                 [...]
                                 [...]
                                    
                   Institute of Evolutionary Biology
                        University of Edinburgh
                                 [...]
                                    
                    David Geffen School of Medicine
                 University of California, Los Angeles
                                 [...]
                                    
                      Downloads, Help & Resources:
                           http://beast2.org/
                                    
  Source code distributed under the GNU Lesser General Public License:
                   http://github.com/CompEvol/beast2
                                    
                           BEAST developers:
   Alex Alekseyenko, Trevor Bedford, Erik Bloomquist, Joseph Heled, 
 Sebastian Hoehna, Denise Kuehnert, Philippe Lemey, Wai Lok Sibon Li, 
Gerton Lunter, Sidney Markowitz, Vladimir Minin, Michael Defoin Platel, 
          Oliver Pybus, Tim Vaughan, Chieh-Hsi Wu, Walter Xie
                                    
                               Thanks to:
          Roald Forsberg, Beth Shapiro and Korbinian Strimmer


--- BEAGLE RESOURCES ---

Unable to load CPU plugin!
Please check for proper libhmsbeagle installation.

$ ls $BEAGLE_LIB 
libhmsbeagle-cpu.la         libhmsbeagle-cpu-sse.so         libhmsbeagle.la
libhmsbeagle-cpu.so         libhmsbeagle-cpu-sse.so.31      libhmsbeagle.so
libhmsbeagle-cpu.so.31      libhmsbeagle-cpu-sse.so.31.0.0  libhmsbeagle.so.1
libhmsbeagle-cpu.so.31.0.0  libhmsbeagle-jni.la             libhmsbeagle.so.1.3.0
libhmsbeagle-cpu-sse.la     libhmsbeagle-jni.so             pkgconfig

$ ls $BEAST_LIB 
beast.jar  beast.src.jar  DensiTree.jar  launcher.jar

Oliver Stueker

unread,
Nov 16, 2018, 9:54:52 AM11/16/18
to beast-users
I've tried a few more things without success:
  • tried with beagle-lib/3.1.1 (which was released just ~2 hours ago) because it claims: "Fixed pthread linking issue on Linux which prevented some programs from loading CPU plugin."
  • tried with beagle-lib/2.1.2 (in combination with beast/2.4.8)
  • tried with using GCC v5.4.0 instead of Intel compilers v2016.4.258
  • install manually in $HOME/.local/beast  directly on the cluster (the paths can otherwise become very long).
And anytime beast -beagle_info ends with:
Unable to load CPU plugin!
Please check for proper libhmsbeagle installation.
BEAGLE resources available:


The Java that I'm using is Oracle Java 1.8.0_121.  Beagle is downloaded as a tar.gz archive from GitHub.

Any hints are welcome!

Oliver

Terry Jones

unread,
Nov 16, 2018, 12:45:21 PM11/16/18
to beast...@googlegroups.com
Hi Oliver

Commiserations! :-)  I've also run into difficulties with this sort of thing a few times, sometimes managing to get through it. I've not seen the message you're getting, though.

Most recently it took me about 4 attempts to get BEAST2 to work with BEAGLE on a cluster. I eventually found the problem, which was that the system BEAGLE module which I was loading (also using the module system that you have access to) was compiled with an incompatible version of GCC. I ended up installing gcc 4.9 and with that things worked. YMMV, though, of course. I wrote up some notes as I went through the process - see the first URL below (the second gives some info about doing this on an Amazon GPU instance).  Hopefully the write-ups of my struggles will be of some use...

Terry


--
You received this message because you are subscribed to the Google Groups "beast-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.
To post to this group, send email to beast...@googlegroups.com.
Visit this group at https://groups.google.com/group/beast-users.
For more options, visit https://groups.google.com/d/optout.

Oliver Stueker

unread,
Nov 16, 2018, 12:59:52 PM11/16/18
to beast-users
Thanks for the feedback Terry.

I was just able to solve it by myself and it had nothing to do with the compiler/version.

It turned out that setting rpaths on the libraries is not sufficient and $BEAGLE_LIB needs to be added to the LD_LIBRARY_PATH.  
The `beast` wrapper shell script actually appends /usr/local/lib to the LD_LIBRARY_PATH for that reason. 

I'm most likely going to patch the beast script to append $BEAGLE_LIB instead of /usr/local/lib to LD_LIBRARY_PATH in our installation.

Mystery solved!

Oliver

Terry Jones

unread,
Nov 16, 2018, 1:07:46 PM11/16/18
to beast...@googlegroups.com
Good - glad to hear you got it sorted :-)

Terry

Reply all
Reply to author
Forward
0 new messages