CreateCluster - Amazon SageMaker

CreateCluster

Creates a SageMaker HyperPod cluster. SageMaker HyperPod is a capability of SageMaker for creating and managing persistent clusters for developing large machine learning models, such as large language models (LLMs) and diffusion models. To learn more, see Amazon SageMaker HyperPod in the Amazon SageMaker Developer Guide.

Request Syntax

{ "ClusterName": "string", "InstanceGroups": [ { "ExecutionRole": "string", "InstanceCount": number, "InstanceGroupName": "string", "InstanceStorageConfigs": [ { ... } ], "InstanceType": "string", "LifeCycleConfig": { "OnCreate": "string", "SourceS3Uri": "string" }, "OnStartDeepHealthChecks": [ "string" ], "OverrideVpcConfig": { "SecurityGroupIds": [ "string" ], "Subnets": [ "string" ] }, "ThreadsPerCore": number, "TrainingPlanArn": "string" } ], "NodeRecovery": "string", "Orchestrator": { "Eks": { "ClusterArn": "string" } }, "Tags": [ { "Key": "string", "Value": "string" } ], "VpcConfig": { "SecurityGroupIds": [ "string" ], "Subnets": [ "string" ] } }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

ClusterName

The name for the new SageMaker HyperPod cluster.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 63.

Pattern: ^[a-zA-Z0-9](-*[a-zA-Z0-9])*$

Required: Yes

InstanceGroups

The instance groups to be created in the SageMaker HyperPod cluster.

Type: Array of ClusterInstanceGroupSpecification objects

Array Members: Minimum number of 1 item. Maximum number of 100 items.

Required: Yes

NodeRecovery

The node recovery mode for the SageMaker HyperPod cluster. When set to Automatic, SageMaker HyperPod will automatically reboot or replace faulty nodes when issues are detected. When set to None, cluster administrators will need to manually manage any faulty cluster instances.

Type: String

Valid Values: Automatic | None

Required: No

Orchestrator

The type of orchestrator to use for the SageMaker HyperPod cluster. Currently, the only supported value is "eks", which is to use an Amazon Elastic Kubernetes Service (EKS) cluster as the orchestrator.

Type: ClusterOrchestrator object

Required: No

Tags

Custom tags for managing the SageMaker HyperPod cluster as an AWS resource. You can add tags to your cluster in the same way you add them in other AWS services that support tagging. To learn more about tagging AWS resources in general, see Tagging AWS Resources User Guide.

Type: Array of Tag objects

Array Members: Minimum number of 0 items. Maximum number of 50 items.

Required: No

VpcConfig

Specifies the Amazon Virtual Private Cloud (VPC) that is associated with the Amazon SageMaker HyperPod cluster. You can control access to and from your resources by configuring your VPC. For more information, see Give SageMaker access to resources in your Amazon VPC.

Note

When your Amazon VPC and subnets support IPv6, network communications differ based on the cluster orchestration platform:

  • Slurm-orchestrated clusters automatically configure nodes with dual IPv6 and IPv4 addresses, allowing immediate IPv6 network communications.

  • In Amazon EKS-orchestrated clusters, nodes receive dual-stack addressing, but pods can only use IPv6 when the Amazon EKS cluster is explicitly IPv6-enabled. For information about deploying an IPv6 Amazon EKS cluster, see Amazon EKS IPv6 Cluster Deployment.

Additional resources for IPv6 configuration:

Type: VpcConfig object

Required: No

Response Syntax

{ "ClusterArn": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

ClusterArn

The Amazon Resource Name (ARN) of the cluster.

Type: String

Length Constraints: Maximum length of 256.

Pattern: ^arn:aws[a-z\-]*:sagemaker:[a-z0-9\-]*:[0-9]{12}:cluster/[a-z0-9]{12}$

Errors

For information about the errors that are common to all actions, see Common Errors.

ResourceInUse

Resource being accessed is in use.

HTTP Status Code: 400

ResourceLimitExceeded

You have exceeded an SageMaker resource limit. For example, you might have too many training jobs created.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: