|
| 1 | +--- |
| 2 | +title: How to move your service resource across regions |
| 3 | +titleSuffix: Azure Cognitive Search |
| 4 | +description: This article will show you how to move your Azure Cognitive Search resources from one region to another in the Azure cloud. |
| 5 | + |
| 6 | +manager: nitinme |
| 7 | +author: tchristiani |
| 8 | +ms.author: terrychr |
| 9 | +ms.service: cognitive-search |
| 10 | +ms.topic: how-to |
| 11 | +ms.custom: subject-moving-resources |
| 12 | +ms.date: 02/18/2020 |
| 13 | +--- |
| 14 | + |
| 15 | +# Move your Azure Cognitive Search service to another Azure region |
| 16 | + |
| 17 | +To move your Azure Cognitive Service account from one region to another, you will create an export template to move your subscription(s). After moving your subscription, you will need to move your data and recreate your service. |
| 18 | + |
| 19 | +In this article, you'll learn how to: |
| 20 | + |
| 21 | +> [!div class="checklist"] |
| 22 | +> * Export a template. |
| 23 | +> * Modify the template: adding the target region, search and storage account names. |
| 24 | +> * Deploy the template to create the new search and storage accounts. |
| 25 | +> * Verify your service status in the new region |
| 26 | +> * Clean up resources in the source region. |
| 27 | +
|
| 28 | +## Prerequisites |
| 29 | + |
| 30 | +- Ensure that the services and features that your account uses are supported in the target region. |
| 31 | + |
| 32 | +- For preview features, ensure that your subscription is whitelisted for the target region. For more information about preview features, see [knowledge stores](https://docs.microsoft.com/azure/search/knowledge-store-concept-intro), [incremental enrichment](https://docs.microsoft.com/azure/search/cognitive-search-incremental-indexing-conceptual), and [private endpoint](https://docs.microsoft.com/azure/search/service-create-private-endpoint). |
| 33 | + |
| 34 | +## Assessment and planning |
| 35 | + |
| 36 | +When you move your search service to the new region, you will need to [move your data to the new storage service](https://docs.microsoft.com/azure/storage/common/storage-account-move?tabs=azure-portal#configure-the-new-storage-account) and then rebuild your indexes, skillsets and knowledge stores. You should record current settings and copy json files to make the rebuilding of your service easier and faster. |
| 37 | + |
| 38 | +## Moving your search service's resources |
| 39 | + |
| 40 | +To start you will export and then modify a Resource Manager template. |
| 41 | + |
| 42 | +### Export a template |
| 43 | + |
| 44 | +1. Sign in to the [Azure portal](https://portal.azure.com). |
| 45 | + |
| 46 | +2. Go to your Resource Group page. |
| 47 | + |
| 48 | +> [!div class="mx-imgBorder"] |
| 49 | +>  |
| 50 | +
|
| 51 | +3. Select **All resources**. |
| 52 | + |
| 53 | +3. In the left hand navigation menu select **Export template**. |
| 54 | + |
| 55 | +4. Choose **Download** in the **Export template** page. |
| 56 | + |
| 57 | +5. Locate the .zip file that you downloaded from the portal, and unzip that file to a folder of your choice. |
| 58 | + |
| 59 | +The zip file contains the .json files that comprise the template and scripts to deploy the template. |
| 60 | + |
| 61 | +### Modify the template |
| 62 | + |
| 63 | +You will modify the template by changing the search and storage account names and regions. The names must follow the rules for each service and region naming conventions. |
| 64 | + |
| 65 | +To obtain region location codes, see [Azure Locations](https://azure.microsoft.com/global-infrastructure/locations/). The code for a region is the region name with no spaces, **Central US** = **centralus**. |
| 66 | + |
| 67 | +1. In the Azure portal, select **Create a resource**. |
| 68 | + |
| 69 | +2. In **Search the Marketplace**, type **template deployment**, and then press **ENTER**. |
| 70 | + |
| 71 | +3. Select **Template deployment**. |
| 72 | + |
| 73 | +4. Select **Create**. |
| 74 | + |
| 75 | +5. Select **Build your own template in the editor**. |
| 76 | + |
| 77 | +6. Select **Load file**, and then follow the instructions to load the **template.json** file that you downloaded and unzipped in the previous section. |
| 78 | + |
| 79 | +7. In the **template.json** file, name the target search and storage accounts by setting the default value of the search and storage account names. |
| 80 | + |
| 81 | +8. Edit the **location** property in the **template.json** file to the target region for both your search and storage services. This example sets the target region to `centralus`. |
| 82 | + |
| 83 | +```json |
| 84 | +}, |
| 85 | + "variables": {}, |
| 86 | + "resources": [ |
| 87 | + { |
| 88 | + "type": "Microsoft.Search/searchServices", |
| 89 | + "apiVersion": "2015-08-19", |
| 90 | + "name": "[parameters('searchServices_target_region_search_name')]", |
| 91 | + "location": "centralus", |
| 92 | + "sku": { |
| 93 | + "name": "standard" |
| 94 | + }, |
| 95 | + "properties": { |
| 96 | + "replicaCount": 1, |
| 97 | + "partitionCount": 1, |
| 98 | + "hostingMode": "Default" |
| 99 | + } |
| 100 | + }, |
| 101 | + { |
| 102 | + "type": "Microsoft.Storage/storageAccounts", |
| 103 | + "apiVersion": "2019-06-01", |
| 104 | + "name": "[parameters('storageAccounts_tagetstorageregion_name')]", |
| 105 | + "location": "centralus", |
| 106 | + "sku": { |
| 107 | + "name": "Standard_RAGRS", |
| 108 | + "tier": "Standard" |
| 109 | + }, |
| 110 | +``` |
| 111 | + |
| 112 | +### Deploy the template |
| 113 | + |
| 114 | +1. Save the **template.json** file. |
| 115 | + |
| 116 | +2. Enter or select the property values: |
| 117 | + |
| 118 | +- **Subscription**: Select an Azure subscription. |
| 119 | + |
| 120 | +- **Resource group**: Select **Create new** and give the resource group a name. |
| 121 | + |
| 122 | +- **Location**: Select an Azure location. |
| 123 | + |
| 124 | +3. Click the **I agree to the terms and conditions stated above** checkbox, and then click the **Select Purchase** button. |
| 125 | + |
| 126 | +## Verifying your services' status in new region |
| 127 | + |
| 128 | +To verify the move, open the new resource group and your services will be listed with the new region. |
| 129 | + |
| 130 | +To move your data from your source region to the target region, please see this article's guidelines for [moving your data to the new storage account](https://docs.microsoft.com/azure/storage/common/storage-account-move?tabs=azure-portal#move-data-to-the-new-storage-account). |
| 131 | + |
| 132 | +## Clean up resources in your original region |
| 133 | + |
| 134 | +To commit the changes and complete the move of your service account, delete the source service account. |
| 135 | + |
| 136 | +## Next steps |
| 137 | + |
| 138 | +[Create an index](https://docs.microsoft.com/azure/search/search-get-started-portal) |
| 139 | + |
| 140 | +[Create a skillset](https://docs.microsoft.com/azure/search/cognitive-search-quickstart-blob) |
| 141 | + |
| 142 | +[Create a knowledge store](https://docs.microsoft.com/azure/search/knowledge-store-create-portal) |
| 143 | + |
0 commit comments