You have a subnet with a CIDR block of 10.0.1.0/24
Which of the following is not an IP address which would be assigned to an EC2 Instance launched in this subnet.
Click on the arrows to vote for the correct answer
A. B. C. D.Answer - C.
The AWS Documentation mentions the following.
The first four IP addresses and the last IP address in each subnet CIDR block are not available for you to use, and cannot be assigned to an instance.
For example, in a subnet with CIDR block 10.0.0.0/24, the following five IP addresses are reserved:
· 10.0.0.0: Network address.
· 10.0.0.1: Reserved by AWS for the VPC router.
· 10.0.0.2: Reserved by AWS.
The IP address of the DNS server is always the base of the VPC network range plus two; however, we also reserve the base of each subnet range plus two.
For VPCs with multiple CIDR blocks, the IP address of the DNS server is located in the primary CIDR.
For more information, see Amazon DNS Server.
· 10.0.0.3: Reserved by AWS for future use.
· 10.0.0.255: Network broadcast address.
We do not support broadcast in a VPC, therefore we reserve this address.
For more information on subnets and VPC's, please refer to below URL:
http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html#vpc-subnet-basicsThe CIDR block 10.0.1.0/24 contains 256 IP addresses, ranging from 10.0.1.0 to 10.0.1.255.
In this subnet, the first 3 IP addresses (10.0.1.0, 10.0.1.1, and 10.0.1.2) are reserved by AWS, and the last IP address (10.0.1.255) is the broadcast address and cannot be assigned to an EC2 instance.
Therefore, the valid IP addresses for an EC2 instance launched in this subnet are from 10.0.1.3 to 10.0.1.254.
Out of the given options, all but one IP address falls within this range.
Option B: 10.0.1.253 is a valid IP address within the subnet range and can be assigned to an EC2 instance.
Option D: 10.0.1.254 is the broadcast address and cannot be assigned to an EC2 instance.
Option A: 10.0.1.4 is a valid IP address within the subnet range and can be assigned to an EC2 instance.
Option C: 10.0.1.3 is a valid IP address within the subnet range and can be assigned to an EC2 instance.
Therefore, the correct answer is D (10.0.1.254).