VMware Cloud Community
Matt_B1
Enthusiast
Enthusiast
Jump to solution

How do I remove a non-existent target ESX server from the vMA list?

I added a couple ESX servers to vMA using "sudo vifp addserver <hostname>". These servers were retired before removing them from vMA. Since they are not online,I get the below message when doing "sudo vifp removeserver <hostname>". How can I remove them from the vMA list of targets? Thanks.

Error: Failed to connect. Please make sure the server is up and is of supported version.

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
lamw
Community Manager
Community Manager
Jump to solution

If you're using the latest version of vMA 4.0, you should be able to do the following:

sudo vifp removeserver <server> --force

When it prompts for password, just type whatever, it should just forcefully remove the host from management.

You could also take a look at the vMA configuration file that keeps track of the hosts under management and clear out the old entries:

/etc/vmware/viconfig/viconfig.xml

/home/vi-admin/.vmware/credstore/vicredentials.xml

Give that a try and see if it helps, it's always best practice to remove from host prior to decommission but generally, option 1 will work from what I've seen.

=========================================================================

William Lam

VMware vExpert 2009,2010

VMware scripts and resources at:

Twitter: @lamw

Getting Started with the vMA (tips/tricks)

Getting Started with the vSphere SDK for Perl

VMware Code Central - Scripts/Sample code for Developers and Administrators

VMware Developer Community

If you find this information useful, please award points for "correct" or "helpful".

View solution in original post

0 Kudos
3 Replies
lamw
Community Manager
Community Manager
Jump to solution

If you're using the latest version of vMA 4.0, you should be able to do the following:

sudo vifp removeserver <server> --force

When it prompts for password, just type whatever, it should just forcefully remove the host from management.

You could also take a look at the vMA configuration file that keeps track of the hosts under management and clear out the old entries:

/etc/vmware/viconfig/viconfig.xml

/home/vi-admin/.vmware/credstore/vicredentials.xml

Give that a try and see if it helps, it's always best practice to remove from host prior to decommission but generally, option 1 will work from what I've seen.

=========================================================================

William Lam

VMware vExpert 2009,2010

VMware scripts and resources at:

Twitter: @lamw

Getting Started with the vMA (tips/tricks)

Getting Started with the vSphere SDK for Perl

VMware Code Central - Scripts/Sample code for Developers and Administrators

VMware Developer Community

If you find this information useful, please award points for "correct" or "helpful".

0 Kudos
Matt_B1
Enthusiast
Enthusiast
Jump to solution

The --force argument worked, thanks! I just noticed that futher down in the vMA guide under Target Management commands.

0 Kudos
estereterete
Enthusiast
Enthusiast
Jump to solution

When I tried

                  vifp removeserver OLD-SERVER  --force

I got, as entries in DNS were already deleted:

                  Error: Unable to resolve hostname.

So I wrote an entry in /etc/hosts pointnig old-server to a real ESX server.

0 Kudos