Set STP Configuration
The Set STP Configuration operation updates the configuration for an STP-only Coordinated Timing Network. This operation is supported using the BCPii interface.
HTTP method and URI
POST /api/cpcs/{cpc-id}/operations/set-stp-config
In this request, the URI variable {cpc-id} is the object ID of the target CPC object.
Request body contents
The request body is expected to contain a JSON object with the following fields:
Field name | Type | Rqd/Opt | Description |
---|---|---|---|
stp-id | String (1-8) | Required | The current STP identifier for the CTN, used to verify that the CPC is a member of the correct CTN. Can contain 0-9, a-z, A-Z, underline (_) and dash (-). |
new-stp-id | String (1-8) | Optional | If provided, the new STP identifier for the CTN, Can contain 0-9, a-z, A-Z, underline (_) and dash (-). |
force | Boolean | Required | Whether a disruptive operation is allowed (true) or rejected (false) |
preferred-time-server | stp-node object | Required | Identifies the CPC object to be the Preferred Time Server. Refer to Table 6 for details. |
backup-time-server | stp-node object | Optional | Identifies the CPC object to be the Backup Time Server. If not provided, the STP has no Backup Time Server. Refer to Table 6 for details. |
arbiter | stp-node object | Optional | Identifies the CPC object to be the Arbiter for the CTN. If not provided, the STP has no Arbiter. Refer to Table 6 for details. |
current-time-server | String Enum | Required | Identifies the role of the Current Time Server (CTS). One of:
|
Description
The CPC object designated by {cpc-id} must be the system that becomes the Current Time Server (CTS).
On success, HTTP status code 204 (No Content) is returned.
Authorization requirements
- For the web services interface:
- Object-access permission to the CPC object designated by {cpc-id}
- Action/task permission to the Manage System Time and Modify Assigned Server Roles tasks.
- For the BCPii interface the source partition must have receive BCPii security controls permissions for the CPC object.
HTTP status and reason codes
On success, HTTP status code 204 (No Content) is returned and no response body is provided.
The following HTTP status codes are returned for the indicated errors, and the response body is a standard error response body providing the reason code indicated and associated error message.
HTTP error status code | Reason code | Description |
---|---|---|
400 (Bad Request) | Various | Errors were detected during common request validation. See Common request validation reason codes for a list of the possible reason codes. |
282 | The operation was rejected, due to an incomplete preferred, backup or arbiter nested object specification. Refer to Table 6 for details. | |
284 | This operation does not target the Current Time Server CPC. | |
285 | The operation was rejected, due to one of the
following configuration errors:
|
|
286 | The operation was rejected for one of the following
reasons:
|
|
403 (Forbidden) | 0 | The request used the BCPii interface and the source partition does not have receive BCPii security controls permission for the CPC object. |
1 | The API user does not have the required permission for this operation. | |
404 (Not Found) | 1 | The object ID in the URI ({cpc-id}) does not designate an existing CPC object, or the API user does not have object-access permission to the object. |
2 | An object URI in one of the stp-node objects in the request body does not designate an existing CPC object, or the API user does not have object-access permission to the object. | |
409 (Conflict) | 1 | The requested operation cannot be performed,
due to the state of the object:
|
287 | The provided configuration can only be set by specifying force=true. | |
288 | No communication path between preferred-time-server and backup-time-server. | |
289 | No communication path to the arbiter. | |
329 | The operation cannot be performed because the CPC designated by the request URI is an unmanaged CPC, which is not supported by this operation. | |
500 (Server Error) | 272 | An unexpected error occurred during the operation. |
503 (Service Unavailable) | 1 | The request could not be processed because the HMC is not communicating with the SE needed to perform the requested operation. |
Additional standard status and reason codes can be returned, as described in Invoking API operations.