Skip to content

Commit 369ef56

Browse files
authored
DTSPO-23529 - Document Update (#388)
* added documentation * added image * added images * updated test * changed mounting schedule text
1 parent d1d4b65 commit 369ef56

File tree

3 files changed

+43
-1
lines changed

3 files changed

+43
-1
lines changed

source/Services/atlassian.html.md.erb

Lines changed: 43 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,48 @@ Your account then should sync with Jira and Confluence and you can then able to
183183

184184
**5.** Change colours of the environment to differentiate between Live and Staging
185185

186+
### Creating Manual Backups
187+
188+
When we are cutting over to the new production environment, we need to take manual backups of the VMs. We have used the following script to take the manual backups:
189+
190+
```bash
191+
VaultName="BK-PRD-ATL-INT-01"
192+
ResourceGroup="RG-PRD-ATL-INT-01"
193+
Subscription="79898897-729c-41a0-a5ca-53c764839d95"
194+
195+
RetainUntil=$(date -v+3d '+%d-%m-%Y')
196+
197+
az account set --subscription $Subscription
198+
199+
# List of VM names
200+
VMNames=(
201+
"PRDATL01ACNF02.cp.cjs.hmcts.net"
202+
"PRDATL01ACNF04.cp.cjs.hmcts.net"
203+
"PRDATL01ACRD01.cp.cjs.hmcts.net"
204+
"PRDATL01AJRA01.cp.cjs.hmcts.net"
205+
"PRDATL01AJRA02.cp.cjs.hmcts.net"
206+
"PRDATL01AJRA03.cp.cjs.hmcts.net"
207+
"PRDATL01DGST01.cp.cjs.hmcts.net"
208+
"PRDATL01DGST02.cp.cjs.hmcts.net"
209+
"PRDATL01DGST03.cp.cjs.hmcts.net"
210+
)
211+
212+
# Loop through each VM name and execute the backup command
213+
for VMName in "${VMNames[@]}"; do
214+
ContainerName=$(az backup container list --resource-group $ResourceGroup --vault-name $VaultName --backup-management-type AzureIaasVM --query "[?properties.friendlyName=='$VMName'].{Name:name}" -o tsv)
215+
az backup protection backup-now --container-name $ContainerName --item-name $VMName --resource-group $ResourceGroup --retain-until $RetainUntil --vault-name $VaultName --backup-management-type AzureIaasVM
216+
done
217+
218+
```
219+
220+
Above script will take the backup of the VMs and will retain them for 3 days.
221+
222+
Below is the time it has taken to take the backups last time when we did it:
223+
<img src=images/AtlassianVMBackup.png width="600">
224+
225+
Once the VMs are backed up, we are then able to use the latest backup to restore the VMs to the new production environment.
226+
227+
<img src=images/AtlassianVMBackupRestore.png width="600">
186228

187229
## Troubleshooting
188230

@@ -193,6 +235,6 @@ e.g `jira_shared` should be mounted here `/var/atlassian/application-data/jira/
193235

194236
Please use `mount -a` command to mount them correctly.
195237

196-
There was problem where the share was not mounted correctly after auto shutdown, we have got cronjob on the staging VMs to run the mounting script everyday at 8am.
238+
There was problem where the share was not mounted correctly after auto shutdown, we have got cronjob on the staging VMs to run the mounting every hour, the script checks if the Share is mounted or not and if not, it will attempt to mount it.
197239

198240

399 KB
Loading
Loading

0 commit comments

Comments
 (0)