-
Notifications
You must be signed in to change notification settings - Fork 26
/
vsphere_migrate_datastore.html.md.erb
114 lines (66 loc) · 5.41 KB
/
vsphere_migrate_datastore.html.md.erb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
---
title: Migrating Ops Manager to a New Datastore in vSphere
owner: Customer0
---
<% current_page.data.title = "Migrating " + vars.platform_name + " to a New Datastore in vSphere" %>
This topic describes how to migrate your <%= vars.platform_name %> installation to a new vSphere datastore.
## <a id="prereqs"></a> Prerequisites
Both the new and existing vSphere datastores must reside in the same datacenter.
To avoid service disruption, <%= vars.company_name %> recommends that you configure your overall <%= vars.platform_name %> deployment for high availability (HA). In addition, check for configurations necessary to achieve HA in each of your installed product tiles.
If your environment has any single points of failure, service may be disrupted as a result of the migration.
## <a id="prep"></a> Before You Begin
These sections describe the steps you should perform prior to the migration.
### <a id="backup"></a> Step 1: Back Up Your Environment
Ensure that your <%= vars.platform_name %> environment is fully backed up.
For more information about how to back up <%= vars.platform_name %>, see [Backing Up Deployments](../../customizing/backup-restore/index.html).
### <a a id="doc"></a> Step 2: Document Current Environment Settings
Document your current environment settings before proceeding with the datastore migration. Record which VMs are running
and in which datastore they reside. If you experience any issues during or after the migration, you must have this
information to restore your environment.
To obtain this information:
1. Run one of these commands:
* If you use BOSH CLI v2, run:
<pre>
bosh -e BOSH-ENVIRONMENT instances --details > instances.txt
</pre>
Where `BOSH-ENVIRONMENT` is the alias you assigned to your BOSH Director.
* If you use the original version of the BOSH CLI, run:
<pre>
bosh-old instances --details > instances.txt
</pre>
1. Save the resulting `instances.txt` file to a safe location.
1. Note the datastore where each VM resides in vSphere.
### <a id="system_health"></a> Step 3: Check System Health
Check the **Status** tab in your runtime product tiles,
such as <%= vars.app_runtime_full %> (<%= vars.app_runtime_abbr %>) or
<%= vars.k8s_runtime_full %> (<%= vars.k8s_runtime_abbr %>), and make sure there are no errors or reported issues.
### <a id="tile_heatlh"></a> Step 4: Check Installed Products Health
In each tile installed in your <%= vars.platform_name %> deployment, check the **Status** tab and make sure there are no errors or reported issues.
### <a id="opsman_health"></a> Step 5: Check BOSH Director Status
To check the status of your BOSH Director:
1. Check that there are no pending changes and that the status of all tiles is green.
1. Make sure the last Installation Log does not contain any errors.
1. Before proceeding with the migration, click **Review Pending Changes** and **Apply Changes** to make sure there are no errors in the Installation Log.
## <a id="migrate_proc"></a> Procedure: Migrate <%= vars.platform_name %> to a New Datastore
To migrate your <%= vars.platform_name %> deployment to a new datastore:
1. Navigate to the <%= vars.ops_manager %> Installation Dashboard.
1. Click the BOSH Director tile.
1. Select **vCenter Config**.
1. Update the **Ephemeral Datastore Names** and **Persistent Datastore Names** fields to reflect the new datastore names.
<p class="note"><strong>Note:</strong> If you use the datastore clustering feature in vSphere, provide only the individual names of the datastores in the cluster. Do not provide the name of the cluster that contains them.</p>
1. Click **Save**.
1. Click **Review Pending Changes**, then **Apply Changes**.
1. Confirm that the BOSH Director VM has persistent disk on the new datastore.
1. Select **vCenter Resource Pools** and select the **Resource Pool** that contains your <%= vars.platform_name %> deployment VMs and new datastore.
1. Click the **Related Objects** and **Virtual Machines**.
1. Locate the <%= vars.ops_manager %> VM and verify that the VM has an expected value in the **Provisioned Space** column.
<%= image_tag('vsphere-web-client.png') %>
1. In the BOSH Director tile, select **Director Config**.
1. Select the **Recreate VMs deployed by the BOSH Director** option.
1. Click **Review Pending Changes**, then **Apply Changes**.
## <a id="after"></a> After the Migration
When BOSH moves disks, it waits for up to 60 minutes for the operation to complete. If the operation does not complete in time, BOSH can enter a state where it claims that the disks are `out of sync`. These sections describe how to resolve and prevent out-of-sync errors.
### <a id="fix_sync_error"></a> Fix Failed BOSH Deployment with Out-of-Sync Error
If your <%= vars.platform_name %> deployment gets into this state, follow the procedure in [How to Recover the out of Sync VMs on vSphere from a Failed BOSH Deployment](https://community.pivotal.io/s/article/How-to-Recover-the-out-of-Sync-VMs-on-vSphere-from-a-Failed-Bosh-Deployment) in the Knowledge Base.
### <a id="prevent_sync_error"></a> Prevent Out-of-Sync Error
You can prevent the `out of sync` BOSH error by increasing the CPI timeout to a larger value before performing the migration. To prevent the error, follow the procedure in [How to Increase the Timeout on BOSH CPI Command Calls in Pivotal Cloud Foundry](https://community.pivotal.io/s/article/how-to-increase-the-timeout-on-bosh-cpi-command-calls) in the Knowledge Base.