How can software determine the public and private IP addresses of the Amazon EC2 instance that it is running on?

How can software determine the public and private IP addresses of the Amazon EC2
instance that it is running on?

How can software determine the public and private IP addresses of the Amazon EC2
instance that it is running on?

A.
Query the appropriate Amazon CloudWatch metric.

B.
Use ipconfig or ifconfig command.

C.
Query the local instance userdata.

D.
Query the local instance metadata.



Leave a Reply 9

Your email address will not be published. Required fields are marked *


networkmanagers

networkmanagers

I agree with the answer. D

Hitesh

Hitesh

A is the answer

Duck Bro

Duck Bro

D
Metadata Value
instance-id i-1234567890abcdef0
ami-launch-index 0
public-hostname ec2-203-0-113-25.compute-1.amazonaws.com
public-ipv4 67.202.51.223
local-hostname ip-10-251-50-12.ec2.internal
local-ipv4 10.251.50.35