In our previous post (Part 8) we have discussed how to recover the Oracle VM Manager using MySQL database. For that we need MySQL backup and admin & weblogic user password. But sometimes we might have chance to forget the admin or weblogic user password and also no backup of Oracle VM Manager MySQL database. In that case, we need to follow the below steps to recover the Oracle VM Manager.
Before starting our VM manager installation we need the existing Manager UUID value. The Oracle VM Manager UUID is located in Oracle VM Manager server (/u01/app/oracle/ovm-manager-3/.config) file and as well as in each server pool’ .ovsrepo file (OVS_REPO_MGR_UUID=UUID) located in the pool file system.
[root@mgmtsrv ~]# cat /repo2/.ovsrepo
OVS_REPO_UUID=0004fb000003000082b0d717e2f9871d
OVS_REPO_VERSION=3.0
OVS_REPO_MGR_UUID=0004fb00000100009157557324ed168d
OVS_REPO_ALIAS=OraRepo
Step 1: Move the OVS agent db directory
This step is not required, however we need to perform if we get any ownership error or warning during discovering the Oracle Virtual Server.
[root@ovs01 ~]# /etc/init.d/ovs-agent stop
Stopping Oracle VM Agent: [ OK ]
[root@ovs01 ~]# mv /etc/ovs-agent/db /etc/ovs-agent/db_bak20171223
[root@ovs01 ~]# /etc/init.d/ovs-agent start
Starting Oracle VM Agent: [ OK ]
Step 2: Login to Oracle VM Manager as admin
[root@mgmtsrv ~]# ssh -l admin ovm.lab.local -p 10000
admin@ovm.lab.local's password:
OVM>
Step 3: Discover one Oracle VM Server from each server pool
OVM> discoverServer ipaddress=ovs01.lab.local password=********** takeOwnership=Yes
Command: discoverServer ipaddress=ovs01.lab.local password=**** takeOwnership=Yes
Status: Success
Time: 2017-12-23 03:47:27,748 EST
JobId: 1514018774243
Step 4: Discover the storage that contains the server pool file system. Present it to the newly discovered Oracle VM Server. Refresh the storage.
OVM> create FileServer plugin="Oracle Generic Network File System" accessHost=mgmtsrv.lab.local adminServers="ovs01.lab.local" name=MYSANRec
Command: create FileServer plugin="Oracle Generic Network File System" accessHost=mgmtsrv.lab.local adminServers="ovs01.lab.local" name=MYSANRec
Status: Success
Time: 2017-12-23 03:50:08,007 EST
JobId: 1514019007499
Data:
id:0004fb0000090000371a9d6db792e728 name:MYSANRec
OVM> addAdminServer FileServer name=MYSANRec server=ovs01.lab.local
Command: addAdminServer FileServer name=MYSANRec server=ovs01.lab.local
Status: Success
Time: 2017-12-23 03:50:33,884 EST
JobId: 1514019033629
OVM> addRefreshServer FileServer name=MYSANRec server=ovs01.lab.local
Command: addRefreshServer FileServer name=MYSANRec server=ovs01.lab.local
Status: Success
Time: 2017-12-23 03:50:58,303 EST
JobId: 1514019058085
OVM> refresh FileServer name=MYSANRec
Command: refresh FileServer name=MYSANRec
Status: Success
Time: 2017-12-23 03:51:24,544 EST
JobId: 1514019082774
Step 5: Refresh the file systems or physical disks that contain the server pool file system
OVM> list FileSystem
Command: list FileSystem
Status: Success
Time: 2017-12-23 03:51:33,554 EST
Data:
id:9f4e1109-2c5b-4bae-834b-0ccc203e5ab6 name:nfs on mgmtsrv.lab.local:/repo2
id:f3834a16-6fcb-4f82-9a2a-b3d3ed936ae3 name:nfs on mgmtsrv.lab.local:/repo1
OVM> refresh FileSystem name="nfs on mgmtsrv.lab.local://repo1"
Command: refresh FileSystem name="nfs on mgmtsrv.lab.local://repo1"
Status: Success
Time: 2017-12-23 03:52:49,786 EST
JobId: 1514019168044
Step 6: Refresh the file systems or physical disks that contain the repositories used by server pool
OVM> refresh FileSystem name="nfs on mgmtsrv.lab.local://repo2"
Command: refresh FileSystem name="nfs on mgmtsrv.lab.local://repo2"
Status: Success
Time: 2017-12-23 03:52:54,608 EST
JobId: 1514019173387
Step 7: Present the repositories to the Oracle VM Server
OVM> add Server name=ovs01.lab.local to ServerPool name=Pool_01
Command: add Server name=ovs01.lab.local to ServerPool name=Pool_01
Status: Success
Time: 2017-12-23 03:57:10,904 EST
JobId: 1514019424928
OVM> list ServerPool
Command: list ServerPool
Status: Success
Time: 2017-12-23 03:57:18,884 EST
Data:
id:0004fb00000200002d1d67487c79ed89 name:Pool_01
OVM> add ServerPool name=Pool_01 to Repository name=OraRepo
Command: add ServerPool name=Pool_01 to Repository name=OraRepo
Status: Success
Time: 2017-12-23 03:59:06,197 EST
JobId: 1514019545102
Step 8: Refresh the repositories
OVM> refresh Repository name=OraRepo
Command: refresh Repository name=OraRepo
Status: Success
Time: 2017-12-23 03:59:20,625 EST
JobId: 1514019559448
Step 9: Check the VM list
OVM> list vm
Command: list vm
Status: Success
Time: 2017-12-23 04:04:50,724 EST
Data:
id:0004fb0000060000524f9d3e43fd71f3 name:FirstVM
OVM> start vm name=FirstVM
Command: start vm name=FirstVM
Status: Failure
Time: 2017-12-23 04:05:36,388 EST
JobId: 1514019936121
Error Msg: Job failed on Core: OVMRU_005053E: Virtual Machine: FirstVM, is not associated with any server pool [Sat Dec 23 04:05:36 EST 2017]
In above command, I’m trying to start the Virtual Machine but it failed because the VM “FirstVM” is not associated with any server pool. So we need to move this VM to corresponding Server Pool.
OVM> migrate Vm name=FirstVM destServerPool=Pool_01
Command: migrate Vm name=FirstVM destServerPool=Pool_01
Status: Success
Time: 2017-12-23 04:13:31,390 EST
JobId: 1514020411131
OVM> start vm name=FirstVM
Command: start vm name=FirstVM
Status: Success
Time: 2017-12-23 04:13:45,270 EST
JobId: 1514020416903