All Products
Search
Document Center

Bastionhost:Automatic O&M

Last Updated:Aug 28, 2026

You can create O&M tasks with defined rules, such as execution schedules and scripts, to automate O&M on hosts at scale and improve efficiency.

Supported editions

Enterprise Edition and SM Edition

Note

If your Bastionhost instance is a Basic Edition instance, you must upgrade it to a supported edition. For more information, see Upgrade an instance.

Prerequisites

You must have imported hosts and users into your Bastionhost instance and authorized them to manage the required hosts and host accounts. For more information, see Create a host, Manage users, and Authorize assets and asset accounts.

Limitations

  • A single O&M task can run for a maximum of 24 hours. If a task exceeds this limit, its connection is terminated.

  • A single O&M task can be associated with a maximum of 200 host accounts.

  • The total number of O&M tasks and the maximum number of concurrent tasks vary by bastion host specification. The following table describes the limits.

    Note

    O&M tasks in all states (such as Pending Approval, Running, and Successful) count toward the task limit.

    Bastion host specification

    Maximum tasks

    Maximum concurrent tasks

    50 assets

    200

    200

    100 assets

    200 assets

    500 assets

    1,000

    500

    1,000 assets

    2,000 assets

    5,000 assets

    2,000

    1,000

    10,000 assets

    20,000 assets

    5,000

    2,000

Procedure

RAM users create O&M tasks in the Bastionhost console. Non-RAM users create O&M tasks in the O&M portal.

RAM users

  1. Log on to the Bastionhost console. In the top navigation bar, select the region where your Bastionhost instance is located.

  2. In the list of Bastionhost instances, find the target instance and click Manage.

  3. In the navigation pane on the left, choose Asset O&M > O&M Tasks

  4. Optional: Create an O&M script.

    1. On the Script Management tab, click Create O&M Script.

    2. In the Create O&M Script panel, set the script name and content, and then click Create O&M Script.

      Note
      • The script name must be 1 to 128 characters in length, cannot start with a special character, and can contain only periods (.), underscores (_), hyphens (-), and spaces.

      • The script content supports only shell commands and cannot exceed 64 KB in size.

      • O&M engineers can create only private scripts. To create public scripts, contact an administrator.

  5. On the O&M Tasks tab, click Create O&M Task.

  6. On the Create O&M Task page, configure the task parameters as described in the following table, and then click Create O&M Task.

    Important
    • After you create an O&M task, its status is Pending Approval. The status changes to Pending after an administrator approves it. For more information about the administrator approval process, see Task approval.

    • Administrators can configure automatic approval for O&M tasks. If this feature is enabled, the system automatically approves tasks created by O&M engineers. For more information, see O&M configuration.

    Parameter

    Description

    Task Name

    Enter a globally unique name for the task.

    The name must meet the following requirements:

    • 1 to 128 characters in length.

    • Cannot start with a special character.

    • Can contain only periods (.), underscores (_), hyphens (-), and spaces.

    Execution Method

    Select an execution method:

    • Manual: The task must be triggered manually.

    • Periodic: Runs the task at a recurring interval. You can set the cycle in hours (1–720) or days (1–30).

    • Scheduled: Runs the task once at a specified time.

    Note

    Manually started tasks have a higher priority than scheduled tasks (Periodic and Scheduled).

    Script Content

    Enter the script content manually or select an O&M script (public or private script).

    Note
    • The script content supports only shell commands and cannot exceed 64 KB in size.

    • O&M engineers create private scripts, while administrators create public scripts. For more information about how to create a public script, see Manage O&M tasks.

    Associate Host Account

    You can associate an O&M task only with authorized host accounts that have at least one credential (password, SSH private key, or shared key) managed by Bastionhost. For more information about how to authorize host accounts, see Authorize assets and asset accounts.

Non-RAM users

  1. Log on to the Bastionhost O&M portal. For more information, see Log on to the O&M portal.

  2. In the navigation pane on the left, click O&M Tasks.

  3. Optional: Create an O&M script.

    1. On the Script Management tab, click Create O&M Script.

    2. In the Create O&M Script panel, set the script name and content, and then click Create O&M Script.

      Note
      • The script name must be 1 to 128 characters in length, cannot start with a special character, and can contain only periods (.), underscores (_), hyphens (-), and spaces.

      • The script content supports only shell commands and cannot exceed 64 KB in size.

      • O&M engineers can create only private scripts. To create public scripts, contact an administrator.

  4. On the O&M Tasks tab, click Create O&M Task.

  5. On the Create O&M Task page, configure the task parameters as described in the following table, and then click Create O&M Task.

    Important
    • After you create an O&M task, its status is Pending Approval. The status changes to Pending after an administrator approves it. For more information about the administrator approval process, see Task approval.

    • Administrators can configure automatic approval for O&M tasks. If this feature is enabled, the system automatically approves tasks created by O&M engineers. For more information, see O&M configuration.

    Parameter

    Description

    Task Name

    Enter a globally unique name for the task.

    The name must meet the following requirements:

    • 1 to 128 characters in length.

    • Cannot start with a special character.

    • Can contain only periods (.), underscores (_), hyphens (-), and spaces.

    Execution Method

    Select an execution method:

    • Manual: The task must be triggered manually.

    • Periodic: Runs the task at a recurring interval. You can set the cycle in hours (1–720) or days (1–30).

    • Scheduled: Runs the task once at a specified time.

    Note

    Manually started tasks have a higher priority than scheduled tasks (Periodic and Scheduled).

    Script Content

    Enter the script content manually or select an O&M script (public or private script).

    Note
    • The script content supports only shell commands and cannot exceed 64 KB in size.

    • O&M engineers create private scripts, while administrators create public scripts. For more information about how to create a public script, see Manage O&M tasks.

    Associate Host Account

    You can associate an O&M task only with authorized host accounts that have at least one credential (password, SSH private key, or shared key) managed by Bastionhost. For more information about how to authorize host accounts, see Authorize assets and asset accounts.

Related topics

  • After an O&M engineer creates an O&M task, an administrator must approve it before it can run. For more information about the approval process, see Task approval.

    Administrators can enable automatic approval, which eliminates the need for manual review of tasks created by O&M engineers. For more information, see O&M configuration.

  • Administrators can manage tasks created by O&M engineers. For example, an administrator can view task details, stop or delete tasks, and create public O&M scripts for them to use. For more information, see Manage O&M tasks.