allocation

dpsctl validate allocation Usage Guide

Validate policy allocation for devices without applying changes.

Usage

dpsctl validate allocation --devices <device[,device...]> --policy <policy> [--strict-policy]

You can also use the validate alias:

dpsctl val allocation --devices <device[,device...]> --policy <policy> [--strict-policy]

Flags

Includes global dpsctl options.

   --devices value [ --devices value ]  (required) device names, comma-separated
   --policy value                       (required) policy name to validate
   --strict-policy                      if requested power policy is not possible, fail instead of switching to a lower policy
   --help, -h                           show help

Behavior

The dpsctl validate allocation command performs a dry-run power allocation analysis for the requested devices and policy. It reports whether the allocation would succeed and any constraints returned by DPS.

No allocation state is persisted. Use this command to test a policy assignment before applying it through a command that changes resource group, policy, or topology state.

Required Inputs

  1. --devices must include at least one device name. Multiple devices can be provided as a comma-separated list.
  2. --policy must specify the policy name to validate against the devices.

Name Validation

The policy name and each device name are validated before the request is sent. Invalid names fail fast and return a validation error for the corresponding flag.

Strict Policy

By default, validation can report the result of allocation analysis that may include fallback behavior when the requested policy cannot be satisfied. Use --strict-policy when the requested policy must be possible exactly. If the strict allocation is not possible, the command still prints a validation response, but allocation_would_succeed is false with a diagnostic message.

Examples

Validate allocation for one device

$ dpsctl validate allocation --devices node-a --policy policy-a
{
  "status": {
    "ok": true,
    "diag_msg": "would activate successfully"
  },
  "allocation_would_succeed": true
}

Validate allocation for multiple devices

$ dpsctl validate allocation --devices node-a,node-b --policy policy-a
{
  "status": {
    "ok": true,
    "diag_msg": "would activate successfully"
  },
  "allocation_would_succeed": true
}

Validate allocation with strict policy matching

$ dpsctl validate allocation --devices node-a,node-b --policy policy-a --strict-policy
{
  "status": {
    "ok": true,
    "diag_msg": "would activate successfully"
  },
  "allocation_would_succeed": true
}

Use the validate alias

$ dpsctl val allocation --devices node-a,node-b --policy policy-a --strict-policy
{
  "status": {
    "ok": true,
    "diag_msg": "would activate successfully"
  },
  "allocation_would_succeed": true
}

Notes

  • This command is a dry run and does not persist allocation, policy, resource group, or topology changes
  • --devices and --policy are required
  • Device names are sent in the order provided
  • Device and policy names must pass DPS name validation
  • Use --strict-policy when policy fallback should make allocation_would_succeed false
  • Output includes allocation_would_succeed and can include policy-selection, power-reclamation, and per-device status details
  • Output follows the selected global output format, such as json or yaml