az sql midb-arc
Note
This reference is part of the arcdata extension for the Azure CLI (version 2.3.1 or higher). The extension will automatically install the first time you run an az sql midb-arc command. Learn more about extensions.
Manage databases for Azure Arc-enabled SQL managed instances.
Commands
Name | Description | Type | Status |
---|---|---|---|
az sql midb-arc restore |
Restore a database to an Azure Arc enabled SQL managed instance. |
Extension | GA |
az sql midb-arc restore
Restore a database to an Azure Arc enabled SQL managed instance.
az sql midb-arc restore [--dest-name]
[--dry-run]
[--k8s-namespace]
[--managed-instance]
[--name]
[--no-wait]
[--time]
[--use-k8s]
Examples
Ex 1 - Restore a database using Point in time restore.
az sql midb-arc restore --managed-instance sqlmi1 --name mysourcedb
--dest-name mynewdb --time "2021-10-20T05:34:22Z" --k8s-namespace
arc --use-k8s --dry-run
Optional Parameters
Name of the database that will be created as the restore destination.
Validates if the restore operation can be successful or not by returning earliest and latest restore time window.
The Kubernetes namespace that contains the Azure Arc enabled SQL managed instance. If no namespace is specified, then the namespace defined in the kubeconfig will be used.
Name of the source Azure Arc enabled SQL managed instance.
Name of the source database from where the backups should be retrieved.
Do not wait for the long-running operation to finish.
The point in time of the source database that will be restored to create the new database. Must be greater than or equal to the source database's earliest restore date/time value. Time should be in following format: 'YYYY-MM-DDTHH:MM:SSZ'. If no time is provided, the most recent backup will be restored.
Use local Kubernetes APIs to perform this action.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.