Using Redis on Mac
April 16, 2023
Prerequisite: Have brew
installed on your macbook.
Install redis using homebrew
brew install redis
Starting the redis using homebrew
brew services start redis
It will start redis and restart it on login.
Check status of redis using homebrew
brew services info redis
If the redis is running you'll get an output like below:
redis (homebrew.mxcl.redis)
Running: ✔
Loaded: ✔
User: johnWick
PID: 69875
Connect to redis using homebrew
redis-cli
Stop redis using homebrew
brew services stop redis
Restart redis using homebrew
brew services restart redis
Clear redis storage using homebrew
redis-cli flushall
Reference: Redis official Docs
Hope it was helpful. Thank you.