Requirements
- Java 1.6 or higher: Download
Download
- SociaLite 0.8.0-alpha: Download binary
GitHub repository: requires Apache-ant to build.
Setup
- Untar the downloaded file:
tar -xvf socialite.tar.gz
This will create a foldersocialite/
. - Set JAVA_HOME environment variable in your shell.
You can also set JAVA_HOME in
conf/socialite-env.sh
. - Optionally, edit
conf/socialite-env.sh
to adjust the heap size for SociaLite runtime with the SOCIALITE_HEAPSIZE variable. Run
bin/socialite
to start the interactive shell. If you see the following message, the installation for a single machine is complete.PySociaLite (Python integrated SociaLite) 0.8.0-alpha Type "help" for more information. Type "quit()" to quit. >>>
- Now you can jump to Quick Start or continue to cluster setup.
Cluster Setup
Edit
conf/master
andconf/slaves
to add master/slave machine names. The master node compiles SociaLite queries, and slave nodes execute the compiled queries. Master node also keeps track of liveness of slave nodes. Note that the master node can also serve as a slave node at the same time.Unpack
socialite.tar.gz
into all the cluster machines, in the same path. The root of the distribution is referred as SOCIALITE_HOME.Edit
conf/socialite-env.sh
to change SOCIALITE_BASE_PORT. SociaLite runtime uses up to 10 port numbers from the SOCIALITE_BASE_PORT for the internal communication (SOCIALITE_BASE_PORT, SOCIALITE_BASE_PORT+1, ..., SOCIALITE_BASE_PORT+9).Edit
conf/socialite-env.sh
to change SOCIALITE_WORKER_NUM (the number of worker threads in each slave node). If SOCIALITE_WORKER_NUM is not set, the number of cores in one of slave nodes will be used for SOCIALITE_WORKER_NUM.Optionally, you can set HADOOP_HOME variable in
conf/socialite-env.sh
if your SociaLite program accesses HDFS (Hadoop Distributed File System).Optionally, you can change log level in
conf/log4j.properties
.Run
bin/start-servers.sh
to start master/slave servers.bin/stop-servers.sh
will stop all the running master/slave servers, andbin/kill-servers.sh
will force stop all the servers.Run
bin/socialite -d
to start the interactive shell connected to the cluster.To check the recent logs in master/slave servers, run
bin/tail-logs
.