Install Redis Server on Ubuntu

A. apt-get install old version

You can easily install Redis 2.8 on Debian by this command:

sudo apt-get install redis-server

B. build latest version

To install the latest version, you need to build it by yourself.

sudo apt-get update
sudo apt-get install build-essential
tar xzf redis-stable.tar.gz
cd redis-stable
make test
sudo apt-get install tcl8.5
sudo make install

Installation complete. Now configure it.

cd utils
sudo ./

All done. Let’s check the version by this command.

redis-server --version

It will print info like following text.

Redis server v=3.2.0 sha=00000000:0 malloc=jemalloc-4.0.3 bits=32 build=96e283a03034e952

You can also run “redis-cli” and use “info” command to get more detail.

To control the service, use this command. (The port number depends on your own configuration)

sudo service redis_6379 [start | stop | restart]

Allow remote access

Before using remote redis server access, modify your conf file first.

#Allow all

#Allow only one IP

标签: none