I am new to pgAdmin 4. I have forgot to setup of login Email id and password while install pgAdmin 4. How can I change after installation? Any one can help me?
I'm assuming that since you don't remember your admin/password, you didn't do much with pgAdmin yet. If that's the case, you can move/remove the SQLite database out of the way and restart pgAdmin:
rm /var/lib/pgadmin/pgadmin4-server.db
or
mv /var/lib/pgadmin/pgadmin4-server.db /tmp
When you do this, you'll be prompted for a password the next time you start up the app.
You can also dump the contents of the SQLite database before moving/removing:
sqlite3 /var/lib/pgadmin/pgadmin4-server.db .dump
As my friend @Almadani and @richyen post are completely right.
But If you are working on remote host databases its best to delete that folder.Such as it may on some instance[ssh]
sudo rm -rf /var/lib/pgadmin
After deletion of folder. you can simply create new credentials
sudo /usr/pgadmin4/bin/setup-web.sh
You can also check it out from the blog. By the way the blog is from here.
I solved this issue on Linux Fedora 32, and it's working. I hope you find it useful for you.
cd /var/lib/pgadmin4/
[root@localhost pgadmin4]# ls
pgadmin4.db sessions storage
[root@localhost pgadmin4]# rm pgadmin4.db
rm: remove regular file 'pgadmin4.db'? y
[root@localhost pgadmin4]# ls
sessions storage
there is still a way to find the database pgadmin4.db
download and open this file via HeidiSQL
as SQLite
, directly viewing the table is not available - you can run the query SELECT * from user
you will see your username, and if you do not remember the password can be changed to any known (encoded) - this method helped me
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With