Skip to content

Instantly share code, notes, and snippets.

@fadushin
Forked from alexmoore/0. Riak on Raspberry Pi's
Created January 11, 2018 18:01
Show Gist options
  • Save fadushin/d5ed43bb0b54533f998402f29e808448 to your computer and use it in GitHub Desktop.
Save fadushin/d5ed43bb0b54533f998402f29e808448 to your computer and use it in GitHub Desktop.
Building Basho Erlang / Riak TS on a Raspberry Pi 3
This is unsupported by Basho, but you can build Basho's flavor of Erlang and Riak on Raspberry Pis.
sudo apt-get install build-essential git autoconf libncurses5-dev openssl libssl-dev fop xsltproc unixodbc-dev libpam0g-dev oracle-java8-jdk maven
mkdir src
cd src
wget http://s3.amazonaws.com/downloads.basho.com/erlang/otp_src_R16B02-basho10.tar.gz
tar zxvf otp_src_R16B02-basho10.tar.gz
cd OTP_R16B02_basho10/
# Note: These steps will take a long time.
./otp_build autoconf
./configure
make
sudo make install
# Report version & arch
erl -eval 'erlang:display(erlang:system_info(otp_release)), erlang:display(erlang:system_info(system_architecture)), halt().' -noshell
# cd back to src dir
cd ../;
# In src dir
git clone https://github.com/basho/riak.git
cd riak
# Run this to build Riak TS 1.5.0
git checkout riak_ts-1.5.0
# Run this to build Riak KV 2.2.1
git checkout riak-2.2.0
make locked-deps
cd deps/eleveldb/c_src/leveldb;
git checkout develop;
cd ../
# If not using a cluster of pis, edit number of leveldb threads to save memory
#sed -i '221s/71/7/g' eleveldb.cc
cd ../../../;
make rel;
cd rel/riak/
echo "leveldb.limited_developer_mem = on" >> etc/riak.conf
## Edit the nodename and ip bindings in the etc/riak.conf file too, riak@raspberrypi may not work
bin/riak start;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment