Skip to content

Add smallsize=1 to pick the smallest disk, the counterpart of largesize=1 - #175

Merged
mastacontrola merged 1 commit into
masterfrom
feat/fogproject-817-smallsize
Sep 2, 2026
Merged

Add smallsize=1 to pick the smallest disk, the counterpart of largesize=1#175
mastacontrola merged 1 commit into
masterfrom
feat/fogproject-817-smallsize

Conversation

@mastacontrola

Copy link
Copy Markdown
Member

For FOGProject/fogproject#817: with several disks at different bus positions per machine, how do you always deploy to the smallest one?

getHardDisk() already honors a largesize=1 kernel argument that picks the largest disk by capacity when no Host Primary Disk is set. This adds smallsize=1, which sorts the same list the other way. Ties keep enumeration order, as before. Both go in Host Kernel Arguments, or on a group.

  • tests/checks/primary-disk-dedup.sh gains the three automatic choices (none, largest, smallest) on a stub machine whose first disk is neither the largest nor the smallest, so each case lands on a different device. The smallest case fails on the old code.
  • Full suite: 20 passed.

Docs for both arguments to follow in fog-docs, since neither is documented today.

🤖 Generated with Claude Code

https://claude.ai/code/session_0131h4axUaE3VJZphvKRdDby

…ze=1

getHardDisk() already honors a largesize=1 kernel argument that picks
the largest disk by capacity when no Host Primary Disk is set. A fleet
whose target disk is always the smallest one, but sits at a different
bus position on every machine, had no equivalent (fogproject #817).
smallsize=1 sorts the same list the other way. Ties keep enumeration
order, as before.

tests/checks/primary-disk-dedup.sh gains the three automatic choices on a
stub machine whose first disk is neither the largest nor the smallest.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0131h4axUaE3VJZphvKRdDby
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