# Initialising the Plom server

The server handles all communication between the database (which stores all the information about your test) and the various programmes, including plom-client, plom-manager, plom-build, plom-scan, and plom-finish.

## Directories and Initialise

Decide on a working directory for the server. This need not be where you want to build your paper (or even on the same computer) but for the purposes of this walkthrough we will use a common directory called “midterm” which we create using:

$plom-server users Creating 'userListRaw.csv' - please edit passwords for 'manager', 'scanner', 'reviewer', and then add one or more normal users and their passwords. Note that passwords must be at least 4 characters and usernames should be at least 4 alphanumeric characters.  The userListRaw.csv file is plain-text, so anyone who can read that file can view the passwords. Open it up and edit it: "user","password" "manager", "1234" "scanner", "4567" "reviewer", "7890" "user0", "0123" "user1", "0123" "user2", "0123"  Notice that the template contains the 3 special users, and some normal users. Change the passwords and rename “user0” if you like. Save the result and we’ll explain what to do with that file in a moment. ### Automatic user generation When you have a large marking team you may not want to sit down and create all their usernames and passwords. Plom can auto-generate random usernames and passwords for you and you can then supply each member of your team with one of these random users as needed. To generate$N$users, run plom-server users --auto N: $ plom-server users --auto 3
Creating an auto-generated named user list at 'userListRaw.csv'
Please edit as you see fit and then rerun 'plom-server users userListRaw.csv'


The file contains something like:

"user","password"
"reviewer","give32big"
"duska","she40than"
"talia","lion94bell"
"usher","win34city"
"yuri","rainy60brave"


You can also use --auto N --numbered to create numbered users. The passwords are generated using something like the xkcd scheme. Again, You are free to edit the resulting file as you see fit.

### Processing the raw user list

Now that userListRaw.csv has been created and edited (by either method), it needs to be checked and the passwords hashed. To do this rerun plom-server users on the raw user list:

\$ plom-server users userListRaw.csv
Processing user file 'userListRaw.csv' to serverConfiguration/userList.json


At this point you can keep the userListRaw.csv somewhere safe or destroy it as you see fit (the server doesn’t use it).

Next we will build a spec to describe our test before starting the server.