LinuxCommandLibrary

gcloud-info

Display information about Google Cloud SDK installation

TLDR

Display gcloud environment information

$ gcloud info
copy

Check network connectivity and hidden properties
$ gcloud info --run-diagnostics
copy

Print the contents of the most recent log file
$ gcloud info --show-log
copy

SYNOPSIS

gcloud info [--format=FORMAT] [--log-http] [--project=PROJECT] [--quiet] [--trace-token=TRACE_TOKEN] [--user-output-enabled] [--verbosity=VERBOSITY]

PARAMETERS

--format=FORMAT
    Output format (e.g., json, yaml, table)

--log-http
    Log all HTTP interactions to stderr

--project=PROJECT
    Override default project

--quiet, -q
    Disable interactive prompts

--trace-token=TRACE_TOKEN
    Write trace metadata to file

--user-output-enabled
    Enable user-readable output

--verbosity=VERBOSITY
    Verbosity level: debug, info, warning, error, critical, none

DESCRIPTION

The gcloud info command provides comprehensive information about your Google Cloud CLI (gcloud SDK) installation. It outputs details such as the SDK version, active configuration path, currently logged-in account, host details, installation path, and a list of installed components like kubectl, bq, and gsutil.

This is useful for troubleshooting, verifying setups, or sharing diagnostic info with support. Running it without flags shows human-readable output divided into sections: Client Configuration, User Config Directory, Active Configuration, Account, Host, Install Path, and Installed Components.

For scripted use, apply --format=json or other formats to parse the structured data. It helps confirm if components are up-to-date or if configurations match expectations across environments.

CAVEATS

Requires gcloud SDK installed; output paths are user-specific. Use --format for automation to avoid parsing human-readable text.

TYPICAL OUTPUT SECTIONS

Client Config: SDK version
User Config: ~/.config/gcloud
Active Config: default
Account: user@domain.com
Installed Components: core, gsutil, bq, kubectl

HISTORY

Introduced with early Google Cloud SDK releases (~2013); evolved with gcloud CLI v1+ for unified IAM, compute, and other services management.

SEE ALSO

gcloud(1), gcloud version(1), gcloud components list(1)

Copied to clipboard