billdossett
Hot Shot
Hot Shot

Restore VCSA - worked, but not in inventory and can't add it :-(

So, my vcenter server appliance was in pretty bad shape at the start of the weekend, I had an appliance manager backup on my ftp server from the day before so shut down the appliance that was misbehaving and did a redeploy/restore...  everything seems to have worked, other than my new VCSA isn't in my inventory.  And when browse to it in the datastore and right click the vmx, add to inventory isn't available.  How to fix?

Thanks

Bill

Bill Dossett
0 Kudos
4 Replies
SupreetK
Commander
Commander

SSH on-to a host --> Navigate to the VM folder --> Run the command <vmkfstools -D "vCenterVM_name.vmx"> to check which host is holding the lock, if any. vCSA might be registered on that host already.

Determine the lock owner - VMware Knowledge Base

Once you identify the host that is holding the lock and if you don't see the VM on that host, you might want to restart the management agents or reboot the host to get rid of the stale lock/registration.

Please consider marking this answer as "correct" or "helpful" if you think your questions have been answered.

Cheers,

Supreet

0 Kudos
continuum
Immortal
Immortal

> And when browse to it in the datastore and right click the vmx, add to inventory isn't available.
This will happen with a vmx-file with syntax errors. Check the vmx-file for errors.


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

0 Kudos
billdossett
Hot Shot
Hot Shot

didn't work...  the mac address that it returned did not correspond to any hosts management, or any other mac address...  information on finding the host mac address is also outdated.

The vcenter is registered with my first host.  I can start it and stop it there. but when I login to my vcenter appliance after starting, it is not registered.

So I unregistered it from host1.  One by one put all hosts in Maint mode and rebooted.

I then need to start my vcenter, so I have to register it with a host.  I registered it with host 1 again.  Powered it up.  Now it will not let me login to the console as root.  Says invalid login or password.  This occurred after unregistering and re-registering it.   This was what happened to my original vcsa ... I couldn't login to the console as root.  I tried changing the password using the

rw init=/bin/bash

method, but when I came up in the shell, passwd was unrecognized command...  which is why I restored a good copy of it and got to this state.

So currently, vcenter is registered with host 1, it is working.  I can login with the administrator@vsphere.local account which is same password as the root console account that I can't login as.

Haha,  just tried again, and now I can login to the console with root password. 

Still can not see the vcenter in the vcenter inventory though... so I can't vmotion to another host, I can't move it to the DVswitch it is supposed to be on. 

So after going through this numerous times... I finally just tried disconnecting the host 1 that it was on, reconnected it - it asked for creds and all like I was actually adding the host, and it asked where to put the VMs, and the VCSA was listed.. and added it and there it was.   Not sure why I didn't try that earlier.

I also seemed to have the old VCSA registered but it was powered down... I deleted that anyway...

I haven't got time to try and do the whole restore thing again...  I will try and do it again later this week as I think there are possibly some issues that need to be nailed down and may help others.

1.  if you restore using the deploy/restore.. to an esxi host, it would seem like it can only restore to a standard switch - so hopefully you have one of those and its connected to a NIC or else you would be out of luck

2.  The new VCSA will be registered to a host, but when you login to it, it isn't registered to the appliance...  I changed the name of it when I was restoring, maybe I  shouldn't have?  I just wanted to be able to differentiate between the old an the new one easily.

3.  If it is registered to a host, you can't register it in the appliance as the host already has it locked... so disconnect the host and reconnect it and you should then have it registered

This is pretty much all conjecture at this point until I can go back and test further, but there doesn't seem to be a lot of info about restoring from vcsa manager backups at this point.  It seems like a really useful thing to me, but you want to know exactly what needs to be done to make it work again after you restore.  Like I say, hopefully I can test all this again later this week and see if it was changing the VM name or what ... or if you really do need to disconnect the host and reconnect it every time you do a restore.  Will post back later... anyone else with any restore experience that hasn't had this problem, please pipe up, would be good to hear!

Thanks

Bill

Bill Dossett
0 Kudos
olant
Contributor
Contributor

I just had the same issue with vSphere 7 Update 1. I disconnected and removed the ESX and added it back, then the VM reappeared.

0 Kudos