Install ssdb-rocks on CentOS 6
Install ssdb-rocks on CentOS 6
为了优化节操精选的弹幕系统,打算更换到Facebook的RocksDB测试,为了支持多台Web Server的场景,打算直接上ssdb-rocks来完成目的,如果有这个需求的朋友还遇到过坑,可以参考一下步骤:
RocksDB需要的依赖
yum install zlib zlib-devel bzip2 bzip2-devel gflags gflags-devel snappy snappy-devel
RocksDB需要的gcc47-c++
- cd /etc/yum.repos.d/
- wget http://people.centos.org/tru/devtools-1.1/devtools-1.1.repo
- yum --enablerepo=testing-1.1-devtools-6 install devtoolset-1.1-gcc devtoolset-1.1-gcc-c++
- 导入环境变量
export CC=/opt/centos/devtoolset-1.1/root/usr/bin/gcc
export CPP=/opt/centos/devtoolset-1.1/root/usr/bin/cpp
export CXX=/opt/centos/devtoolset-1.1/root/usr/bin/c++
安装ssdb-rocks
- git clone https://github.com/ideawu/ssdb-rocks.git
- make && make install
注意:上面是我fork的原作者的库做了修改,如果使用作者的git repo安装可能会遇到下面的错误:2014-08-11现在的版本已经Fix了
/home/docker-cc/Downloads/ssdb-rocks/deps/rocksdb-master/librocksdb.a(env_posix.o): In function `rocksdb::(anonymous namespace)::PosixEnv::NowNanos()':
/home/docker-cc/Downloads/ssdb-rocks/deps/rocksdb-master/util/env_posix.cc:1342: undefined reference to `clock_gettime'
collect2: error: ld returned 1 exit status
make[1]: *** [all] Error 1
make[1]: Leaving directory `/home/docker-cc/Downloads/ssdb-rocks/src'
make: *** [all] Error 2
修改build.sh文件,把:
case "$TARGET_OS" in
Darwin)
#PLATFORM_CLIBS="-pthread"
#PLATFORM_CFLAGS=""
;;
Linux)
PLATFORM_CLIBS="-pthread"
;
中的Linux)部分修改成“-pthread -lrt"就好了
原文链接: http://onlyvc.us/install-ssdb-rocks-on-centos-6/
Install ssdb-rocks on CentOS 6的更多相关文章
- Install .Net Core For CentOS
Install .NET Core SDK Before you start, please remove any previous versions of .NET Core from your s ...
- [转载]How to Install Firefox 33 on CentOS, Redhat and Other Linux Distributions
FROM: http://tecadmin.net/install-firefox-on-linux/ Firefox 33 has been released for Systems and And ...
- Install RabbitMQ server in CentOS 7
About RabbitMQ RabbitMQ is an open source message broker software, also sometimes known as message-o ...
- Install Docker Engine on CentOS 在CentOS 7 上安装Docker
Install Docker Engine on CentOS OS Requirements 系统要求 To install Docker Engine,you need a maintained ...
- Centos 7.5 通过yum安装GNOME Desktop时出现:file /boot/efi/EFI/centos from install of fwupdate-efi-12-5.el7.centos.x86_64 conflicts with file from package grub2-common-1:2.02-0.65.el7.centos.2.noarch
系统版本为: [root@s10 ~]# cat /etc/redhat-release CentOS Linux release 7.5.1804 (Core) 由于管理kvm虚拟机的需求,需要安装 ...
- 转载--How to Install VMware Tools on CentOS 6.3
源地址:http://www.ehowstuff.com/how-to-install-vmware-tools-on-centos-6-3/ VMware Tools is a group of u ...
- install keepalived on RedHat/CentOS to provide IP failover for web cluster
Contents [hide] 1 Introduction 2 Our Sample Setup 3 Install Keepalived 4 Install Kernel Headers 5 C ...
- install erlang environment on centos
#(erlide in linux can't detect the runtime if build from source, but erlang shell works correctly)su ...
- CentOS7: How to install Desktop Environments on CentOS 7?
1. Installing GNOME-Desktop: Install GNOME Desktop Environment on here. # yum -y groups install &quo ...
- install docker swarm on centos
ref: https://sonnguyen.ws/install-docker-docker-swarm-centos7/ https://hostadvice.com/how-to/how-to- ...
随机推荐
- java和linux的编码
最近要使用中科院计算所的关键词工具NLPIR,用java调用,在windows下测试后放到linux下跑,就发现会有乱码. windows下默认是GBK,linux下是utf-8,因此在意料之中(尽管 ...
- OVER(PARTITION BY)函数介绍
问题场景 最近在项目中遇到了对每一个类型进行求和并且求该类型所占的比例,当时考虑求出每种类型的和,并在java中分别对每一种类型的和与总和相除求出所占比例.后来,想到这样有点麻烦,并且项目中持久层使用 ...
- Calender的使用详解
Calendar和GregorianCalendar简介 Calendar的中文翻译是日历,实际上,在历史上有着许多种计时的方法.所以为了计时的统一,必需指定一个日历的选择.那现在最为普及和通用的日历 ...
- ZOJ 3201 树形dp+背包(简单题)
#include<cstdio> #include<vector> #include<cstring> #include<iostream> using ...
- 【POJ 1062】昂贵的聘礼(最短路)
Dijkstra最短路,每次限制一个等级差,再更新答案. #include <cstdio> #define N 105 #define INF 1e9 int m, n; int p[N ...
- BZOJ-3668 起床困难综合症 位运算+贪心
faebdc学长杂题选讲中的题目...还是蛮简单的...位运算写的不熟练... 3668: [Noi2014]起床困难综合症 Time Limit: 10 Sec Memory Limit: 512 ...
- POJ2226 Muddy Fields
Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 10149 Accepted: 3783 Description Rain ...
- 使用I/O 系统调用--copy.c
作为Linux/Unix 系统编程入门,小生按照自己可以理解的方式,改写了源copy.c源代码来自:Linux/UNIX 系统编程手册 上册 P57 #include <stdio.h>/ ...
- memcached安装和php-memcached扩展安装.update.2014-08-15
服务器端主要是安装memcache服务器端,目前的最新版本是 memcached-1.3.0 .下载官网:http://www.danga.com另外,Memcache用到了libevent这个库用于 ...
- linux安全加固(1)
Redhat是目前企业中用的最多的一类Linux,而目前针对Redhat攻击的黑客也越来越多了.我们要如何为这类服务器做好安全加固工作呢? 一. 账户安全 1.1 锁定系统中多余的自建帐号 检查方法: ...