Skip to content

crimson/os/seastore: add xattr metrics like the classic chgattr_lat - #73924

Merged
shraddhaag merged 2 commits into
ceph:mainfrom
shraddhaag:wip-shraddhaag-seastore-xattr-metrics
Nov 19, 2026
Merged

shraddhaag merged 2 commits into
ceph:mainfrom
shraddhaag:wip-shraddhaag-seastore-xattr-metrics

Conversation

@shraddhaag

@shraddhaag shraddhaag commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

The PR adds metrics for xattr metrics. The following metrics dashboard changes were also added:

Screenshot 2026-11-18 at 11 00 11 PM

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands

You must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.

@shraddhaag
shraddhaag force-pushed the wip-shraddhaag-seastore-xattr-metrics branch from 2a17262 to 007ceba Compare November 17, 2026 05:41
@shraddhaag
shraddhaag marked this pull request as ready for review November 17, 2026 06:29
@shraddhaag
shraddhaag requested review from a team as code owners November 17, 2026 06:29
@shraddhaag shraddhaag moved this to Awaits review in Crimson Nov 17, 2026

@knrt10 knrt10 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @shraddhaag , looks good, apart from make check failure, everything LGTM.

@shraddhaag

Copy link
Copy Markdown
Contributor Author

apart from make check failure

This was due to a bug on main. The fix, #73945, was just merged.

@shraddhaag

Copy link
Copy Markdown
Contributor Author

jenkins test make check

SeaStore reports getattr/getattrs latency (op_lat GET_ATTR, GET_ATTRS),
like the classic getattr_lat, but it has nothing for xattr changes and
no data on the xattr omap tree. Add, per shard_store_index:

- xattr_set_ops, xattr_rm_ops: setattr/setattrs and rmattr/rmattrs
  transaction ops.
- xattr_change_count, xattr_change_usec: count and total time of those
  ops in the transaction build, like the classic chgattr_lat (avgcount
  and sum). A steady clock is used: one change takes microseconds, below
  the lowres_clock resolution of the op_lat histograms.
- attr_inline / attr_overflow with attr="ss": SnapSet in the onode
  inline slot or in the xattr tree, next to the existing attr="oi".
- xattr_tree_set_records, xattr_tree_set_bytes: entries and key + value
  bytes written to the xattr omap tree.
- xattr_tree_kv_size: histogram of key + value size of each entry
  written to the xattr tree, 64 B to 64 KiB. The leaf limit is 16,382 B.
  The buckets are cumulative, as Prometheus expects, so
  histogram_quantile() works on it.

The op counters count each build of the transaction, so a conflict
replay counts again.

Signed-off-by: Shraddha Agrawal <[email protected]>
Add three panels for the new SeaStore xattr metrics to the SeaStore row
of the crimson OSD dashboard:

- xattr ops / s: xattr_set_ops and xattr_rm_ops, the load for the next
  panel.
- Avg xattr change time: xattr_change_usec / xattr_change_count, like
  the classic BlueStore chgattr_lat.
- xattr tree entry size (over time range): the share of entries in each
  size band (0-64 B, 64-128 B, ... 16-64 KiB). It shows the sizes the
  xattr leaf must hold, and entries near the 16,382 B leaf limit.

The xattr_tree_kv_size buckets are cumulative, so each band is the
difference of two buckets, divided by xattr_tree_kv_size_count. The bar
gauge uses one query per band, so that each bar has a range label; the
"heatmap" format would label the bars with le. increase() extrapolates
each bucket on its own, so a band is clamped at 0. The bucket query
matches le both as "64" and as "64.000000". bars() now draws in one
colour: a green-to-red gradient made a large share look like an error.

ts() gets a min option. The change time panel uses min=0: without it,
Grafana can draw a flat line outside the y axis range.

Signed-off-by: Shraddha Agrawal <[email protected]>
@shraddhaag
shraddhaag force-pushed the wip-shraddhaag-seastore-xattr-metrics branch from 007ceba to 78e514e Compare November 18, 2026 20:18
@github-project-automation github-project-automation Bot moved this from New to Reviewer approved in Ceph-Dashboard Nov 18, 2026
@shraddhaag

Copy link
Copy Markdown
Contributor Author

jenkins test windows

1 similar comment
@shraddhaag

Copy link
Copy Markdown
Contributor Author

jenkins test windows

@shraddhaag
shraddhaag merged commit 8fd56ef into ceph:main Nov 19, 2026
13 of 14 checks passed
@github-project-automation github-project-automation Bot moved this from Reviewer approved to Done in Ceph-Dashboard Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project
Status: Awaits review

Development

Successfully merging this pull request may close these issues.

3 participants