Verify Artifactory Accessibility
Verify Artifactory is accessible by running a ping command with JFrog CLI.
Use this command to verify that Artifactory is accessible by sending an application-level ping. A successful run prints OK in the terminal.
To verify Artifactory is accessible:
-
Ensure the prerequisites are met for your scenario (URL-only ping, or a configured server ID).
-
Run a ping. When you pass a URL explicitly, use this form:
jf rt ping --url=<ArtifactoryURL>Where:
<ArtifactoryURL>— Full Artifactory base URL (for examplehttps://<your-subdomain>.jfrog.io/artifactory).
Example:
jf rt ping --url=https://your-instance.jfrog.io/artifactory -
Confirm the CLI prints
OK. If you use a configured default server instead of--url, runjf rt pingwith no arguments (or use the abbreviationjf rt p).
When to Use This Command
- Verify connectivity when configuring Artifactory for the first time
- Diagnose connection issues before running other JFrog CLI commands
- Test authentication credentials without performing actual operations
- Confirm Artifactory availability in CI/CD pipelines or monitoring scripts
Prerequisites
- JFrog CLI installed — Download and install JFrog CLI if you haven't already.
- For URL-based examples (Examples 1–7) — You need a valid Artifactory URL. No prior CLI configuration is required.
- For server-ID and default-server examples (Examples 8–10) — You must have at least one server configured via
jf config add. Runjf config showto list your configured servers and their IDs.
Note
Start with Example 1, which requires only an Artifactory URL and no prior configuration. If you need to set up a server first, see Artifactory Authentication.
Command Parameters
| Parameter | Command / Description |
|---|---|
| Command name | rt ping |
| Abbreviation | rt p |
Command Options
| Option | Description |
|---|---|
--url | [Optional] JFrog Platform URL. (for example: https://your-instance.jfrog.io) |
--server-id | [Optional] Server ID configured using the jf config command. If not specified, the default configured Artifactory server is used. |
--user | [Optional] JFrog username. |
--password | [Optional] JFrog password. |
--access-token | [Optional] JFrog access token. |
--ssh-key-path | [Optional] SSH key file path. |
--ssh-passphrase | [Optional] SSH key passphrase. |
--client-cert-path | [Optional] Client certificate file in PEM format. |
--client-cert-key-path | [Optional] Private key file for the client certificate in PEM format. |
--format | [Optional] Output format: json or table. When omitted, prints plain OK (backward-compatible). See jf rt output format. |
--insecure-tls | [Default: false] Set to true to skip TLS certificates verification. |
Command Arguments
The command accepts no arguments.
Accessibility Parameter Examples
Example 1: Ping a Specific Server by URL
Pings the Artifactory server accessible at the specified URL. This is the most self-contained example — no prior CLI configuration required.
jf rt ping --url=https://your-instance.jfrog.io/artifactoryExpected output:
OKExample 2: Ping with Username and Password Authentication
Pings the Artifactory server using username and password credentials.
jf rt ping --url=https://your-instance.jfrog.io/artifactory --user=myuser --password=mypasswordExpected output:
OKExample 3: Ping with Access Token Authentication
Pings the Artifactory server using an access token.
jf rt ping --url=https://your-instance.jfrog.io/artifactory --access-token=your-access-tokenExpected output:
OKExample 4: Ping with SSH Key Authentication
Pings the Artifactory server using SSH key authentication.
jf rt ping --url=ssh://artifactory.mycompany.com:1339 --ssh-key-path=~/.ssh/id_rsaExpected output:
OKExample 5: Ping with SSH Key and Passphrase
Pings the Artifactory server using an encrypted SSH key.
jf rt ping --url=ssh://artifactory.mycompany.com:1339 --ssh-key-path=~/.ssh/id_rsa --ssh-passphrase=your-passphraseExpected output:
OKExample 6: Ping with mTLS Client Certificates
Pings the Artifactory server using mutual TLS authentication with client certificates.
jf rt ping --url=https://your-instance.jfrog.io/artifactory --client-cert-path=/path/to/client-cert.pem --client-cert-key-path=/path/to/client-key.pemExpected output:
OKExample 7: Skip Certificate Verification with Insecure TLS
Pings the Artifactory server while skipping TLS certificate verification.
Warning
Use
--insecure-tlsonly for testing or in trusted internal environments. It disables certificate validation entirely and should never be used in production.
jf rt ping --url=https://your-instance.jfrog.io/artifactory --insecure-tlsExpected output:
OKExample 8: Ping Default Server
Pings the configured default Artifactory server.
Note
A server must be configured via
jf config addbefore running this command. Runjf config showto confirm your default server is set.
jf rt pingExpected output:
OKExample 9: Ping a Specific Server by ID
Pings a configured Artifactory server by its server ID.
Note
Replace
my-server-idwith your actual server ID. Runjf config showto list all configured servers and their IDs.
jf rt ping --server-id=my-server-idExpected output:
OKExample 10: Ping Using the Abbreviation
Pings the default Artifactory server using the command abbreviation.
Note
A server must be configured via
jf config add. Runjf config showto confirm your default server is set.
jf rt pExpected output:
OKTroubleshooting
| Error | Likely Cause | Resolution |
|---|---|---|
server response: 401 | Invalid or expired credentials or access token | Re-run jf config add or jf config edit to update credentials for your server. |
Token failed verification: parse | The stored access token is malformed or expired | Re-run jf config add with a fresh token. |
Server ID 'X' does not exist | The server ID used with --server-id is not configured | Run jf config show to list valid server IDs. |
Connection refused or other network error | Wrong URL, or Artifactory is unreachable | Verify the Artifactory URL and confirm the service is running. |
certificate signed by unknown authority | Self-signed or internal TLS certificate | Use --insecure-tls in non-production environments, or install the CA certificate on your machine. |
Tip
When a command fails, the CLI prints a
Trace IDin the output, for example:[Info] Trace ID for JFrog Platform logs: 9933faa938e8b4fdIf you contact JFrog Support, include this Trace ID to help the support team locate the related server-side logs quickly.
Frequently Asked Questions
This section provides answers to frequently asked questions.
FAQs
Q: How do I verify that Artifactory is accessible from JFrog CLI?
A: Run jf rt ping --url=<ArtifactoryURL> for an ad hoc check, or run jf rt ping with no arguments to use your configured default server. See Example 1.
Q: What do I need before running jf rt ping?
A: For URL-only pings you only need a valid Artifactory URL. For server-ID or default-server pings you need at least one server configured with jf config add. See Prerequisites.
Q: What happens if jf rt ping returns a server response: 401 error?
A: A 401 response means your stored credentials or access token are invalid or expired. Re-run jf config add or jf config edit to update them. See Troubleshooting.
Q: What is the difference between using --url and --server-id with jf rt ping?
A: --url pings a server directly without needing a saved configuration. --server-id pings a server you already configured with jf config add, using its stored credentials.
Q: Can I skip TLS certificate verification when pinging Artifactory?
A: Yes, add --insecure-tls to the command. Use this only for testing or trusted internal environments, since it disables certificate validation entirely. See Example 7.
Related Topics
Updated 3 days ago
What’s Next
Connection verified. Now upload your first file to Artifactory.
