All Products
Search
Document Center

Elastic Compute Service:Create a security group

Last Updated:May 13, 2024

A security group acts as a virtual firewall that controls inbound and outbound traffic for Elastic Compute Service (ECS) instances. Each ECS instance must be added to at least one security group. This topic describes how to create a custom security group in the ECS console.

Considerations

  • A virtual private cloud (VPC) is created. To create a security group of the VPC type, this requirement must be met. For more information, see Create and manage a VPC.

  • If you do not create a security group when you create an ECS instance, a default security group is automatically created. If you want to add an ECS instance to a custom security group, perform the following steps to create the security group.

  • ECS imposes limits on the maximum number of security groups that can be created in a single region. To view the limit, go to the Quota Center console. You can apply to increase the limit based on your business requirements. For more information, see Manage quotas.

For more information about security groups, see Overview.

Procedure

  1. Go to the security group list page.

    1. Log on to the ECS console.

    2. In the left-side navigation pane, choose Network & Security > Security Groups.

    3. In the upper-left corner of the top navigation bar, select a region.

  2. Click Create Security Group.

  3. In the Basic Information section, configure the basic information of the security group.

    1. Configure the security group parameters for easy identification of the security group that you want to create. The parameters include the security group name, description, resource group, and tags.

    2. Specify a network. You can select the classic network or a VPC. For more information, see Network types.

    3. Specify the type of security group. You can select the basic or advanced security group type. For more information, see Basic security groups and advanced security groups.

  4. In the Access Rule section, configure security group rules.

    By default, basic security group rules are configured in the security group. To add custom security group rules, perform the following steps. For more information, see Add a security group rule.

    1. Click the Inbound or Outbound tab based on the direction of the security group rules that you want to add.

    2. Click Add Rule.

    3. Configure custom security group rules. For more information about security group rules, see Security group rules.

  5. Click Create Security Group.

    After you create the security group, you can view the security group on the security group list page. For more information, see Search for security groups.

References