Installation
Download, extract and compile Redis with:
$ wget http://download.redis.io/releases/redis-3.2.6.tar.gz
$ tar xzf redis-3.2.6.tar.gz
$ cd redis-3.2.6
$ make
$ make install
The binaries that are now compiled are available in the src
directory. Run Redis with:
$ src/redis-server
You can interact with Redis using the built-in client:
$ src/redis-cliredis> set foo bar
OK
redis> get foo
"bar"
安装完成以后运行不会再后台,所以查了下
只需要在启动命令后加上redis.conf的路径就行
cd /usr/local/src
$ wget http://download.redis.io/releases/redis-3.2.6.tar.gz
$ tar xzf redis-3.2.6.tar.gz
$ cd redis-3.2.6
$ make
$ make install
安装完成后再cd /usr/local/bin
目录下会有启动文件
./redis-server
只需要在后面加上conf的目录就可以
并修改conf文件
把daemonize设置为yes
./redis-server /usr/local/src/redis/redis.conf
这样就会在后台启动了