In one of the previous Redis posts I wrote about how you could authenticate and run a command in one go. Now, let’s see how to get the currently installed version of Redis. Although there are a couple of ways to do so, I’m going to pick the two laziest approaches.
Prerequisites
- Redis
Solution
Run the following command:
redis-server --version
redis-server -v
or, simply grep
the INFO server
command.
redis-cli INFO server | grep ^redis_version
Conclusion
To find more cool Redis commands and hacks, simply browse the Redis category. Feel free to leave a comment below and if you find this tutorial useful, follow our official channel on Telegram.