Failed to Log in to OpenResty Edge Admin
This document will help you resolve common issues encountered when logging in to OpenResty Edge Admin.
Error Message: “Incorrect login credentials”
Physical Machine or Virtual Machine Environment
Method 1: Obtain Credentials Using the Installation Script
If you installed OpenResty Edge Admin Database using openresty-edge-installer.sh
from openresty-edge-VERSION.tar.gz
, follow these steps:
Run the installation script again:
bash openresty-edge-installer.sh
Select the following options when prompted:
- Choose action:
6) get
- Select component:
1) default-info
- Choose action:
The script will display login information, including username and password.
Method 2: Locate the Initialization Script
If Method 1 fails, try the following commands:
find ./ -name 'init-admin-db.sh' | xargs -n1 grep -rs 'password :'
Use the password found and the username admin
to log in.
Kubernetes Environment
For environments set up in Kubernetes using the openresty-edge-VERSION.yml
file, execute:
grep -A 1 'EDGE_ADMIN_INIT_PASSWORD' openresty-edge-VERSION.yml | tail -n 1 | awk -F "'" '{print $2}'
Use the output password and the username admin
to log in.
Reset Password
If the above methods fail, you can reset the password in the database:
Log in to OpenResty Edge Admin Database:
/usr/local/openresty-postgresql12/bin/psql -U postgres -d or_edge_admin
Note: For openresty-postgresql15 or other database versions, use the appropriate path.
Execute the following SQL command to reset the password:
UPDATE users SET password = '8000$08$01$3a2c8ff2a9e24b1d$342b6a5a3472282be25c3cb1a6bb1db8a4ca8acf5644321e92ab6fb46d884ef9', requires_password_change = TRUE WHERE username = 'admin';
The password will be reset to
openresty@admin
.
Error Message: “no pg_hba.conf entry for host “x.x.x.x”, user “or_edge_admin””
This error indicates that OpenResty Edge Admin lacks permission to access the database. Follow these steps to resolve:
Note: Adjust commands according to your OpenResty PostgreSQL version.
Edit the
pg_hba.conf
file:vim /var/postgres12/data/pg_hba.conf
Add the following content (replace
x.x.x.x/x
with the actual IP address):host or_edge_admin or_edge_admin x.x.x.x/x md5
Restart the database service:
sudo systemctl restart openresty-postgresql12
Need Further Assistance?
If you still encounter issues, please contact our support team:
- Email: support@openresty.com
Our technical support team will be happy to assist you.