EVAL "local keys = redis.call('keys', ARGV[1]) \n for i=1,#keys,5000 do \n redis.call('del', unpack(keys, i, math.min(i+4999, #keys))) \n end \n return keys" 0 prefix:*
redis-cli CLIENT LIST
https://gist.github.com/shukla2112/b9688800bf71f7be66e76943abecf729
redis-cli --scan | while read LINE ; do TTL=`redis-cli ttl "$LINE"`; if [ $TTL -eq -1 ]; then echo "$LINE"; fi; done;
Ref - https://stackoverflow.com/a/56265879
info keyspace
DBSIZE