Skip to main content
A support bundle is a tar archive that a device assembles locally. It packages logs, the effective configuration, and runtime telemetry for analysis by Ditto Support. Bundles are generated entirely on the device and work offline. No connection to Ditto Server is required.
Support bundles are available in Ditto SDK 5.2 and later on native platforms. The system_request_support_bundle() function isn’t available in the JavaScript Web SDK.

Requesting a bundle

Request a bundle with the system_request_support_bundle() DQL function. Run it with EXECUTE FUNCTION. The call completes when the bundle has been generated and stored, or fails with an error.
DQL
You can attach your own metadata to the bundle, for example to record why it was requested. Ditto stores the metadata on the bundle’s attachment, and it’s visible when you list bundles:
DQL
The function returns one document that identifies the new bundle:
Ditto generates one bundle at a time. If a bundle is already being generated, Ditto rejects the new request instead of queuing it.

Requesting from your app

Run the statement with ditto.store.execute(), the same way you run any other DQL statement. Because it’s a query, you can trigger it from wherever your app already runs Ditto queries, such as an admin screen, a remote command from your backend, or a debug socket. To download the archive, pass the file token to fetchAttachment(). See Fetching attachments for the full fetch lifecycle in each SDK.
On Android, the support bundle screen in DittoAndroidTools lets you request, view, and export bundles without writing queries.

Listing retained bundles

Ditto stores generated bundles on the device and lists them in the system:support_bundles virtual collection. To list bundles from newest to oldest, run:
DQL
Each document has the same _id, reason, and file fields that system_request_support_bundle() returns. See system:support_bundles for the schema.

Bundle contents

The archive is a plain tar with a flat layout:
Bundles captured in the first 60 seconds of process lifetime don’t contain dial9 traces. Trace segments rotate every 60 seconds, and only completed segments are captured. dial9 recording is on by default at level Lite. Change it with the DITTO_DIAL9_OBSERVABILITY_LEVEL environment variable.
The log export includes a mapping of full peer public keys, so that peer logs can be cross-referenced, and absolute on-device file paths. Config secrets are redacted from config_snapshot.json. Review bundle contents before sharing them broadly.

Rate limiting, timeout, and retention

Three system parameters control bundle generation. Change them at run time with ALTER SYSTEM. Changes apply to the next request without a restart and reset to the defaults when the process restarts. In SDK 5.2 and later you can also set them in the system parameters of DittoConfig. For example, to allow more requests during a support session:
DQL
There is no total byte-size cap on retained bundles. Retention is count-based. Bundle size is driven mainly by retained log volume and the dial9 buffer size (dial9_buffer_size_mb, default 16 MB).

Requesting a bundle from the Portal

You can also request a support bundle from a managed device through the Ditto Portal. See Troubleshooting. The Portal-driven archive uses the same base entries and adds request_history.json and system_indexes.json, plus a flamegraph when remote_flamegraph_request_enabled is on. Portal-triggered bundles upload to Ditto Server automatically. Locally requested bundles stay on the device until you fetch and share them.