Tuesday, April 24, 2018 04:34 am EDT

How To Fix Drupal 7 Blocked Account After 5 Incorrect Password Attempts

Bri's picture

Have you ever come across the situation where you key in a password incorrectly more than 5 times? When you are using Drupal 7, you will get the following message:

Sorry, there have been more than 5 failed login attempts for this account. It is temporarily blocked. Try again later or request a new password.

Even after requesting a new password, you may get this message again. This can be a real problem if it happens to occur for user 1. The quickest fix is to remove all the records from the flood table. This might be a problem if you want to keep certain IP addresses and users locked out, but if you happen to lock yourself out locally or on a development site it will get you back in right away. Of course you need MySQL access, but run the following query:

DELETE FROM `flood`;

There are also a couple of contributed module that appear to help you manage this, but I have not tried them myself.

Flood Control Module
Flood Unblock Module