Updated on 2026-03-19 GMT+08:00

Binding Key Pairs in Batches

Binding key pairs in batches is supported when multiple ECSs need to be bound to the same key pair and the ECSs are in the Running state.
  • Scenario 1: If the ECSs to be bound to a key pair share the same password, you can use one-click binding, that is, select the key pair to be bound to and enter the root password of the ECSs.
  • Scenario 2: If the ECSs to be bound to a key pair use different root passwords, you need to use separate binding, that is, select the key pair to be bound to and enter the root password of each ECS.

Prerequisites

  • The ECS must be in the Running state.
  • The ECS has not been bound to a key pair.

Constraints

  • On the management console, key pairs cannot be bound to ECSs that run Windows.
  • Key pairs cannot be bound to public images running CoreOS, OpenEuler, FreeBSD (Other), Kylin V10 64-bit, or UnionTech OS Server 20 Euler 64-bit.
  • You can bind key pairs to a maximum of 10 ECSs at a time.

Procedure

  1. Log in to the management console.
  2. Click in the upper left corner of the management console and select a region or project.
  3. Click . Choose Security > Data Encryption Workshop.
  4. In the navigation pane on the left, click Key Pair Service.
  5. Click ECS List to view ECSs.
  6. Select the servers to be bound in batches and click Bind above the search box.

    • If the passwords of the ECSs to be bound are the same, you can select a key pair by one click and enter the password to bind the key pair.
    • If the passwords of the ECSs to be bound are different, you can bind them separately.

      If you select Unified bind, only the same key pair can be used for binding.

  7. The default port number is 22 and can be modified.

    Before using user-defined port, ensure that:

    • The key pair can be connected to the ECS using the port. For details about how to modify the security group configuration of an ECS, see "Configuring Security Group Rules".
    • Modify the default port of the ECS and ensure that the port is enabled. For details, see "How Can I Change a Remote Login Port?".
    • Modify the default port of the ECS and ensure that the port is enabled.

  8. You can choose whether to disable the password login mode as necessary. By default, the password login mode is disabled.

    • If you do not disable the password login mode, you can use the password or the key pair to log in to the ECS.
    • If the password login mode is disabled, you can use only the key pair to log in to the ECS. If you need to use the password login mode later, you can enable the password login mode again. For details, see the "How Do I Enable the Password Login Mode for an ECS?" in Data Encryption Workshop FAQ.

  1. Click OK. The key pairs are bound in batches. The binding takes about 3 to 5 minutes.