Skip to content

Command Reference

Matteo Concas edited this page Jul 30, 2026 · 1 revision

Command reference

Every command, argument and flag osm accepts, generated from the source.

An unrecognised first word is not an error: it is sent to the OpenSearch REST API as a path, with cluster, cat and nodes expanded to _cluster, _cat and _nodes.

osm _cluster/health
osm cat indices
osm -t prod cat shards

Listing commands accept --json. Export commands write ndjson to stdout, a JSON array under --json, or one file per object under --to-file [DIR]. Import commands take several files and expand wildcards themselves, so quoted patterns work.

Global options

These come before the command, and apply to raw REST paths too.

Argument Description
-t, --target NAME target from ~/.os-manager/config.json (default: the first)
-w, --workspace ID scope saved objects to this Dashboards workspace, overriding the target's own
--global scope saved objects globally, ignoring the target's workspace
-v, --version show program's version number and exit

Commands

osm target

show configured targets

osm target list

list configured targets

osm target list

osm workspace

Dashboards workspaces

osm workspace list

list workspaces and their ids

osm workspace list [--json]
Argument Description
--json machine-readable output

osm saved-object

manage saved objects

osm saved-object list

list saved objects

osm saved-object list

osm saved-object export

export saved objects as ndjson

osm saved-object export [--to-file [DIR]] [--json] [--type {dashboard,visualization,search}] [ids ...]
Argument Description
[ids ...] saved object ids; omit for all
--to-file [DIR] write one file per object into DIR (default .)
--json machine-readable output
--type {dashboard|visualization|search} export only this type

osm saved-object import

import saved objects from ndjson

osm saved-object import FILE [FILE ...]
Argument Description
FILE [FILE ...] ndjson files; wildcards are expanded

osm dashboard

manage dashboards

osm dashboard list

list dashboards

osm dashboard list

osm dashboard export

export dashboards as ndjson

osm dashboard export [--to-file [DIR]] [--json] [ids ...]
Argument Description
[ids ...] dashboard ids; omit for all
--to-file [DIR] write one file per object into DIR (default .)
--json machine-readable output

osm dashboard import

import dashboards from ndjson

osm dashboard import FILE [FILE ...]
Argument Description
FILE [FILE ...] ndjson files; wildcards are expanded

osm dashboard delete

delete a dashboard

osm dashboard delete id
Argument Description
id id of the dashboard to delete

osm dashboard validate

check dashboards for broken references and fields

osm dashboard validate [--json] [ids ...]
Argument Description
[ids ...] dashboard ids; omit for all
--json machine-readable output

osm visualization

manage visualizations

osm visualization list

list visualizations

osm visualization list

osm visualization export

export visualizations as ndjson

osm visualization export [--to-file [DIR]] [--json] [ids ...]
Argument Description
[ids ...] visualization ids; omit for all
--to-file [DIR] write one file per object into DIR (default .)
--json machine-readable output

osm visualization import

import visualizations from ndjson

osm visualization import FILE [FILE ...]
Argument Description
FILE [FILE ...] ndjson files; wildcards are expanded

osm visualization delete

delete a visualization

osm visualization delete id
Argument Description
id id of the visualization to delete

osm search

manage saved searches

osm search list

list saved searches

osm search list

osm search export

export saved searches as ndjson

osm search export [--to-file [DIR]] [--json] [ids ...]
Argument Description
[ids ...] saved search ids; omit for all
--to-file [DIR] write one file per object into DIR (default .)
--json machine-readable output

osm search import

import saved searches from ndjson

osm search import FILE [FILE ...]
Argument Description
FILE [FILE ...] ndjson files; wildcards are expanded

osm search delete

delete a saved search

osm search delete id
Argument Description
id id of the saved search to delete

osm detector

anomaly detection detectors

osm detector list

list detectors

osm detector list

osm detector export

export detectors as ndjson

osm detector export [--to-file [DIR]] [--json] [ids ...]
Argument Description
[ids ...] detector ids; omit for all
--to-file [DIR] write one file per object into DIR (default .)
--json machine-readable output

osm ism

index state management

osm ism list

policy and state per index

osm ism list [--all]
Argument Description
--all include unmanaged indices

osm ism status

how each policy is executing

osm ism status [--failed] [--json] [index]
Argument Description
[index] index name or wildcard
--failed only failed or retrying steps; exits 1 if any
--json machine-readable output

osm ism settings

effective plugins.index_state_management.* settings

osm ism settings [--json]
Argument Description
--json machine-readable output

osm ism schedule

per-index tick interval baked in at enrolment

osm ism schedule [--json] [index]
Argument Description
[index] index name or wildcard
--json machine-readable output

osm ism change-policy

enrol indices on the current version of a policy

osm ism change-policy [--state STATE] pattern policy-id
Argument Description
pattern index name or wildcard
policy-id policy to enrol the indices on
--state STATE state to start in

osm ism retry

retry a failed ISM step

osm ism retry [--state STATE] pattern
Argument Description
pattern index name or wildcard
--state STATE state to retry from

osm ism rollover

roll over a data stream or write alias

osm ism rollover name
Argument Description
name data stream or write alias to roll over

osm ism policy

inspect and edit policies

osm ism policy show

print the full policy

osm ism policy show name
Argument Description
name policy to print

osm ism policy create

create a policy that manages indices without acting

The policy has one state with no actions and no transitions, so enrolled indices are managed but never modified or deleted.

osm ism policy create [--description DESCRIPTION] [--state STATE] [--pattern PATTERN] [--priority PRIORITY] name
Argument Description
name name of the policy to create
--description DESCRIPTION human-readable policy description
--state STATE name of the single state (default: keep)
--pattern PATTERN index pattern the policy claims; repeatable
--priority PRIORITY ism_template priority (default: 100)

osm ism policy version

per-index policy version against the current one

osm ism policy version [--include-orphans] [--json] [index]
Argument Description
[index] index name or wildcard
--include-orphans also list indices with no policy at all
--json machine-readable output

osm ism policy set-rollover

edit a state's rollover conditions

Conditions merge into the existing ones; pass none to drop one.

osm ism policy set-rollover [--age AGE] [--size SIZE] [--docs N] [--primary-shard-size SIZE] [--state STATE] name
Argument Description
name policy to edit
--age AGE roll over at this index age, e.g. 1d, or none
--size SIZE roll over at this total size, e.g. 50gb, or none
--docs N roll over at this document count, or none
--primary-shard-size SIZE roll over at this primary shard size, or none
--state STATE state to edit (default: hot)

osm ism policy set-transition

upsert a transition between two states

At least one condition is required; pass none to drop one. Dropping every condition removes the transition.

osm ism policy set-transition [--min-size SIZE] [--min-rollover-age AGE] [--min-index-age AGE] [--min-doc-count N] [--position {first,last}] name from-state to-state
Argument Description
name policy to edit
from-state state the transition leaves
to-state state the transition enters
--min-size SIZE transition at this total size, e.g. 50gb, or none
--min-rollover-age AGE transition this long after rollover, e.g. 7d, or none
--min-index-age AGE transition at this index age, e.g. 90d, or none
--min-doc-count N transition at this document count, or none
--position {first|last} where to insert a new transition (default: first)

osm ism policy edit-ism-template

edit which indices the policy claims

osm ism policy edit-ism-template [--replace-pattern OLD NEW] [--add-pattern PATTERN] [--remove-pattern PATTERN] [--entry-index ENTRY_INDEX] [--priority PRIORITY] name
Argument Description
name policy to edit
--replace-pattern OLD NEW swap one claimed pattern for another; repeatable
--add-pattern PATTERN pattern to start claiming; repeatable
--remove-pattern PATTERN pattern to stop claiming; repeatable
--entry-index ENTRY_INDEX which ism_template entry to add to (default: 0)
--priority PRIORITY ism_template priority; higher wins over other policies

osm index

indices

osm index delete

delete an index

osm index delete name
Argument Description
name index to delete

osm index field-caps

field types across a pattern, as Dashboards sees them

osm index field-caps [--non-keyword] [--conflicts] [--unknown] [--json] pattern
Argument Description
pattern index name or wildcard
--non-keyword hide string fields
--conflicts only fields mapped as more than one type
--unknown only fields Dashboards renders as '?'
--json machine-readable output

osm index-pattern

index patterns

osm index-pattern list

list index patterns

osm index-pattern list [--json]
Argument Description
--json machine-readable output

osm index-pattern delete

delete an index pattern

osm index-pattern delete id
Argument Description
id id of the index pattern to delete

osm index-pattern refresh

rebuild the cached field list from the live mapping

osm index-pattern refresh [--dry-run] [--json] id
Argument Description
id id of the index pattern to refresh
--dry-run report the diff without writing
--json machine-readable output

osm jobs

what the cluster is busy with

osm jobs list

running cluster tasks

osm jobs list [--all] [--filter ACTION] [--json]
Argument Description
--all include monitoring and internal tasks
--filter ACTION only tasks whose action contains this text
--json machine-readable output

osm jobs pending

queued master-level tasks

osm jobs pending [--json]
Argument Description
--json machine-readable output

osm jobs policy

ISM work in flight

osm jobs policy [--json]
Argument Description
--json machine-readable output

osm index-template

index templates

osm index-template list

list templates and their policy

osm index-template list [--json] [pattern]
Argument Description
[pattern] name or wildcard
--json machine-readable output

osm index-template set-policy

bake an ISM policy_id into the template

osm index-template set-policy name policy-id
Argument Description
name index template to edit
policy-id policy to apply, or 'none' to remove

osm component-template

component templates

osm component-template list

list templates and their policy

osm component-template list [--json] [pattern]
Argument Description
[pattern] name or wildcard
--json machine-readable output

osm component-template set-policy

bake an ISM policy_id into the template

osm component-template set-policy name policy-id
Argument Description
name component template to edit
policy-id policy to apply, or 'none' to remove

osm data-stream

data streams

osm data-stream list

list data streams with their write index

osm data-stream list [--json] [pattern]
Argument Description
[pattern] name or wildcard
--json machine-readable output

Clone this wiki locally