ttserver安装

一、安装

1.下载源码包
wget http://fallabs.com/tokyocabinet/tokyocabinet-1.4.46.tar.gz 
wget http://jaist.dl.sourceforge.net/project/tokyocabinet/tokyotyrant/1.1.33/tokyotyrant-1.1.33.tar.gz



2.编译安装tokyocabinet
tar zxvf tokyocabinet-1.4.46.tar.gz 
cd tokyocabinet-1.4.46 
./configure --prefix=/usr/local/tokyocabinet
make 
make install 



3.编译安装tokyotyrant
tar zxvf tokyotyrant-1.1.33.tar.gz 
cd tokyotyrant-1.1.33 
./configure  --prefix=/usr/local/ttserver/ --with-tc=/usr/local/tokyocabinet/
make 
make install 


4.创建tokyotyrant数据文件存放目录以及日志文件,同步日志文件
mkdir -p /data/ttserver/data   #数据文件
mkdir -p /data/ttserver/ulog   #同步日志 
mkdir -p /data/ttserver/log    #日志文件


5.启动
/usr/local/ttserver/bin/ttserver -host 127.0.0.1 -port 11211 -dmn -pid /data/ttserver/ttserver1.pid
/usr/local/ttserver/bin/ttserver -host 127.0.0.1 -port 11212 -dmn -pid /data/ttserver/ttserver2.pid



6.异常
ttserver: error while loading shared libraries: libtokyocabinet.so.9: cannot open shared object file: No such file or directory

解决办法:
ln -s /usr/local/tokyocabinet/lib/libtokyocabinet.so.9 libtokyocabinet.so.9




你可能感兴趣的:(ttserver)