CmdID

CmdID / aws / aws ec2

aws ec2 modify-id-format

Modifies the ID format for the specified resource on a per-Region basis. AWS CLI reference

2 examples 2 options Its page in the AWS CLI reference

Opens CmdID with your command. It is read in your browser and sent nowhere.

Examples

from aws-cli, each command read by CmdID

Example 1: To enable the longer ID format for a resource

The following modify-id-format example enables the longer ID format for the instance resource type.

aws ec2 modify-id-format --resource instance --use-long-idsIdentify
--resourceThe type of resource: bundle | conversion-task | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task | flow-log | image | import-task | internet-gateway | network-acl | network-acl-association | network-interface | network-interface-attachment | prefix-list | route-table | route-table-association | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway.
--use-long-idsIndicate whether the resource should use longer IDs (17-character IDs).

This command produces no output.

For more information, see Manage your Amazon EC2 resources in the Amazon EC2 User Guide.

Example 2: To disable the longer ID format for a resource

The following modify-id-format example disables the longer ID format for the instance resource type.

aws ec2 modify-id-format --resource instance --no-use-long-idsIdentify
--resourceThe type of resource: bundle | conversion-task | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task | flow-log | image | import-task | internet-gateway | network-acl | network-acl-association | network-interface | network-interface-attachment | prefix-list | route-table | route-table-association | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway.
--no-use-long-idsIndicate whether the resource should use longer IDs (17-character IDs).

This command produces no output.

The following modify-id-format example enables the longer ID format for all supported resource types that are within their opt-in period.

aws ec2 modify-id-format --resource all-current --use-long-idsIdentify
--resourceThe type of resource: bundle | conversion-task | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task | flow-log | image | import-task | internet-gateway | network-acl | network-acl-association | network-interface | network-interface-attachment | prefix-list | route-table | route-table-association | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway.
--use-long-idsIndicate whether the resource should use longer IDs (17-character IDs).

This command produces no output.

For more information, see Manage your Amazon EC2 resources in the Amazon EC2 User Guide.

Options

2 in the AWS CLI reference
--resourceThe type of resource: bundle | conversion-task | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task | flow-log | image | import-task | internet-gateway | network-acl | network-acl-association | network-interface | network-interface-attachment | prefix-list | route-table | route-table-association | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway.
--use-long-idsIndicate whether the resource should use longer IDs (17-character IDs).