Skip to content

feat(storcli2): logical volume create and delete#69

Open
g-carre wants to merge 1 commit into
improvement/storcli2-cache-jbod-setterfrom
feature/storcli2-lv-manager-create-delete
Open

feat(storcli2): logical volume create and delete#69
g-carre wants to merge 1 commit into
improvement/storcli2-cache-jbod-setterfrom
feature/storcli2-lv-manager-create-delete

Conversation

@g-carre

@g-carre g-carre commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Summary

Implements the create/delete part of ports.LogicalVolumesManager on the storcli2/perccli2 logical-volume manager (ARTESCA-17647).

  • CreateLV — fills the request drives through the physical-drive getter, validates the RAID creation, formats a single-enclosure drives=e:s,... list (rejecting multi-enclosure requests), issues add vd with the bare RAID-level and cache tokens, and rediscovers the new volume by its physical-drive set.
  • DeleteLV — issues /cx/vx delete and surfaces the in-JSON failure payload.
  • The manager now also takes a PhysicalDrivesGetter; command verbs follow the storcli2 command map documented in DESIGN.md.

Testing

go build, go vet, gofmt, and the package test suite pass. New tests cover the create happy path, command-failure, multi-enclosure rejection, and a table-driven delete (success / invalid VD / nonexistent VD).

Note: This PR targets improvement/storcli2-cache-jbod-setter (its base), not main.

Issue: ARTESCA-17647

🤖 Generated with Claude Code

Implement the create/delete part of ports.LogicalVolumesManager on the
storcli2/perccli2 logical-volume manager:

- CreateLV fills the request drives through the physical-drive getter,
  validates the RAID creation, formats a single-enclosure "drives=e:s,..."
  list (rejecting multi-enclosure requests), issues "add vd" with the bare
  RAID-level and cache tokens, and rediscovers the new volume by its
  physical-drive set.
- DeleteLV issues "/cx/vx delete" and surfaces the in-JSON failure payload.

The manager now also takes a PhysicalDrivesGetter; command verbs follow the
storcli2 command map documented in DESIGN.md.

Issue: ARTESCA-17647
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant