sentry-logger-deploy

Bulk deploys a set of loggers defined in a logger provisioning profile to a sentry.

Syntax

sentry-logger-deploy

Description

Logpresso supports a logger provisioning profile function that automatically sets up loggers on a sentry upon connecting to the sentry. This enables collecting logs of instances that are dynamically generated from the cloud. However, if you want logger provisioning to run automatically upon connection, you first need to set the environment variable logpresso.sentry.logger_provisioning_profile when starting the sentry. The sentry-logger-deploy command automatically deploys a set of loggers defined by a provisioning profile to the specified Logpresso sentry, even if you do not specify a logger provisioning profile when the Logpresso sentry boots up.

This command only forwards the provisioning start request and does not wait. The logger configuration may still be waiting or processing even after the command ends. If a failure occurs during logger provisioning, it will not be notified other than the system log.

Tip
You can check the number of queued logger provisioning tasks using the logpresso.loggerProvisioningTasks command in the logpresso shell.
Input Field

This query requires that the input record contains guid and profile_guid field values.

FieldTypeDescription
guidStringUnique sentry identifier (Not relevant to GUID in JAVA)
profile_guidStringLogger provisioning profile identifier (32-character long GUID)
Output Fields

If any error occurs, this query command returns an _error field in addition to the fields from input record. Possible errors are as follows:

Error MessageDescription
guid is nullguid field value from input record is null.
guid should be stringguid field value from input record is not a string.
guid should be non empty stringguid field value from input record is empty.
profile_guid is nullprofile_guid field value from input record is null.
profile_guid should be stringprofile_guid field value from input record is not a string.
profile_guid should be non empty stringprofile_guid field value from input record is empty.
not connectedSentry is not connected.
profile not found: profile_guidLogger provisioning profile does not exist.

Usage

  1. Provision window loggers on the window sentries.

    sentry
    | search os == "Windows*"
    | eval profile_guid="448c0422-7a30-42ef-b73a-e855e538f779"
    | sentry-logger-deploy