The Login Command

The login command establishes your AccuRev user identity. In the "User Name" field, you must enter the name of a registered AccuRev user. If your organization has more than one AccuRev repository (each managed by a separate AccuRev server process), you can choose the server to which you want to connect.

Note: Active and inactive users. A user name can be Inactive (Remove User command) or Active (when first created; or when the Reactivate User command is used for an Inactive user). When you log in, the username must be currently Active.

See also: Security.

Invoking the Login Command

Choose Tools > Login from the GUI main menu. This command is invoked automatically:

  • At the beginning of an AccuRev GUI session if there is no valid session file in the .accurev subdirectory of your home directory.
  • When you invoke a command that requires user authentication, but your session has expired.

Back to top

Using the Login Dialog

To log in:

Type in your user name — and if you have one, your password — then click OK. Passwords are case-sensitive.

To switch to another server:

  1. Open the listbox by clicking the down-arrow, then select another AccuRev Server (hostname/port-number combination).
  2. Then, complete the login by typing your username (and password).

To add an AccuRev Server to the listbox:

  1. Click the Edit Available Servers button ().

    The Available AccuRev Servers dialog appears.
    For more information see The Available AccuRev Servers Dialog.

  1. Click the Add Server button () to specify:

    • The hostname (or IP address) where the additional AccuRev Server runs.
    • The IP port number on which it listens for AccuRev client requests.

Tip: The ACCUREV_SERVER environment variable influences which AccuRev Server the AccuRev GUI interacts with at startup time. See ENV_VARS in the AccuRev CLI User’s Guide for more information.

Back to top

Logging Out

To log out of AccuRev, you must use the accurev logout command:

> accurev logout

Logging out cancels the session that is created when you log in to AccuRev.
For more inforamtion see

See The "session" File below for more information.

Whether or not the session is canceled when you exit the AccuRev GUI is controlled by the Keep Session Active user preference. This preference is on by default — your session remains active even after you exit the AccuRev GUI.

SeeAccuRev Preferences (Tools > Preferences Command) for more information on setting preferences.

Back to top

The "session" File

A successful login command creates an encrypted file in the .accurev subdirectory of your home directory. This file records your AccuRev username and password, along with the IP address of your client machine. Most AccuRev client commands can be executed only by an authorized user. Such commands send the information in your session file to the AccuRev Server process, so that you don't need to repeatedly "remind" the AccuRev Server who (and where) you are.

Tip: You can specify whether you want AccuRev to cancel the user session when you exit the AccuRev GUI. For more information see Keep Session Active in General Page

Session Expiration

Session files are automatically deleted by the AccuRev Server after an administrator-configurable interval, which defaults to 240 minutes. This implements a session-expiration feature. Administrators can also actively cancel all sessions associated with a user using the accurev remove sessions command. See remove in the CLI User’s Guide for more information.

Multiple Session Files for Different Servers

The name of the session file includes the hostname and port number of the AccuRev Server. If you Login to different AccuRev Server processes, you'll have multiple session files, one for each Server.

Example:

session_VENUS_5050

session_MARS_5050

session_MARS_5999

These session files indicate that your are logged in to an AccuRev Server on host venus, listening on port 5050, and are also logged into two different AccuRev Server processes on host mars.

Multiple Session Files for the Same Server

What if you want to be testuser john in one GUI window, but testuser mary in another — both using the same AccuRev Server? You can't have two session files with the same name (for example, session_VENUS_5050) in your .accurev subdirectory. But you can have two or more session files with the same name in different .accurev subdirectories. The AccuRev GUI uses the value of environment variable ACCUREV_HOME as the location of the .accurev subdirectory (and will create this subdirectory, if necessary). It also uses ACCUREV_HOME whenever it checking for the existence of a session file in order to authenticate you.

Example (Windows):

  1. Set ACCUREV_HOME to c:\myusers\john.
  2. Create directory c:\myusers\john.
  3. Start the AccuRev GUI.
  4. Login as john.
  5. Set ACCUREV_HOME to c:\myusers\mary.
  6. Create directory c:\myusers\mary.
  7. Start another instance of the AccuRev GUI.
  8. Login as mary in this second instance.

Tip: Setting up scripts to run the AccuRev GUI makes it easier to ensure that the GUI will be running with the environment variable set correctly.

Back to top