Is there a way to print the number of keys in Redis?
I am aware of
keys *
But that seems slightly heavy weight. – Given that Redis is a key value store maybe this is the only way to do it. But I would still like to see something along the lines of
count keys *
Best Answer
You can issue the INFO command, which returns information and statistics about the server. See here for an example output.
As mentioned in the comments by mVChr, you can use
info keyspace
directly on the redis-cli.