-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Blueprints: extract discretionary zone placement into its own module (#…
…5788) Previously, we chose a sled for new Nexus instances by taking the sled with the lowest number of current Nexus zones and tiebreaking by sled-id (arbitrary but deterministic). This PR moves the placement decisions into a new submodule and adds some additional requirements: 1. We need to know the number of zpools present on each sled. 2. We refuse to start a service if there are already more instances of that service than there are zpools on the sled. (This isn't required today for Nexus, but will be important for services with non-transient datasets, like CRDB, and will eventually be required for all zones once we track transient dataset assignment in blueprints.) 3. If there are multiple sleds are tied on "lowest count of current instances of this zone type", we tiebreak by "lowest total number of discretionary zones", and only if we're still tied do we tiebreak on sled-id. This module only supports Nexus at the moment, but adding additional zone kinds (assuming all the same requirements are valid for them) is nearly trivial - I'll add cockroachdb support in a subsequent PR.
- Loading branch information
1 parent
279cb8c
commit 82c77f2
Showing
3 changed files
with
564 additions
and
60 deletions.
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
nexus/reconfigurator/planning/proptest-regressions/planner/omicron_zone_placement.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Seeds for failure cases proptest has generated in the past. It is | ||
# automatically read and these particular cases re-run before any | ||
# novel cases are generated. | ||
# | ||
# It is recommended to check this file in to source control so that | ||
# everyone who runs the test benefits from these saved cases. | ||
cc 72b902d1405681df2dd46efc097da6840ff1234dc9d0d7c0ecf07bed0b0e7d8d # shrinks to input = _TestPlaceOmicronZonesArgs { input: ArbitraryTestInput { existing_sleds: {[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]: ExistingSled { zones: ZonesToPlace { zones: [] }, waiting_for_ntp: false, num_disks: 1 }}, zones_to_place: ZonesToPlace { zones: [Nexus] } } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.