Wednesday, January 4, 2012

Installing GraphLab on Centos 6.0

Note: this document described how to install GraphLab 1 (multicore version).
For other versions see: http://graphlab.org/downloads/

For Keren's request..
Login into your CentOS machine, or start Amazon EC2 instance: ami-03559b6a.

1) Installing libboost
yum install boost boost-devel
2) Installing itpp - this step is optional.
yum install lapack autoconf autogen libtool
ln -s /usr/lib64/liblapack.so.3.2.1 /usr/lib64/liblapack.so
ln -s /usr/lib64/libblas.so.3.2.1 /usr/lib64/libblas.so

yum groupinstall "Development Tools"
wget http://sourceforge.net/projects/itpp/files/itpp/4.2.0/itpp-4.2.tar.gz
tar xvzf itpp-4.2.tar.gz
cd itpp-4.2
./autogen.sh 
./configure --without-fft --with-blas=/usr/lib64/libblas.so.3 --with-lapack=/usr/lib64/liblapack.so.3 CFLAGS=-fPIC CXXFLAGS=-fPIC CPPFLAGS=-fPIC
make && make install
Note: future version of lalpack may have different library name, check your /usr/lib64
dir for the correct lapack/blas lib names.

3) Install Mercurial
yum install mercurial
4) Install cmake
yum install cmake
5a) Install graphlab from mercurial
Go to graphlab download page, and follow the download link to the mercurial repository.
copy the command string: "hg clone..." and execute it in your ubuntu shell.
hg update v1

or 5b) Install graphlab from tgz file
Go to graphlab download page, and download the latest release.
Extract the tgz file using the command: "tar xvzf graphlabapi_v1_XXX.tar.gz"
where XXX is the version number you downloaded.

6) configure using It++ (if you installed it in step 2)
cd graphlabapi
./configure --bootstrap --itpp_include_dir=/usr/local/include/ --itpp_dynamic_link_dir=/usr/local/lib/libitpp.so --itpp_lapack_dir=/usr/lib64/
6a) Alternatively - you can configure and compile using Eigen:
cd graphlabapi
./configure --bootstrap --eigen

7) compile
cd release/
make -j4

8) Test Graphlab
cd tests
export LD_LIBRARY_PATH=/usr/local/lib/
cd release/tests
./runtests.sh
8) Optional: install Octave.
TBD

10 comments:

  1. Can you update step 6? ./configure only has the following itpp related options:
    --itpp_include_dir
    --itpp_link_dir

    ReplyDelete
    Replies
    1. Hi,
      Maybe your version is not the latest? please try to do "hg pull; hg update" and retry.

      Best,

      DB

      Delete
  2. And why you don't use eigen by default?

    ReplyDelete
    Replies
    1. it++ is the default in version 1. In version 2 we switched s.t. eigen will be the default.

      Best,

      DB

      Delete
  3. I had to install developer tools on cent os 6 to get it running
    yum install lapack-devel blas-devel

    ReplyDelete
    Replies
    1. Thanks for the update! Don't hesitate to contact me with any further questions!!

      Delete
  4. There seems a typo in creating the links:
    ln -s /usr/lib64/liblalpack.so.3.2.1 /usr/lib64/liblapack.so
    should be liblapack.so.3.2.1

    ReplyDelete
  5. Hello, I installed version 2.1.0 of graphlab on Linux CentOS-6.3-but the script file ". / Configure" has not the settings in step 6 above. Also, I do not see a "runtest.sh" in the "release" directory.
    So I want to know what versions of graphlab are covered by your tutorial

    Thank you!

    ReplyDelete
    Replies
    1. Thanks for your note! The instructions are for version 1. Please follow the instructions: http://graphlab.org/downloads/ for version 2.

      Best,

      DB

      Delete