All Products
Search
Document Center

Bastionhost:Add hosts

Last Updated:Mar 31, 2026

Bastionhost manages O&M access to hosts from multiple sources — Alibaba Cloud Elastic Compute Service (ECS) instances, on-premises servers, and servers on other cloud platforms. Before you can connect to a host through Bastionhost, import it into your bastion host instance.

How it works

When you import a host, Bastionhost registers the host's address and network reachability information. All subsequent SSH or Remote Desktop Protocol (RDP) sessions go through the bastion host — the bastion host acts as the single entry point, enforcing access control. If the host is not directly reachable from the bastion host (for example, it sits in a different network segment), configure a network domain with a proxy so that the bastion host can forward traffic to it.

Choose an import method

MethodUse when
Import ECS instances — current accountYour hosts are ECS instances under the same Alibaba Cloud account
Import ECS instances — member accountsYour hosts are ECS instances under other accounts managed through Resource Directory
Create a host manuallyYour hosts are on-premises servers or servers on other cloud platforms, and you are adding a small number
Import hosts from a fileYour hosts are on-premises or from other clouds, and you are importing a large number at once
Import from a third-party asset sourceYour hosts are on Tencent Cloud, Huawei Cloud, Amazon Web Services (AWS), or another configured third-party source

Prerequisites

Before you begin, ensure that you have:

Import ECS instances from the current account

Import multiple ECS instances from your current Alibaba Cloud account in a single operation.

Importing an ECS instance does not affect the instance's running state.
  1. Log on to the Bastionhost console. In the top navigation bar, select the region where your bastion host resides.

  2. In the bastion host list, find the bastion host and click Manage.

  3. In the left-side navigation pane, choose Assets > Hosts.

  4. Choose Import ECS Instances > Import Instances of Current Account.

  5. In the Select Region dialog box, select the region of the ECS instances and click OK.

  6. In the Import ECS Instances dialog box, select the instances to import and click Import.

Import ECS instances from member accounts

If you manage multiple Alibaba Cloud accounts through Resource Directory, import ECS instances from member accounts for centralized O&M.

  1. Log on to the Bastionhost console. In the top navigation bar, select the region where your bastion host resides.

  2. In the bastion host list, find the bastion host and click Manage.

  3. In the left-side navigation pane, choose Assets > Hosts.

  4. Choose Import ECS Instances > Import Instances of Member Accounts.

  5. In the Select Alibaba Cloud Account step, select the account whose instances you want to import and click Next.

  6. In the Select Region step, select the region of the instances and click OK.

  7. In the Import ECS Instances dialog box, select the instances to import and click Import.

Add a host manually

Specify host details directly to register a single on-premises or third-party cloud server.

  1. Log on to the Bastionhost console. In the top navigation bar, select the region where your bastion host resides.

  2. In the bastion host list, find the bastion host and click Manage.

  3. In the left-side navigation pane, choose Assets > Hosts.

  4. Choose Import Other Hosts > Create Host.

  5. In the Create Host panel, fill in the parameters and click Create.

    ParameterDescription
    Operating SystemOS of the host. Linux and Windows are supported.
    Host IP AddressIPv4 address or domain name of the host. For example, 192.168.XX.XX or www.example.com.
    HostnameA custom name for the host. Must be 1–128 characters, cannot start with a special character, and can contain periods (.), underscores (_), hyphens (-), and spaces.
    Network DomainThe network path the bastion host uses to reach this host. The default Direct Network (Direct Connection) means the bastion host connects directly, without a proxy. If the host is not directly reachable, select a network domain configured with a proxy server. For details, see Use the network domain feature.
    Asset GroupThe asset group to assign this host to. Asset groups let you organize and manage hosts of the same type together. For details, see Manage asset groups.
    RemarksAn optional label to identify the host.

Import hosts from a file

Use a template file to register multiple hosts at once. The downloadable template package includes XLS, CSV, and XLSX formats.

  1. Log on to the Bastionhost console. In the top navigation bar, select the region where your bastion host resides.

  2. In the bastion host list, find the bastion host and click Manage.

  3. In the left-side navigation pane, choose Assets > Hosts.

  4. From the Import Other Hosts drop-down list, select Import Hosts from File.

  5. In the Import Hosts panel, click Download Host Template. Decompress the package, open a template file in your preferred format, enter the host information, and save the file.

  6. In the Import Hosts panel, click Upload and select the template file you saved.

  7. In the Preview dialog box, select the hosts to import and click Import.

  8. In the Import Hosts panel, confirm the host information and click Import Hosts.

Import hosts from a third-party asset source

Pull hosts directly from Tencent Cloud, Huawei Cloud, AWS, or another third-party source you have configured.

  1. Log on to the Bastionhost console. In the top navigation bar, select the region where your bastion host resides.

  2. In the bastion host list, find the bastion host and click Manage.

  3. In the left-side navigation pane, choose Assets > Hosts.

  4. Click Import Other Hosts and select the third-party asset source from the drop-down list.

  5. In the Import Third-party Hosts dialog box, select the hosts to import and click Import.

Verify the import

After the import completes, confirm the hosts appear in Bastionhost:

  1. In the left-side navigation pane, choose Assets > Hosts.

  2. Check that the imported hosts are listed with the correct hostnames and IP addresses.

If a host does not appear, check that:

  • The host's IP address or domain name is correct and reachable from the bastion host

  • A proxy-based network domain is configured if the host is not directly reachable

What's next

  • Add a host account — Bastionhost requires at least one host account (the OS-level login credential) before you can open a session. See Manage a host account.

  • Change the service port — If the host uses a non-default SSH or RDP port, update it before connecting. See Change the service port of a host.

  • Manage hosts — Edit, group, or remove registered hosts. See Manage hosts.