1 Respuesta
- Más nuevo
- Más votos
- Más comentarios
1
Hi - Please try specifying the subnet id while creating the instance.
EC2 Run-instances cli - https://docs.aws.amazon.com/cli/latest/reference/ec2/run-instances.html
Launches the specified number of instances using an AMI for which you have permissions.
You can specify a number of options, or leave the default options. The following rules apply:
EC2-VPC = If you don't specify a subnet ID, we choose a default subnet from your default VPC for you. If you don't have a default VPC, you must specify a subnet ID in the request.
So try this instead:
aws ec2 run-instances --image-id ami-<id> --count 1 --instance-type c5.2xlarge --key-name dev_nitro.pem --region us-east-1 --enclave-options 'Enabled=true' --subnet-id <subnet-id>
Contenido relevante
- OFICIAL DE AWSActualizada hace 3 años
- OFICIAL DE AWSActualizada hace 2 años
It throws this error after I assigned a subnet-it An error occurred (InvalidSubnetID.NotFound) when calling the RunInstances operation: The subnet ID 'vpc-<created-vpc-id>' does not exist