Skip to content

Latest commit

 

History

History
77 lines (61 loc) · 4.26 KB

File metadata and controls

77 lines (61 loc) · 4.26 KB
title pg hardstorage backup graph
description CLI reference for the pg hardstorage backup graph command.
tags
cli
reference

pg_hardstorage backup graph

Backup-chain topology + per-node dedup analysis

Synopsis

Walks every visible manifest for the deployment, links them by parent_backup_id into a chain forest, and (by default) computes per-node chunk-overlap metrics: how many chunks this backup contributes vs how many it shares with ancestors in the chain.

Output formats: --format json (default) — JSON body; the v1 contract. --format markdown — forensics-grade GFM with per-chain section, ASCII tree, per-node detail table, issues. --format dot — Graphviz DOT digraph. Pipe through dot -Tsvg or dot -Tpng to render. --format tree — pure ASCII tree (suitable for terminal output and pipe-to-grep workflows).

Flags: --include-tombstoned include soft-deleted manifests in the graph (marked with "tombstoned"). Default: live view only. --no-analysis skip the chunk-overlap pass. Useful on very large chains where memory is tight. Per-node Metrics will be nil.

Read-only; safe at any cadence.

pg_hardstorage backup graph <deployment> [flags]

Options

      --format string        output format: json | markdown | dot | tree (default "json")
  -h, --help                 help for graph
      --include-tombstoned   include soft-deleted manifests in the graph
      --no-analysis          skip the chunk-overlap analysis pass (faster, less memory)
      --repo string          repository URL (required)

Options inherited from parent commands

      --airgapped airgapped: strict                                                       refuse outbound endpoints (LLM providers, sinks, OTLP collectors) outside loopback / RFC1918 / explicit airgap.allowlist. Also enabled by PG_HARDSTORAGE_AIRGAPPED=1 or airgapped: strict in the config file.
  -c, --config string                                                                     path to config file (default: XDG/FHS lookup)
      --cpu-profile go tool pprof <path>                                                  write a pprof CPU profile to this path for the duration of the command (go tool pprof <path> to analyse). Off when empty.
      --mem-profile string                                                                write a pprof heap profile to this path at command exit. Off when empty.
      --no-color                                                                          disable ANSI color in text output
      --on-error-llm                                                                      on a structured-error failure, drop into the matching LLM helper skill (auto_on_error trigger). Also enabled by PG_HARDSTORAGE_ON_ERROR_LLM=1.
      --otel-endpoint string                                                              OpenTelemetry OTLP/HTTP endpoint (e.g. http://otel-collector:4318); empty disables tracing
      --otel-stdout                                                                       also export OpenTelemetry traces to stderr (useful for dev)
  -o, --output string                                                                     output format: text|json|ndjson|yaml|template|csv|markdown|html|tap|junit|pdf (default: text on TTY, json off-TTY)
      --profile-port go tool pprof http://127.0.0.1:6060/debug/pprof/profile?seconds=30   if non-zero, expose net/http/pprof on 127.0.0.1:<port> for live profiling of long-running commands (e.g. go tool pprof http://127.0.0.1:6060/debug/pprof/profile?seconds=30). Off when zero.
  -q, --quiet                                                                             suppress non-essential output
      --template string                                                                   Go text/template applied when --output template (or implied if --template is set without --output)

SEE ALSO