Installing P4

This chapter tells you how to install the Helix Command-Line Client (p4) on your workstation. For details about installing the Helix Versioning Engine, refer to the Helix Versioning Engine Administrator Guide: Fundamentals.

Installing P4 on UNIX and OS X

To install the Helix Command-Line Application (p4) on a UNIX or Mac OS X machine, perform the following steps:

  1. Download the p4 executable file from the Perforce web site:

    http://www.perforce.com/downloads/complete_list

    Helix applications are typically installed into /usr/local/bin.

  2. Make the p4 file executable (chmod +x p4).
  3. Configure the port setting, client workspace name, and user name.

    You can specify these settings by configuring the P4PORT, P4CLIENT, and P4USER environment variables. (For details, see “Configuring P4”.)

Installing P4 on Windows

To install the Helix Command Line (p4.exe) on Windows, download and run the Helix Windows installer (perforce.exe) from the Downloads page of the Perforce web site:

http://www.perforce.com/downloads/complete_list

The Helix installer enables you to install and uninstall the Helix Command Line and other Helix Windows components.

Verifying the installation

To verify that you have successfully installed the Helix Command Line, type p4 info at the command line and press Enter. If the Helix service is running on the specified host and port, the following message is displayed:

User name: ona
Client name: ona-agave
Client host: agave
Client root: /home/ona/p4-ona
Current directory: /home/ona/p4-ona
Client address: 10.0.0.196
Server address: perforce:1666
Server root: /usr/depot/p4d
Server date: 2012/03/28 12:11:47 -0700 PDT
Server uptime: 752:41:33
Server version: P4D/FREEBSD/2012.1/406375 (2012/01/25)
Server license: P4Admin <p4adm> 20 users (expires 2013/01/01)
Server license-ip: 10.0.0.2
Case handling: sensitive

If your configuration settings are incorrect, an error message is displayed:

Perforce client error:
        Connect to server failed; check $P4PORT.
        TCP connect to <hostname> failed.
        <hostname>: host unknown.

If your administrator has configured Perforce to require SSL, the first time you attempt to connect to the Perforce service, you will need to verify the server’s fingerprint. See SSL-encrypted connections.