Stisknutím tlačítka "Enter" přeskočíte na obsah

Oprava „orphaned“ VM na vSAN

Někdy se vám může stát, že dojde k poškození některých objektů na vSAN (např. po chybovém update vSAN nodu). Některá VM pak i po resynchronizaci objektů však mohou zůstat nedostupná a ve stromu  „Host and Clusters“ se objeví místo původního názvu VM pouze:

/vmfs/volumes/vsan.uuid

Žádná panika, stačí se pouze připojit do RVC (Ruby vSphere Console) a spustit jeden příkaz. RVC je součást vCSA, je potřeba se tedy přihlásit přes SSH do vCSA pod rootem a pak spustit RVC:

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
rvc administrator@vsphere.local@localhost
password: SSO admin password
rvc administrator@vsphere.local@localhost password: SSO admin password
rvc administrator@vsphere.local@localhost
password: SSO admin password

Po té co jsme v RVC, tak spustit příkaz „vsan.check_state“:

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
vsan.check_state -r localhost/Datacenter*/computers/Cluster*/
vsan.check_state -r localhost/Datacenter*/computers/Cluster*/
vsan.check_state -r localhost/Datacenter*/computers/Cluster*/

Parametr „-r“ znovu načte *.vmx a zaregitruje VM

Výpis pak vypadá následovně:

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
2018-05-31 09:47:46 +0000: Step 1: Check for inaccessible vSAN objects
2018-05-31 09:47:52 +0000: Step 1b: Check for inaccessible vSAN objects, again
2018-05-31 09:47:52 +0000: Step 2: Check for invalid/inaccessible VMs
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2fd056965a-a828-be19-' as being 'orphaned', reloading ...
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f8ccd975a-750d-e8e7-' as being 'orphaned', reloading ...
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f71b1965a-1143-61e8-' as being 'orphaned', reloading ...
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f1fc5975a-9dae-596f-' as being 'orphaned', reloading ...
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2fd056965a-a828-be19-: success
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f8ccd975a-750d-e8e7-: success
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f71b1965a-1143-61e8-: success
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f1fc5975a-9dae-596f-: success
2018-05-31 09:47:54 +0000: Step 2b: Check for invalid/inaccessible VMs again
2018-05-31 09:47:54 +0000: Step 3: Check for VMs for which VC/hostd/vmx are out of sync
Did not find VMs for which VC/hostd/vmx are out of sync
2018-05-31 09:47:46 +0000: Step 1: Check for inaccessible vSAN objects 2018-05-31 09:47:52 +0000: Step 1b: Check for inaccessible vSAN objects, again 2018-05-31 09:47:52 +0000: Step 2: Check for invalid/inaccessible VMs Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2fd056965a-a828-be19-' as being 'orphaned', reloading ... Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f8ccd975a-750d-e8e7-' as being 'orphaned', reloading ... Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f71b1965a-1143-61e8-' as being 'orphaned', reloading ... Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f1fc5975a-9dae-596f-' as being 'orphaned', reloading ... reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2fd056965a-a828-be19-: success reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f8ccd975a-750d-e8e7-: success reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f71b1965a-1143-61e8-: success reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f1fc5975a-9dae-596f-: success 2018-05-31 09:47:54 +0000: Step 2b: Check for invalid/inaccessible VMs again 2018-05-31 09:47:54 +0000: Step 3: Check for VMs for which VC/hostd/vmx are out of sync Did not find VMs for which VC/hostd/vmx are out of sync
2018-05-31 09:47:46 +0000: Step 1: Check for inaccessible vSAN objects

2018-05-31 09:47:52 +0000: Step 1b: Check for inaccessible vSAN objects, again

2018-05-31 09:47:52 +0000: Step 2: Check for invalid/inaccessible VMs
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2fd056965a-a828-be19-' as being 'orphaned', reloading ...
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f8ccd975a-750d-e8e7-' as being 'orphaned', reloading ...
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f71b1965a-1143-61e8-' as being 'orphaned', reloading ...
Detected VM '%2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f1fc5975a-9dae-596f-' as being 'orphaned', reloading ...
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2fd056965a-a828-be19-: success
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f8ccd975a-750d-e8e7-: success
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f71b1965a-1143-61e8-: success
reloadVirtualMachineFromPath %2fvmfs%2fvolumes%2fvsan:52e427d394ea1add-f942937ce413fb10%2f1fc5975a-9dae-596f-: success

2018-05-31 09:47:54 +0000: Step 2b: Check for invalid/inaccessible VMs again

2018-05-31 09:47:54 +0000: Step 3: Check for VMs for which VC/hostd/vmx are out of sync
Did not find VMs for which VC/hostd/vmx are out of sync

Nyní je vše opraveno a můžete startovat VM.