debugsqlMinor
how to fix "your account is locked. please contact admin" issue in postgresql when login
Viewed 0 times
fixcontactpostgresqlyouradminpleaseissuelockedloginaccount
Problem
I'm new to PostgreSQL.I'm using postgreSQL locally. I used it last time without any issues. Now, when I try login with my login credentials it shows the account is locked message all the time.
Solution
According to the pgadmin documentation there are two ways to unlock the user.
Locate the pgAdmin4.db file and open it using any DB Browser (or DB Browser for SQLite)
After opening the DB file, head towards ‘Execute SQL’ section.
Run below query :
And make sure the query changes are committed.
- Updating SQLite DB (pgAdmin4.db):
Locate the pgAdmin4.db file and open it using any DB Browser (or DB Browser for SQLite)
After opening the DB file, head towards ‘Execute SQL’ section.
Run below query :
UPDATE USER SET LOCKED = false, LOGIN_ATTEMPTS = 0 WHERE USERNAME = And make sure the query changes are committed.
- Increase the MAX_LOGIN_ATTEMPTS in the pgadmin configuration file config.py or preferably add a line in config_local.py
MAX_LOGIN_ATTEMPTS = 5Code Snippets
UPDATE USER SET LOCKED = false, LOGIN_ATTEMPTS = 0 WHERE USERNAME = <YOUR_EMAIL_ID>MAX_LOGIN_ATTEMPTS = 5Context
StackExchange Database Administrators Q#299063, answer score: 5
Revisions (0)
No revisions yet.