1. Download Redis installation package
Open Browser input address: http://download.redis.io/redis-stable.tar.gz Download the latest Redis stable installation package
Mac OS downloaded files are saved by default under the downloads file.
2. Compiling & Installing Redis
Open terminal into Downloads directory: CD Downloads,
Unzip the Redis installation package that you just downloaded: Tar xvzf redis-stable.tar.gz, redis-stable directory will be generated in the downloads directory.
Enter this directory in the terminal: CD redis-stable,
Compiling source code: Make
After successful compilation, the Redis-server (Redis service) and REDIS-CLI (Redis command line client) are generated under REDIS-STABLE/SRC.
Copy Redis-server and REDIS-CLI to/usr/local/bin/
sudo cp redis-server/usr/local/bin/
sudo cp redis-cli/usr/local/bin/
3. Start Redis-server
Starting Redis on the terminal input redis-server, if successful, the following prompt will appear:
4. Start REDIS-CLI
Another open terminal window, enter: REDIS-CLI, appears
127.0.0.1:6379>, then enter Ping, as shown
127.0.0.1:6379> Ping
PONG
Indicates that Redis is working correctly
Installing Redis on Mac OS X