oxidecomputer / oxidecomputer/omicron

Nexus: Account for all storage on U.2s

Open
#6,110 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

nexus storage
Dominant language
Rust
Stars
572
Forks
97
Avg merge
2d 12h
Merged PRs (30d)
96

Description

In the context of the "Support Bundles" project, it is currently difficult for Nexus to answer the question "will a particular U.2 have enough space to store a support bundle of a particular size?".

More generally, Nexus may ask "If I provision a resource to a U.2, and I want it to have some minimum / maximum space, will it fit?

We need the following tools to answer this question:

  1. Nexus wants https://github.com/oxidecomputer/omicron/issues/6042 to request datasets explicitly, rather than implicitly. This should apply to all datasets (see: https://github.com/oxidecomputer/omicron/issues/6043)
  2. Nexus needs https://github.com/oxidecomputer/omicron/issues/6107 , to know that provisioned datasets won't overflow their expected capacities.
  3. Nexus would like to ensure that all storage usage within U.2s is tracked, to some degree. This depends on e.g. https://github.com/oxidecomputer/omicron/issues/6108, https://github.com/oxidecomputer/omicron/issues/6109
  4. Nexus needs to keep track of the expected quotas/reservations given to each U.2, and compare the usages of "all datasets on a zpool, so far" when making adjustments to the allocations.

It would also be extremely nice to have commands through omdb that can display these numbers, and give context on what they mean.

As prior art, the "region allocation" query for crucible accounts for some of this information: https://github.com/oxidecomputer/omicron/blob/main/nexus/db-queries/src/db/queries/region_allocation.rs

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with nexus/db-queries/src/db/queries/region_allocation.rs, especially its zpool usage and capacity queries, then review linked issues 6042, 6043, 6107, 6108, and 6109. Determine how Nexus should track all dataset usage and per-U.2 quotas, and what omdb commands should expose; done requires an agreed design and implementation covering those requirements.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend, databases
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.