Perforce 2007.2 Command Reference
<< Previous Chapter
p4 logger
Table of Contents
Index
Perforce on the Web
Next Chapter >>
p4 logout

p4 login

Synopsis

Log in to a Perforce server by obtaining a ticket.

Syntax

p4 [g-opts] login [ -a -p ] [ user ]
p4 [g-opts] login [ -s ]

Description

The p4 login command authenticates a user and creates a ticket that represents a session with a Perforce server. Once authenticated, a user may access the Perforce server until either the ticket expires or until the user issues the p4 logout command.

By default, tickets are valid for 12 hours, and only for the IP address of the workstation of the user that issued the p4 login command.

To obtain a ticket valid for all IP addresses (for instance, to use Perforce simultaneously on more than one machine), use p4 login -a. Users with tickets that are valid for all IP addresses still consume only one Perforce license.

Options

-a

Obtain a ticket that is valid for all IP addresses.

-p

Display the ticket, rather than storing it in the local ticket file.

-s

Display the status of the current ticket, if one exists.

g-opts

See the Global Options section.

Usage Notes

Can File Arguments Use
Revision Specifier?

Can File Arguments Use
Revision Range?

Minimal Access Level Required

N/A

N/A

list

Examples

p4 login

Prompt the user for a password; if the password is entered correctly, issue a ticket valid on the user's machine.

p4 -u builder login -a

Attempt to log in as user builder; if the password is entered correctly, issue a ticket valid on all machines.

Related Commands

To end a login session

p4 logout

To display tickets

p4 tickets


Perforce 2007.2 Command Reference
<< Previous Chapter
p4 logger
Table of Contents
Index
Perforce on the Web
Next Chapter >>
p4 logout
Please send comments and questions about this manual to [email protected].
Copyright 1999-2007 Perforce Software. All rights reserved.
Last updated: 05/21/07