Workspace backup and restoration is used for code migration between workspaces. This topic describes how to back up and restore a workspace.
Click in the lower-left corner of the DataStudio page to go to the Setup page.
- On the Backup tab, you can compress the node code, node dependencies, resources, and functions in a workspace into one package.
- On the Restore tab, you can restore a workspace to its original scheduling settings. After the workspace is restored, all nodes in the workspace are saved but not committed.
Go to the Workspace Backup and Restoration page
- Log on to the DataWorks console. In the left-side navigation pane, click Workspaces. On the Workspaces page, find the target workspace and click Data Analytics in the Actions column.
- Click in the lower-left corner of the page to go to the Setup page.
- In the top navigation bar, click Workspace Backup and Restoration.
Back up the workspace
- Only workspace administrators can export backups and restore data from backups on the Configuration Center page. For more information about how to open the Configuration Center page, see Setup.
- Workflows and node groups of earlier versions cannot be backed up. We recommend that you use the latest version for data analytics.
- A node backed up to a path in the workspace will override the original node with the same name in the path. We recommend that you create a new workspace to restore data.
- Data in tables is not backed up when you back up a workspace. You can synchronize
the table data in the following ways:
- Choose , configure a MaxCompute connection, and then create a sync node to back up the data.
- In workspace A, run the DDL statement
create table select * from workspace B. table nameto migrate data.
- Go to the Backup tab. Then, click Create Backup in the upper-right corner. page and click the
- In the Create Backup dialog box, configure Method and Version.
You can set the backup method to Full or Incremental.
Note If you use the incremental backup method, make sure that the dependencies between incremental sync nodes are correct. Otherwise, the workspace may fail to be restored. We recommend that you set Method to Full.
- Full: Back up all the node code, node dependencies, resources, and functions in the workspace.
- Incremental: Set Start Timestamp to back up all the new or modified nodes from the specified start timestamp to the current time.
Valid values are Public Cloud, Apsara Stack V3.6.1-V3.8.1, and Apsara Stack < V3.6.1.
- After the configuration is completed, click Create.
Restore the workspace
- Go to the Restore tab. Then, click Restore in the upper-right corner. page and click the
- In the Restore dialog box, click Select File.
Note You can upload the compressed package that you previously backed up to the workspace.
- After the configuration is completed, click Restore.
- In the Set Compute Engine Mapping dialog box, configure Compute Engine Instances of Target Workspace.
If the workspace that you backed up contains multiple compute engines, the system scans all compute engine instances during restoration. The system only restores nodes of the existing compute engines in the workspace to be restored. In this case, you must configure the mappings between the compute engines before restoring the target workspace.Note
- If the workspace to be restored does not contain a compute engine type such as E-MapReduce, or no instance is available for the compute engine type, nodes of this engine type are not restored.
- The custom node types vary with regions. Therefore, you must also create the mappings among the custom node types. For example, you must configure the mappings among the custom nodes such as Hologres node, Data Lake Analytics node, AnalyticDB for MySQL node, and AnalyticDB for PostgreSQL node.