VCSA 6.5 – Greyed Out Migration Option (BAW2)

Whilst performing some Storage vMotion activities recently, I discovered an issue with 3 virtual machines in my environment where they were unable to perform a vMotion of any type due to the Migrate option being greyed out in vCenter.  I believe that this actually occurred because the 3 virtual machines in question had been in the middle of a Storage vMotion activity when my vCenter server was rebooted.

As you may already know, when a vMotion activity is performed, a table in the vCenter DB is updated to identify that the VM cannot perform other activities of the same type.  This DB entry is what disables the Migrate menu item.  The DB entry is subsequently removed when the vMotion activity is completed.  As the vCenter server was rebooted during one of these processes, the three virtual machines in question did not have their entries removed from the database table.

Here is a method that I used to correct this issue, it is based on a KB article by VMware (https://kb.vmware.com/s/article/2008957) but their method of finding the VM id can be hard to figure out and therefore I used a simple piece of PowerCLI to find the same information.  Please note that if you perform this process, you do it at your own peril, I took a snapshot of the whole virtual machine before beginning this process and if you access the KB article from VMware, they advise taking a backup as well… here’s what I did:

  • I checked in vCenter to understand the name of the virtual machine with the issue, and made a note of the name
  • I started up PowerCLI connected to the vCenter server and ran the following command:
(get-vm 'servername*').extensiondata.Moref.Value
  • This then returned the moref value of the virtual machine, which will be utilised later (please note that the whole moref name will be required, including the vm-)
  • We now need to putty onto the vCenter appliance using the root credentials
  • Once logged on, type:
shell
  • This will take you to a normal vCenter shell command prompt
  • You should then type:
service vmware-vpxd stop
  • This will stop the virtualcenter service
  • At this point, as I was dealing with three virtual machines, I found it easier to just start up psql to the vpostgres SQL instance, to allow the subsequent commands to be run multiple times (one for each VM).
  • To start up psql type:
/opt/vmware/vpostgres/current/bin/psql -d VCDB -U postgres
  • You will now be presented with a new command prompt, which is actually the psql command prompt
  • To confirm whether there are any methods that are disabled (any entries in the DB stopping migrations occurring), type:
SELECT * FROM VPX_DISABLED_METHODS WHERE ENTITY_MO_ID_VAL = 'moref id collected earlier';
  • Please note that in the previous command there are ‘ marks around the moref entry plus a ; at the end of the line.
  • This should now confirm that there is an entry for the disabled methods, if there is no entry shown, then the moref value you have could be incorrect or the entry is not disabled as first thought… it would be best at this point to contact VMware support for further assistance.
  • With this information confirmed, we can now looked to delete the entry from the database using the following command:
DELETE * FROM VPX_DISABLED_METHODS WHERE ENTITY_MO_ID_VAL = 'moref id collected earlier';
  • At this point you should receive confirmation that 1 entry has been deleted from the database.
  • Type:  \q   to exit the psql instance.
  • Although, you could just start up the vpxd server again, my recommendation would be to log onto the vCenter server management page (https://servename:5480/) and perform a reboot through that interface.
  • If everything has gone well, then the migration option should be available again within vCenter and you can now migrate the virtual machines as required.

 

Blog-a-Week 2018 Posting (BAW):

In previous years, I have had periods throughout the year where I have been unable to post an entry to my blog.  During 2018, my aim is to post a blog entry each week of the year.  I’m hoping that the blog entries will all be useful bits of information or items that I’ve been working on recently but if the standard of the entries drops, I apologise now, as this could have been a busy week and I wasn’t able to put in as much time as I would have liked into the post

About the Author

Dinger

I have been in IT for the past 15 years and using virtualisation technologies for around the past 8 years. I started, as quite a lot of people do, working with PCs after playing with such iconic systems like the ZX81, ZX Spectrum and then progressing through 386s, 486s, Pentiums etc. After being headhunted at sixth form to work for a small company based around Hertfordshire, UK. I began working with small businesses and gaining a lot of hardware experience. Three years later, after helping to increase the size of the business, I needed to gain exposure to a larger environment to progress my own career. I joined a large manufacturing company around Electronic Test and Measurement which progressed my skills onto more PC work, hardware work and then onto Server Operating Systems. I progressed again onto a consultancy company based in Reading, UK. Initially working as an engineer performing hardware / software installations for larger companies contracted out to the consultancy company, I moved up into a Consultant position continuing my travel across the UK assisting and providing solutions to companies. I finally moved on again to my current position, working back in Hertfordshire, UK. Again working for a large manufacturing company, this time with over 50,000 users worldwide. I am responsible for the datacenter hardware, the storage environment, the vmware environment and also implementing their new Citrix XenApp farm. My days are busy but also productive, its a friendly environment and in my four years of being with the company, I have seen many changes in technology and infrastructure in use within the company. About the site I started this site as I had been thinking of having more of a presence on the web for a while. On a daily basis, I perform tasks and use tools that others may not use or may not think to do and therefore I thought that I would share some of these experiences and tips with others to help with their day to day work. Currently, my main focus of work is around VMware and Veeam Backup & Replication but hopefully as my tasks progress, I’ll be able to share useful bits of information about other areas of IT as well.

Leave a Reply

Your email address will not be published. Required fields are marked *