oxidecomputer / oxidecomputer/omicron

[sled-agent] Tracking issue for "test it in a VMM"

Open
#5,329 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

Once https://github.com/oxidecomputer/omicron/pull/5285 merges, we will have the ability to write tests for the illumos target which can execute within a VMM, and which can assume exclusive access to the underlying machine.

This will be a boon for tests which wish to, for example, modify storage, configs, etc.

This issue tracks tests which should be converted:

  • Pretty much all tests using the StorageManagerTestHarness, from https://github.com/oxidecomputer/omicron/pull/5172. This harness creates zpools from files in /var/tmp, but doesn't perform the best cleanup in certain test failures.
  • sled-agent/src/services.rs -- uses a lot of mocks, shouldn't
  • sled-agent/src/instance.rs -- relies on mocks, ideally wouldn't
  • sled-agent/src/dump_device.rs -- uses fakes, but could use "real disks" from the VMM

There are additional spots where test coverage would be beneficial, but for which tests don't currently exist, including:

  • sled-agent/src/swap_device.rs
  • sled-agent/src/backing_fs.rs
  • sled-agent/src/vmm_reservoir.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 by checking whether PR 5285 has merged, then review the VMM test capability it enables. Inspect the listed sled-agent files and StorageManagerTestHarness usage to identify tests that can use real VMM resources instead of mocks or fakes. Done means converting the applicable tests and adding coverage for swap_device.rs, backing_fs.rs, and vmm_reservoir.rs where appropriate.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
operating-systems, testing-qa
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.