Show / Hide Table of Contents

Enum LocalStorageType

Types of local storage available for EC2 instances.

Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public enum LocalStorageType
Syntax (vb)
Public Enum LocalStorageType
Remarks

Specifies the physical medium used for local (instance store) storage.

ExampleMetadata: infused

Examples
Role infrastructureRole;
             InstanceProfile instanceProfile;
             Vpc vpc;


             var miCapacityProvider = new ManagedInstancesCapacityProvider(this, "MICapacityProvider", new ManagedInstancesCapacityProviderProps {
                 InfrastructureRole = infrastructureRole,
                 Ec2InstanceProfile = instanceProfile,
                 Subnets = vpc.PrivateSubnets,
                 InstanceRequirements = new InstanceRequirementsConfig {
                     // Required: CPU and memory constraints
                     VCpuCountMin = 2,
                     VCpuCountMax = 8,
                     MemoryMin = Size.Gibibytes(4),
                     MemoryMax = Size.Gibibytes(32),

                     // CPU preferences
                     CpuManufacturers = new [] { CpuManufacturer.INTEL, CpuManufacturer.AMD },
                     InstanceGenerations = new [] { InstanceGeneration.CURRENT },

                     // Instance type filtering
                     AllowedInstanceTypes = new [] { "m5.*", "c5.*" },

                     // Performance characteristics
                     BurstablePerformance = BurstablePerformance.EXCLUDED,
                     BareMetal = BareMetal.EXCLUDED,

                     // Accelerator requirements (for ML/AI workloads)
                     AcceleratorTypes = new [] { AcceleratorType.GPU },
                     AcceleratorManufacturers = new [] { AcceleratorManufacturer.NVIDIA },
                     AcceleratorNames = new [] { AcceleratorName.T4, AcceleratorName.V100 },
                     AcceleratorCountMin = 1,

                     // Storage requirements
                     LocalStorage = LocalStorage.REQUIRED,
                     LocalStorageTypes = new [] { LocalStorageType.SSD },
                     TotalLocalStorageGBMin = 100,

                     // Network requirements
                     NetworkInterfaceCountMin = 2,
                     NetworkBandwidthGbpsMin = 10,

                     // Cost optimization
                     OnDemandMaxPricePercentageOverLowestPrice = 10
                 }
             });

Synopsis

Fields

HDD

Hard disk drive storage.

SSD

Solid state drive storage.

Fields

Name Description
HDD

Hard disk drive storage.

SSD

Solid state drive storage.

Back to top Generated by DocFX