本文将介绍如何安装Redis在ubuntu系统上面。
步骤
-
~$ sudo apt-get update
-
~$ sudo apt-get install make gcc python-dev
- 下载, 解压和编译compile Redis:
$ wget http://download.redis.io/releases/redis-3.2.0.tar.gz $ tar xzf redis-3.2.0.tar.gz $ cd redis-3.2.0 $ make
- 启动Redis-server:
The binaries that are now compiled are available in the src directory. Run Redis with:d
michael@ubuntu:~$ cd redis-3.2.0 $ src/redis-server
- 启动默认Redis-client并与Server进行交互
michael@ubuntu:~$ cd redis-3.2.0 $ src/redis-cli redis> set name HelloWorld OK redis> get name "HelloWorld"