Skip to main content
Rack groups, templates and layouts are in beta and available through Nonce MCP only. Their operations do not appear in the API Reference.

Overview

A farm describes its physical layout with three objects: Nonce places each miner in a slot from its IP address. The farm must give its miners fixed IP addresses; when a miner’s IP changes, its slot changes with it.

Rack groups

A rack group has its own id. Its subnets are an attribute: one or more IPv4 subnets from /16 to /24 that hold the miners of the rack group. Every /24 subnet that has miners but no rack group gets a new unnamed rack group the next time rack groups are read. Rack groups therefore cover every IPv4 miner of the farm, and setup starts by naming and configuring the rack groups Nonce already created. To list the miners of a rack group, search miners with ip_ranges set to its subnets.

Changing subnets

When a container spans more than one /24 subnet, replace the subnets of one rack group with the full range.
New subnets absorb every other rack group whose subnets all fall within them. The absorbed rack groups are deleted together with their names and templates. A subnet that only partly overlaps another rack group is rejected. Review the affected rack groups before you change subnets.

Templates

A template sets the number of racks in a rack group, the rows and columns of each rack, and how miners take slots.

Slot modes

For a rack group with a single /24 subnet, start_offset is the last octet of the first miner’s IP. For example, with start_offset set to 11, the miner at x.x.x.11 takes slot 1.

System and farm templates

Use ListRackGroupTemplates to see the templates available to a farm. Changing a farm template changes every rack group that uses it. Deleting a farm template leaves those rack groups without a template.

Layouts

A layout places rack groups in the farm. It is saved as a whole.
  • Rows run from the front of the farm to the back.
  • Positions run along each row. A position is empty or stacks one or two rack groups, listed from the floor up.
  • Aisles: each row can be followed by a cold or hot aisle, or none.
  • A rack group takes at most one position.
rows is null until someone arranges the farm. A saved layout may still refer to rack groups that were deleted since, for example after a subnet change absorbed them; skip those when you read it.

Concurrent edits

Pass the updated_at you read with GetFarmLayout as expected_updated_at when you save with UpdateFarmLayout, or null if no layout was saved. If someone else saved the layout in between, the save is rejected with 409. Read the layout again, reapply your change, and save.

Legacy racks

Rack groups replace the earlier rack model. There is no operation that writes a slot for an individual miner. Slots follow from IP addresses, the rack group template, and start_offset.

Permissions

Both are checked against the target farm. These writes change farm configuration only; they do not send commands to miners.

Operations