skip to Main Content

My redis db runs out of memory after 2-3 day, I do flush manually. But, I want to fushall automatically in nodejs.

2

Answers


  1. you should look why it happens at first place, maybe you could expire keys using tls check this link

    Other option would be just set a cronjob to flush redis once in a while(not recommended)

    Login or Signup to reply.
  2. Read about Redis’ maxmemory-policy and then choose one of the allkeys-* policies.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search