You can use Hybrid Backup Recovery (HBR) to back up files from Elastic Compute Service (ECS) instances and restore these files when they are lost or damaged. This topic describes how to back up files from ECS instances.

Prerequisites

Preparations are completed.

Back up files from a single ECS instance

To use HBR to back up files from a single ECS instance, follow these steps:

  1. Log on to the HBR console.
  2. In the left-side navigation pane, choose Backup > ECS File Backup.
  3. On the ECS File Backup page, click the ECS Instance tab.
  4. On the ECS Instance tab, find the target ECS instance and click Backup in the Actions column.
  5. In the Create Backup Plan pane that appears, set the parameters as described in the following table and click OK.
    Parameter Description
    Plan Name The name of the backup plan. If you do not specify this parameter, a random name is set by default.
    Source File Path The path of the backup source. Set source paths based on the following rules:
    • You can enter a maximum of eight paths if the paths do not contain wildcard characters, such as asterisks (*).
    • You can enter only one path if the path contains wildcard characters, such as asterisks (*). You can enter wildcard characters in the following format: /*/*.
    • You can enter only absolute paths, for example, paths that start with a forward slash (/), two backslashes (\\), C:\, or D:\.
    Note
    • You can specify only one root path at a time. For example, you cannot enter C:\ and D:\ at the same time.
    • If you use volume shadow copy service (VSS), you cannot enter multiple paths, a universal naming convention (UNC) path, or the storage path of files to exclude. Also, the path cannot contain wildcard characters.
    • If you use a UNC path, you cannot use VSS or enter the storage path of files to exclude. Also, the path cannot contain wildcard characters. If the path of the backup source contains a UNC path, HBR does not back up the access control list (ACL) of Windows.
    Backup File Rule The rule for backing up files. You can set the value to Include All Files or Exclude Files.
    If you set the value to Exclude Files, enter the storage paths of files to exclude.
    Note The following rules apply to the storage paths of files to exclude:
    • You can enter a maximum of eight paths, including paths that contain wildcard characters, such as asterisks (*).
    • If the paths do not contain a forward slash (/), asterisks (*) match multi-level paths or files. For example, *abc* matches /abc/, /d/eabcd/, and /a/abc, and *.txt matches files whose file name extension is .txt.
    • If the paths contain a forward slash (/), each asterisk (*) only matches a single-level path or a file. For example, /a/*/*/share only matches /a/b/c/share instead of /a/d/share.
    • If the paths end with a forward slash (/), asterisks (*) match folders. For example, *tmp/ matches /a/b/aaatmp/ and /tmp/.
    • Use forward slashes (/) as path delimiters for Linux and backslashes (\) for Windows.
    Start Time The start time of the backup plan. The time is accurate to seconds.
    Plan Run Interval The interval for backing up incremental data. Valid units: hours, days, and weeks.
    Note The maximum interval is 52 weeks.
    Retention The retention period of backup data. Valid units: days, weeks, months, and years.
    Using VSS
    • Specifies whether to use VSS for backup. This parameter is available only for ECS instances whose operating system is Windows.
    • You can set the value to Use if data in the backup source changes. The feature is designed to keep data consistency between a backup source and its backup.
    • If you use VSS, you cannot back up data from multiple directories at a time.
    Note This feature is unavailable if the backup source resides on a volume of the exFAT format.
    Using Flow Control

    Specifies whether to enable throttling. You can enable throttling to set bandwidth limits for backing up data from a directory during peak hours. This guarantees business continuity.

    If you set the value to Use, set Time Range and enter the maximum bandwidth that can be used for backup during the specified throttling period in the Max Flow field based on business requirements. Then, click Add.

Back up files from multiple ECS instances

If you want to back up files from multiple ECS instances, you can create multiple backup plans at a time. To create multiple backup plans, follow these steps:

  1. Log on to the HBR console.
  2. In the left-side navigation pane, choose Backup > ECS File Backup.
  3. In the top navigation bar, select the region where the ECS instances to be backed up reside.
  4. In the upper-right corner, choose Batch Operation > Batch Add Backup Plan.
  5. In the Batch Create Backup Plan pane that appears, click Download Template.
  6. Open the downloaded template, set the parameters as described in the following table, and then save the template.
    Note If you do not want to back up files from an ECS instance, you can delete all parameters of the instance from the template.
    Parameter Description
    Client Id The ID of the backup client you can use to back up files. We recommend that you do not change the ID.
    Instance Id The ID of the ECS instance where the backup client is installed. We recommend that you do not change the ID.
    Instance Name The name of the ECS instance where the backup client is installed. We recommend that you do not change the name.
    Source The path of the directory from which you want to back up files. The path must be an absolute path.
    Plan name The name of the backup plan. If you do not specify this parameter, a random name is set by default.
    Retention (Day)
    • The retention period of backup data. You must enter an integer.
    • Default unit: days.
    • If you do not specify this parameter, the backup data is stored for 730 days by default.
    Effective Time The start time of the backup plan. Specify the time in the YYYY-MM-DD/HH:MM:SS format, for example, 2018-12-03/12:00:00.
    Backup Interval
    • The interval for backing up incremental data. You must enter an integer.
    • Default unit: hours.
    • If you do not specify this parameter, the interval is 24 hours by default.
    Use VSS for backup (Windows only)
    • Specifies whether to use VSS for backup. This parameter is available only for ECS instances whose operating system is Windows.
    • You can enable this feature if data in the backup source changes. The feature is designed to keep data consistency between a backup source and its backup.
    • Enter Y to enable this feature or N to disable this feature. If you do not specify this parameter, the feature is disabled by default.
    • If you use VSS, you cannot back up data from multiple directories at a time.
    Bandwidth Throttling
    • Specifies whether to enable throttling. You can set bandwidth limits for backing up data from a directory during peak hours. This guarantees business continuity.
    • If you enable this feature, enter the maximum bandwidth that can be used for backup.
    • You must enter an integer. Default unit: MB/s.
    • If you do not specify this parameter, the bandwidth is not throttled by default.
  7. Click Upload Template to upload the template.
  8. Click OK.

Browse backup files online

You can use the online browse feature of HBR to quickly browse all files in each backup plan.

  1. On the Backup Plan and Job tab, find the target backup plan and click View in the Actions column.
  2. On the page that appears, select a backup source and click Browser in the Actions column.

    In the Browser pane that appears, view all files in the source directory.

    Notice You can only browse files in this pane. For more information about how to restore files to an ECS instance, see Restore files to an ECS instance.

What to do next

On the ECS File Backup page, click the Backup Plan and Job tab. On this tab, you can perform the operations as described in the following table.
Operation Description
View an error report Find the target backup plan and view the backup progress in the Status column. If some files fail to be backed up, click View in the Actions column. On the page that appears, click the Download icon in the Errors column to download the error report.
Start a backup job Find the target backup plan and choose More > Execute in the Actions column.
Cancel a running backup job Find the target backup plan and choose More > Cancel Task in the Actions column.
Pause a running backup job Find the target backup plan and choose More > Pause in the Actions column.
Resume a paused backup job Find the target backup plan and choose More > Enable in the Actions column.
Modify a backup plan Find the target backup plan and choose More > Edit in the Actions column.
Delete a backup plan Find the target backup plan and choose More > Delete in the Actions column. After you delete a backup plan, HBR no longer runs the plan but retains data that is backed up by using the plan.

FAQ

If you fail to back up files due to network instability, you can perform the following operations and try again:

  1. Log on to the ECS instance where files need to be backed up.
  2. Go to the installation directory of the HBR backup client.
  3. In the client folder, create a file named hbr.config.
    Note The hbr.config file must be stored in the same directory as the hybridebackup and ids executable files.
  4. Add the following parameters to the hbr.config file.
    Parameter Description
    retry_times The number of file backup retries. Default value: 3.
    retry_interval The interval for retrying file backups. Default value: 100 ms.
    skip_error_files Specifies whether to skip files failed to be backed up. Default value: false.
    • false: does not skip files failed to be backed up.
    • true: skips files failed to be backed up.

For example, you can add the following parameters to the hbr.config file:

retry_times=3
retry_interval=100
skip_error_files=false