Helix Core is now P4. Product user interfaces will be updated soon. Learn more >>

P4 CLI Documentation | 2026.1

# Start up P4 CLI and verify the connection to the server

1. Start up the command-line client:

   $ p4

2. To verify a connection, run the `p4 info` command. If `P4PORT` is set correctly, information like the following is displayed:

   Copy

       User name: bruno
       Client name: bruno_ws
       Client host: computer_12
       Client root: c:\bruno_ws
       Current directory: c:\bruno_ws
       Peer address: 10.0.102.24:61122
       Client address: 10.0.0.196
       Server address: ssl:example.com:1818
       Server root: /usr/depot/p4d
       Server date: 2020/09/28 15:03:05 -0700 PDT
       Server uptime: 752:41:33
       Server version: P4D/FREEBSD/2012.1/406375 (2020/08/25)
       ServerID: London-commit1
       Server license: P4Admin &lt;p4adm&gt; 20 users (expires 2021/01/01)
       Server license-ip: 10.0.0.2
       Case handling: sensitive

   The `Server address` field shows the host to which `p4` connected and also displays the host and port number on which the P4 Server is listening. If `P4PORT` is set incorrectly, you receive a message like the following:

   Perforce client error:
   Connect to server failed; check $P4PORT.
   TCP connect to perforce:1666 failed.
   perforce: host unknown.

3. If the host:port value is `perforce:1666`, `P4PORT` has not been set. Set `P4PORT` and try to connect again.
4. If your installation requires SSL/TLS, make sure your `P4PORT` is of the form `ssl:`hostname`:`port``.
5. The first time you attempt to connect to the server, you are asked to verify the server’s fingerprint. If the fingerprint is accurate, use the `p4 trust` command to install the fingerprint into a file (pointed to by the `P4TRUST` environment variable) that holds a list of known/trusted P4 Server and their respective fingerprints. If `P4TRUST` is unset, this file is `.p4trust` in the user’s home directory. For more information, see SSL/TLS-encrypted connections.
6. If your installation requires plain text (in order to support older P4 Server applications), set `P4PORT` to `tcp:`hostname`:`port``.

Your search for returned results