]> git.evergreen-ils.org Git - Evergreen.git/blob - docs/admin/staff_from_command_line.adoc
Docs: Spell check corrections
[Evergreen.git] / docs / admin / staff_from_command_line.adoc
1 Managing Staff from the Command Line
2 ====================================
3
4 Changing passwords
5 ------------------
6
7 If you need to change a patron or staff account password without using the staff client, here is how you can reset it with SQL.
8
9 Connect to your Evergreen database using _psql_ or similar tool, and retrieve and verify your admin username:
10
11 [source, sql]
12 ------------------------------------------------------------------------------
13 psql -U <user-name> -h <hostname> -d <database>
14
15 SELECT id, usrname, passwd from actor.usr where usrname = 'admin';
16 ------------------------------------------------------------------------------
17
18 If you do not remember the username that you set, search for it in the _actor.usr_ table, and then reset the password.
19
20 [source, sql]
21 ------------------------------------------------------------------------------
22 UPDATE actor.usr SET passwd = <password> WHERE id=<id of row to be updated>;
23 ------------------------------------------------------------------------------
24
25 The new password will automatically be hashed.
26