How to flush Redis cache

To delete everything from redis cache, run the command

redis-cli FLUSHDB

This will delete all keys from the current DB.

To delete cache from all DB, run

redis-cli FLUSHALL

If Redis is on another server or needs password, you can use the following command

redis-cli -h IP_HERE -p PORT_HERE -a PASSWORD_HERE FLUSHDB

See Redis

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *