如何确定我在 AWS 上的子网?

How to determine which subnet I am in on AWS?

starting an EC2 from an image in AWS Marketplace时,它请求子网设置:

并说:

Ensure you are in the selected VPC above

它给出了 2 个选项:

我不知道这是什么意思。

它是否要求我确定我的笔记本电脑当前所在的 AWS“子网”(在本例中为 ap-southeast-2bap-southeast-2a),并通过此下拉菜单告诉 AWS?我不明白为什么它会想要这些信息,也不明白要给它什么。我已经使用了数千个 EC2,从来不需要指定比 region 更细粒度的任何内容。但今天我从市场图像启动 EC2,它需要这些附加信息。

无论何时启动实例,您都必须选择 VPC and a subnet. When you launch your instance, usually a default VPC with default subnets 是 pre-selected。

默认的 VPC 和子网通常是 public,这使得您的实例可以从 Internet 访问。通常,出于安全原因,可能不需要这样做。在那种情况下 custom VPC and/or subnets are created. This allows you to create private subnets shielded from direct access from the internet. One such architecture is VPC with public and private subnets (NAT).

上述设置中的 NAT 允许私有子网中的实例访问互联网,但不允许从互联网直接访问实例。