

Terjemahan disediakan oleh mesin penerjemah. Jika konten terjemahan yang diberikan bertentangan dengan versi bahasa Inggris aslinya, utamakan versi bahasa Inggris.

# Contoh untuk topologi instans Amazon EC2
<a name="ec2-instance-topology-examples"></a>

Anda dapat menggunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah untuk mendeskripsikan topologi untuk instans EC2 Anda. Dan Anda dapat menggunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah untuk menggambarkan topologi Reservasi Kapasitas Anda.

Bila Anda menggunakan `describe-capacity-reservation-topology` perintah `describe-instance-topology` atau tanpa parameter atau filter, respons mencakup semua instance atau Reservasi Kapasitas Anda (tergantung pada perintah yang digunakan) yang cocok dengan jenis instans yang didukung untuk perintah ini di Wilayah yang ditentukan. Anda dapat menentukan Wilayah dengan menyertakan parameter `--region`, atau dengan menetapkan Wilayah default. Untuk informasi selengkapnya tentang mengatur Wilayah default, lihat [Pilih Wilayah untuk sumber daya Amazon EC2](using-regions-availability-zones-setup.md).

Anda dapat menyertakan parameter untuk mengembalikan instans atau Reservasi Kapasitas yang sesuai dengan contoh tertentu atau Reservasi Kapasitas IDs atau nama grup penempatan. Anda juga dapat menyertakan filter untuk mengembalikan instance atau Reservasi Kapasitas yang cocok dengan jenis instans atau keluarga instans tertentu, atau instance atau Reservasi Kapasitas di Zona Ketersediaan atau Zona Lokal yang ditentukan. Anda dapat menyertakan satu parameter atau filter, atau kombinasi parameter dan filter.

Outputnya diberi paginasi, dengan hingga 20 instance atau Reservasi Kapasitas per halaman secara default. Anda dapat menentukan hingga 100 instance atau Reservasi Kapasitas per halaman menggunakan parameter. `--max-results`

Untuk informasi selengkapnya, lihat [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html) dan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-reservation-topology-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-reservation-topology-topology.html).

**Izin yang diperlukan**

Izin berikut diperlukan:
+ `ec2:DescribeInstanceTopology`— Untuk menggambarkan topologi contoh
+  `ec2:DescribeCapacityReservationTopology`— Untuk menggambarkan topologi Reservasi Kapasitas

**Contents**
+ [Contoh 1: DescribeInstanceTopology - Instance IDs](#instance-topology-ex1)
+ [Contoh 2: DescribeInstanceTopology - Parameter nama grup penempatan](#instance-topology-ex2)
+ [Contoh 3: DescribeInstanceTopology - Filter tipe instance](#instance-topology-ex3)
  + [Contoh 3a - Filter pencocokan yang tepat untuk jenis instance tertentu](#instance-topology-ex3a)
  + [Contoh 3b — Filter kartu liar untuk keluarga instance](#instance-topology-ex3b)
  + [Contoh 3c - Keluarga instance gabungan dan filter pencocokan tepat](#instance-topology-ex3c)
+ [Contoh 4: DescribeInstanceTopology - Filter ID zona](#instance-topology-ex4)
  + [Contoh 4a - Filter Availability Zone](#instance-topology-ex4a)
  + [Contoh 4b - Filter Zona Lokal](#instance-topology-ex4b)
  + [Contoh 4c - Zona Ketersediaan Gabungan dan filter Zona Lokal](#instance-topology-ex4c)
+ [Contoh 5: DescribeInstanceTopology - Jenis instans dan filter ID zona](#instance-topology-ex5)
+ [Contoh 6: DescribeCapacityReservationTopology - Reservasi Kapasitas IDs](#instance-topology-ex6)
+ [Contoh 7: DescribeCapacityReservationTopology - Filter tipe instance](#instance-topology-ex7)

## Contoh 1: DescribeInstanceTopology - Instance IDs
<a name="instance-topology-ex1"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi contoh tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `--instance-ids` parameter. Outputnya hanya mencakup instance yang cocok dengan instance IDs yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-west-2 \
    --instance-ids i-1111111111example i-2222222222example
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-1111111111example",
            "InstanceType": "p4d.24xlarge",
            "GroupName": "ML-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        },
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "GroupName": "HPC-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3214313214example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi contoh tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -InstanceId i-1111111111example, i-2222222222example
```

------

## Contoh 2: DescribeInstanceTopology - Parameter nama grup penempatan
<a name="instance-topology-ex2"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi contoh dalam kelompok penempatan tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `group-names` parameter. Output hanya mencakup instance yang ada di salah satu grup penempatan yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-west-2 \
    --group-names ML-group HPC-group
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-1111111111example",
            "InstanceType": "p4d.24xlarge",
            "GroupName": "ML-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        },
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "GroupName": "HPC-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3214313214example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi contoh dalam kelompok penempatan tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -GroupName ML-group, HPC-group
```

------

## Contoh 3: DescribeInstanceTopology - Filter tipe instance
<a name="instance-topology-ex3"></a>

Anda dapat memfilter berdasarkan tipe instans tertentu (sama persis) atau memfilter menurut keluarga instans (menggunakan wildcard). Anda juga dapat menggabungkan filter tipe instans tertentu dan filter keluarga instans.

### Contoh 3a - Filter pencocokan yang tepat untuk jenis instance tertentu
<a name="instance-topology-ex3a"></a>

------
#### [ AWS CLI ]

**Untuk mendeskripsikan topologi instance dengan tipe instance tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `instance-type` filter. Outputnya hanya mencakup instance dengan tipe instance yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-west-2 \
    --filters Name=instance-type,Values=trn1n.32xlarge
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk mendeskripsikan topologi instance dengan tipe instance tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="instance-type"; Values="trn1n.32xlarge"}
```

------

### Contoh 3b — Filter kartu liar untuk keluarga instance
<a name="instance-topology-ex3b"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi instance dengan keluarga instance tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `instance-type` filter. Output hanya mencakup instance dengan keluarga instance tertentu.

```
aws ec2 describe-instance-topology \
    --region us-west-2 \
    --filters Name=instance-type,Values=trn1*
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        },
        {
            "InstanceId": "i-3333333333example",
            "InstanceType": "trn1.32xlarge",
            "NetworkNodes": [
                "nn-1212121212example",
                "nn-1211122211example",
                "nn-1311133311example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az4",
            "AvailabilityZone": "us-west-2d"            
        },
        {
            "InstanceId": "i-444444444example",
            "InstanceType": "trn1.2xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-5434334334example",
                "nn-1235301234example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"          
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi instance dengan keluarga instance tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="instance-type"; Values="trn1*"}
```

------

### Contoh 3c - Keluarga instance gabungan dan filter pencocokan tepat
<a name="instance-topology-ex3c"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi instance dengan keluarga instance atau tipe instance**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `instance-type` filter. Output hanya mencakup contoh yang memenuhi kriteria yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-west-2 \
    --filters "Name=instance-type,Values=p4d*,trn1n.32xlarge"
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-1111111111example",
            "InstanceType": "p4d.24xlarge",
            "GroupName": "ML-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        },
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-4343434343example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "usw2-az2",
            "AvailabilityZone": "us-west-2a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi instance dengan keluarga instance atau tipe instance**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="instance-type"; Values="p4d*", "trn1n.32xlarge"}
```

------

## Contoh 4: DescribeInstanceTopology - Filter ID zona
<a name="instance-topology-ex4"></a>

Anda dapat menggunakan filter `zone-id` untuk memfilter berdasarkan Zona Ketersediaan atau Local Zones. Anda juga dapat menggabungkan filter Zona Ketersediaan dan filter Local Zones.

### Contoh 4a - Filter Availability Zone
<a name="instance-topology-ex4a"></a>

------
#### [ AWS CLI ]

**Untuk menjelaskan topologi instance di Availability Zone tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `zone-id` filter. Output hanya mencakup instance di Availability Zone yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-east-1 \
    --filters Name=zone-id,Values=use1-az1
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3214313214example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "use1-az1",
            "AvailabilityZone": "us-east-1a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menjelaskan topologi instance di Availability Zone tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="zone-id"; Values="use1-az1"}
```

------

### Contoh 4b - Filter Zona Lokal
<a name="instance-topology-ex4b"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi contoh di Zona Lokal tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `zone-id` filter. Output hanya mencakup instance di Zona Lokal yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-east-1 \
    --filters Name=zone-id,Values=use1-atl2-az1
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-1111111111example",
            "InstanceType": "p4d.24xlarge",
            "GroupName": "ML-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "use1-atl2-az1",
            "AvailabilityZone": "us-east-1-atl-2a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi contoh di Zona Lokal tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="zone-id"; Values="use1-atl2-az1"}
```

------

### Contoh 4c - Zona Ketersediaan Gabungan dan filter Zona Lokal
<a name="instance-topology-ex4c"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi contoh di zona tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `zone-id` filter. Output hanya mencakup contoh yang berada di salah satu zona yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-east-1 \
    --filters Name=zone-id,Values=use1-az1,use1-atl2-az1
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-1111111111example",
            "InstanceType": "p4d.24xlarge",
            "GroupName": "ML-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "use1-atl2-az1",
            "AvailabilityZone": "us-east-1-atl-2a"
        },
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3214313214example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "use1-az1",
            "AvailabilityZone": "us-east-1a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi contoh di zona tertentu**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="zone-id"; Values="use1-az1", "use1-atl2-az1"}
```

------

## Contoh 5: DescribeInstanceTopology - Jenis instans dan filter ID zona
<a name="instance-topology-ex5"></a>

Anda dapat menggabungkan filter dalam satu perintah.

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi instance dengan tipe instance tertentu, keluarga instance, dan zona**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-topology.html)perintah dengan `zone-id` filter `instance-type` dan. Respons berisi instance apa pun dengan salah satu jenis instance yang ditentukan dan berada di salah satu zona yang ditentukan.

```
aws ec2 describe-instance-topology \
    --region us-east-1 \
    --filters "Name=instance-type,Values=p4d*,trn1n.32xlarge" \
              "Name=zone-id,Values=use1-az1,use1-atl2-az1"
```

Berikut ini adalah output contoh.

```
{
    "Instances": [
        {
            "InstanceId": "i-1111111111example",
            "InstanceType": "p4d.24xlarge",
            "GroupName": "ML-group",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3333333333example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "use1-atl2-az1",
            "AvailabilityZone": "us-east-1-atl-2a"
        },
        {
            "InstanceId": "i-2222222222example",
            "InstanceType": "trn1n.32xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example",
                "nn-3214313214example"
            ],
            "CapacityBlockId": "null",
            "ZoneId": "use1-az1",
            "AvailabilityZone": "us-east-1a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi instance dengan tipe instance tertentu, keluarga instance, dan zona**  
Gunakan [Get-EC2InstanceTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2InstanceTopology.html)cmdlet.

```
Get-EC2InstanceTopology `
    -Filter @{Name="instance-type"; Values="p4d*", "trn1n.32xlarge"} `
            @{Name="zone-id"; Values="use1-az1", "use1-atl2-az1"}
```

------

## Contoh 6: DescribeCapacityReservationTopology - Reservasi Kapasitas IDs
<a name="instance-topology-ex6"></a>

------
#### [ AWS CLI ]

**Untuk menggambarkan topologi Reservasi Kapasitas tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-capacity-reservation-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-capacity-reservation-topology.html)perintah dengan `capacity-reservation-id` parameter. Output hanya mencakup Reservasi Kapasitas yang sesuai dengan Reservasi Kapasitas yang ditentukan. IDs

```
aws ec2 describe-capacity-reservation-topology \
    --region us-east-1 \
    --capacity-reservation-id cr-1111111111example cr-2222222222example
```

Berikut ini adalah output contoh.

```
{
    "CapacityReservations": [
        {
            "CapacityReservationId": "cr-1111111111example",
            "CapacityBlockId": "null",
            "State": "active",
            "InstanceType": "p5.48xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example"
            ],
            "AvailabilityZone": "us-east-1a"
        },
        {
            "CapacityReservationId": "cr-2222222222example",
            "CapacityBlockId": "null",
            "State": "active",
            "InstanceType": "p5en.48xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example"
            ],
            "AvailabilityZone": "us-east-1a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk menggambarkan topologi Reservasi Kapasitas tertentu**  
Gunakan [Get-EC2CapacityReservationTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2CapacityReservationTopology.html)cmdlet.

```
Get-EC2CapacityReservationTopology `
    -CapacityReservationId cr-1111111111example cr-2222222222example
```

------

## Contoh 7: DescribeCapacityReservationTopology - Filter tipe instance
<a name="instance-topology-ex7"></a>

Anda dapat memfilter berdasarkan tipe instans tertentu (sama persis) atau memfilter menurut keluarga instans (menggunakan wildcard). Anda juga dapat menggabungkan filter tipe instans tertentu dan filter keluarga instans.

------
#### [ AWS CLI ]

**Untuk mendeskripsikan topologi Reservasi Kapasitas dengan jenis instans tertentu**  
Gunakan [https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-capacity-reservation-topology.html](https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-capacity-reservation-topology.html)perintah dengan `instance-type` filter. Respons berisi instance apa pun dengan tipe instance yang ditentukan.

```
aws ec2 describe-capacity-reservation-topology \
    --region us-east-1 \
    --filters Name=instance-type,Values=p5en.48xlarge
```

Berikut ini adalah output contoh.

```
{
    "CapacityReservations": [
        {
            "CapacityReservationId": "cr-2222222222example",
            "CapacityBlockId": "null",
            "State": "active",
            "InstanceType": "p5en.48xlarge",
            "NetworkNodes": [
                "nn-1111111111example",
                "nn-2222222222example"
            ],
            "AvailabilityZone": "us-east-1a"
        }
    ],
    "NextToken": "SomeEncryptedToken"
}
```

------
#### [ PowerShell ]

**Untuk mendeskripsikan topologi Reservasi Kapasitas dengan jenis instans tertentu**  
Gunakan [Get-EC2CapacityReservationTopology](https://docs.aws.amazon.com/powershell/latest/reference/items/Get-EC2CapacityReservationTopology.html)cmdlet.

```
Get-EC2CapacityReservationTopology `
    -Filter @{Name="instance-type"; Values="p5en.48xlarge"}
```

------