mongocli ops-manager diagnose-archive download
The diagnose-archive download
command downloads a diagnostic
archive for the specified Ops Manager project to a .tar.gz
file.
You can also download diagnostic archives through the Ops Manager
API.
Syntax
mongocli ops-manager|om diagnose-archive download|get [ --limit <max-number-of-entries> ] [ --minutes <number-of-minutes-ago> ] [ --out <file-destination> ] [ --output|-o <output-format> ] [ --profile|-P <profile-name> ] [ --projectId <id-of-project> ]
Options
Option | Type | Description | Required? |
---|---|---|---|
--limit | integer | Maximum number of entries for the diagnostic archive. | no |
--minutes | integer | Time range of the diagnostic archive, beginning at the specified number of minutes in the past and ending at the present time. ExampleTo retrieve a diagnostic archive with data for the last 10
minutes, specify | no |
--out , -o | string | Output filename or path to filename. If omitted, the diagnostic
archive is downloaded to your current directory as
diagnose-archive.tar.gz . | no |
--output , -o | string | Command output format. Valid values are:
If omitted, the command returns output in the default format. | no |
--profile , -P | string | Name of the profile where the public and private
keys for the project are saved. If omitted, uses the default profile. To learn more about creating a
profile, see Configure the MongoDB CLI. | no |
--projectId | string | Unique identifier of the project. If omitted, uses the project ID in the profile or environment variable. NoteYou can retrieve the list of projects, including their IDs, using
the | no |
Output
The command downloads the diagnostic archive of the specified Ops Manager
project to:
The current directory as a file named
diagnose-archive.tar.gz
, orA directory and filename you specify with the
--out
option.
If the command returns an error, see Troubleshooting for recommended solutions.
Examples
The following example uses the
mongocli ops-manager diagnose-archive download
command to download
the diagnostic archive for an Ops Manager project. The command uses the
default profile, which stores the project ID and the Programmatic API Keys.
mongocli ops-manager diagnose-archive download
The previous command downloads the log file diagnose-archive.tar.gz
to the current directory.