About This Manual

This manual documents every Perforce command, environment variable, and configurable. This manual is intended for users who prefer to learn by means of Unix-style man pages, and for users who already understand the basics of Perforce and need to quickly find information on a specific command.

The following table provides an index to the P4 Command Reference by functional area:


Where to look


p4 help, p4 info, “File Specifications”, “Views”, “Global Options”, “File Types”

Client workspace

p4 clean, p4 client, p4 clients, p4 flush, p4 have, p4 sync, p4 update, p4 where, p4 workspace, p4 workspaces


p4 add, p4 attribute, p4 copy, p4 delete, p4 diff, p4 diff2, p4 dirs, p4 edit, p4 files, p4 fstat, p4 grep, p4 move, p4 lock, p4 print, p4 reconcile, p4 rename, p4 revert, p4 status, p4 sizes, p4 unlock


p4 change, p4 changelist, p4 changes, p4 changelists, p4 describe, p4 filelog, p4 opened, p4 reopen, p4 review, p4 shelve, p4 submit, p4 unshelve


p4 fix, p4 fixes, p4 job, p4 jobs, p4 jobspec

Branching and Merging

p4 branch, p4 branches, p4 copy, p4 cstat, p4 integrate, p4 integrated, p4 interchanges, p4 istat, p4 label, p4 labels, p4 labelsync, p4 list, p4 merge, p4 populate, p4 tag, p4 resolve, p4 resolved, p4 stream, p4 streams


p4 admin, p4 archive, p4 cachepurge, p4 configure, p4 counter, p4 counters, p4 dbschema, p4 dbstat, p4 depot, p4 depots, p4 diskspace, p4 journals, p4 key, p4 keys, p4 license, p4 lockstat, p4 logappend, p4 logger, p4 logparse, p4 logrotate, p4 logschema, p4 logstat, p4 logtail, p4 monitor, p4 obliterate, p4 ping, p4 property, p4 proxy, p4 pull, p4 reload, p4 renameuser, p4 replicate, p4 restore, p4 reviews, p4 server, p4 serverid, p4 servers, p4 triggers, p4 typemap, p4 unload, p4 verify


p4 group, p4 groups, p4 login, p4 logout, p4 passwd, p4 protect, p4 protects, p4 tickets, p4 trust, p4 user, p4 users, P4CLIENTPATH, P4SSLDIR, P4TRUST



If you'd prefer to learn the concepts on which Perforce is based, or you prefer a style featuring more examples and tutorials than what you find here, see the P4 User's Guide, available from our web site at: http://www.perforce.com/documentation.

If there's anything we've left out that you think should be included, let us know. Please send your comments to .

What's new in this guide for the 2015.1 update

This section provides a summary of the notable changes in this guide for the 2015.1 update release. For a list of all new functionality and major bug fixes in Perforce Server 2015.1, see the Perforce Server 2015.1 Release Notes.

New commands

p4 ldapsync

Updates the users in the specified Perforce groups to match the members in the corresponding LDAP groups. The correspondence between a Perforce group and an LDAP group is defined in the Perforce group spec. If you do not specify a group name, all groups with LDAP configurations are updated.

p4 init

Creates a new personal server in a distributed versioning environment.

p4 clone

Clones a new personal server from a shared server in a distributed versioning environment.

p4 switch

Switches to a new stream, optionally creating it (in a distributed versioning environment).

p4 remote

Defines a connection to a shared server in a distributed versioning environment.

p4 remotes

Lists the known shared servers in a distributed versioning environment.

p4 fetch

Copies files from a shared server to a personal server in a distributed versioning environment.

p4 push

Copies files from a personal server to a shared server in a distributed versioning environment.

p4 unsubmit

Unsubmits a change, leaving the work in a shelf, in a distributed versioning environment.

p4 resubmit

Resubmits unsubmitted changes, in a distributed versioning environment.

p4 zip

Packages a set of files for use by the p4 unzip command in a distributed versioning environment.

p4 unzip

Imports files from a package created with the p4 zip command in a distributed versioning environment.

New command options and other command changes

p4 add

Using wild cards with the p4 add command makes it synonymous to p4 reconcile. That is, it will open files that exist in the workspace but not in the depot for add.

p4 admin setldapusers

Allows you to convert all existing non-super users to use LDAP authentication. The command changes the AuthMethod field in the user specification for each user from perforce to ldap. If super users want to use LDAP authentication, they must set their AuthMethod manually.

p4 interchanges

The command now also reports changes that consist solely of ignored integrations if those changes have not yet been integrated into the target.

p4 journalcopy

An operator may run the p4 journalcopy -l, p4 pull -l -j, and p4 pull -l -s commands. This makes it possible for an operator to confirm the state of a replica.

p4 passwd

If you use the -O option, you must use the -P option.

p4 pull

An operator may run the p4 journalcopy -l, p4 pull -l -j, and p4 pull -l -s commands. This makes it possible for an operator to confirm the state of a replica.

p4 reconcile

You may use p4 rec as a synonym for p4 reconcile.

Other changed behavior: files opened for delete and present in your workspace that don't have pending resolve records are reopened for edit.

p4 renameuser

If you are renaming a user authorized by means of a P4AUTH configuration, you must issue the p4 renameuser command for every server that the user is authorized to use.

p4 revert

The -C client option allows you to revert another user's open files.

The -a option allows you to revert files opened for add that are missing from the workspace.

p4 servers

A user with operator privileges may execute p4 servers and p4 servers -J.

p4 status

Displays files already opened in addition to files that need to be reconciled.

p4 stream

If you specify no arguments for the command, the target defaults to the current stream, and the source defaults to the current stream parent. You can also specify the stream as a directory name relative to the current stream depot.

The new options mergeany and mergedown specify whether the merge flow is restricted or whether merge is permitted from any other stream. For example, the mergeany option would allow a merge from a child to a parent with no warnings.

p4 submit

New --parallel option specifies that multiple files should be transferred in parallel, using independent network connections from automatically-invoked child processes. In order to run a parallel submit, the configurable net.parallel.max must be set to a value greater than 1.

p4 sync

The new -r option reopens files that are mapped to new locations in the depot, in the new location. By default, open workspace files remain associated with the depot files that they were originally opened as.

The command now automatically resolves files where the previously synced version does not differ from the newer depot version.

p4 unlock

The new -r option unlocks the files associated with the specified client that were locked due to a failed p4 push command.

New specification fields

p4 group

New fields include LdapConfig, LdapSearchQuery, and LdapUserAttribute. These are used with the p4 ldapsync command.

p4 server

New optional field ExternalAddress specifies the external address used for connections to a commit server. This field must be set for the edge server to enable parallel submits in a federated environment.

New configurables


Set on the server to support filenames longer than 260 characters on Windows platforms.


Specifies whether to automatically create users on login. The auth.default.method configurable now only determines whether the user is authenticated against an LDAP directory or against Perforce's internal database.


Specifies whether changes can be fetched in a distributed versioning environment.


Specifies whether changes can be pushed in a distributed versioning environment.


Specifies whether submitted changes can be rewritten.

Deprecated configurables


Has been deprecated.