2.1. Creating the lockss User and Group

This section describes how to create the lockss system user and group (if necessary), under which the LOCKSS stack will run.

2.1.1. Establishing a root Session

The configuration and operation of LOCKSS entail commands run as lockss, but the installation of LOCKSS is largely done as root. We recommend opening a root console session and using it throughout this chapter. At first, this root session does not need to be in any particular directory.

2.1.2. Invoking adduser

To create the lockss user and group, follow these steps:

  1. Double-check that you are operating in the root session established for the entirety of this chapter [1] by typing:

    whoami
    

    and verifying that the output is root.

  2. Check if the lockss user already exists. Run this id command:

    id lockss
    
    • If the id command outputs information about the lockss user including its user ID (UID) and group ID (GID), for example:

      uid=958(lockss) gid=958(lockss) groups=958(lockss)
      

      then the lockss user already exists on the host, and you can proceed to Section 2.2 (Downloading the LOCKSS Installer).

    • If the id command outputs an error message, for example:

      id: ‘lockss’: no such user
      

      then the lockss user does not exist on the host yet, and you will need to create it below.

  3. If the lockss user needs to be created on the host, run this useradd command:

    useradd --system --user-group --create-home --shell=/bin/bash lockss
    

    This will create a lockss system user, a lockss system group, and a home directory in (typically) /home/lockss.


Footnotes