You can associate a security group when creating instances, or you can select security group to associate to the specified instance on the security group page after instance is created.
Each network interface of an instance must be associated to at least one security group.
Select a region.
In the instance list, select the instance to which you want to associate the security group and click on the name to enter the details page.
Click Security Group tab - Add.
Note: The instance side only supports security group associating for the instance primary network interface. To operate the instance secondary network interface, please operate from the security group side.
In addition, you can also associate from the security group console. For details, see Security Group Side Binding Instance.