question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ReplyError: NOAUTH Authentication required - even if password 100% correct.

See original GitHub issue

Hello colleges.

I have issue with authenticated connection to Redis. I set up password in redis.conf and in redis-cli authentication is passing normally, but in ioredis client not. It always throw error: ReplyError: NOAUTH Authentication required - even if password is 100% correct. Password is simple for testing of course. Without setting password everything also is OK.

My code:

const Redis = require('ioredis')

const client = new Redis({
   host: '127.0.0.1',
   port: 6379,
   db: 0,
   password: 'qwerty',
   enableReadyCheck: true,
   autoResubscribe: true,
   retryStrategy: times => {
      return Math.min(times * 500, 5000)
   }
})

client.on('ready', () => {
   console.log('Redis server is ready.')
})

client.on('error', error => {
   console.log('Error in Redis server: ' + error)
})

What could be the problem? Thank you.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
SirPhemmieycommented, Apr 4, 2020

Just leaving this here for future persons.

This issue will likely happen if you set a password for Redis while you have an instance already running. So if you’re sure that your password is correct, restart the Redis server brew services stop redis and brew services start Redis. You should not have the issue again.

1reaction
pantuchycommented, Mar 28, 2020

yeah it seems there’re three Redis instance being created (can tell from the first three lines in the logs), two of which don’t have password option set.

Thank you so much for Your help. Problem is not in ioredis at all. I am using BullMQ with Redis, so BullMQ probably is creating multiple instances of connection or any other problem.

Thank you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Node-Redis: ready check failed - NOAUTH Authentication ...
NOAUTH Authentication required is caused by when redis process command , it found the client is not authenticated so it complained with it....
Read more >
Redis (error) NOAUTH Authentication required - Server Fault
Setting the requirepass configuration directive causes the server to require password authentication with the AUTH command before sending other commands.
Read more >
Redis NOAUTH authentication required - How we fix it?
The error Redis NOAUTH authentication required occurs when the redis has a password set. We can fix it by using the AUTH command...
Read more >
Why Is "(error) NOAUTH Authentication required" Displayed ...
This is because you have enabled password-free access for the instance. To prevent the error message from appearing, do not enter any password....
Read more >
NOAUTH Authentication Required | Upstash: Documentation
The client can not connect to the database throwing an exception similar to: [ioredis] Unhandled error event: ReplyError: NOAUTH Authentication required ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found