What:
When you deploy linked clone desktops pools with VMware Horizon, the information for these machines are stored in the ADAM database and not with the vCenter database. The ADAM database is described in the following VMware KB:
“The Active Directory Application Mode (ADAM) database is used as a replicated storage facility for vCenter Servers running in Linked mode.
ADAM is used to store:
• The list of vCenter instances participating in the group. For a standalone instance, this still exists, but there is only one entry in the list.
• The definitions of authorization Roles. These are common in the group and are no longer stored in the vCenter SQL database.
• The definitions of available licenses and license assignments for the Linked Mode group. One-stop shopping for checking on and updating license usage across all vCenters in the group.
ADAM is required to run vCenter Server in Linked Mode. If you do not want to run vCenter Server in Linked Mode, close ADAM ports, RPC ports and port 389 and port 636 in the firewall. These ports are only used by the local VMware VirtualCenter Management Webservices and VMware VirtualCenter Server services.
Note: ADAM is also utilized by standalone vCenter Servers for storing licensing information.”
Sometimes will be necessary to connect to the ADAM database for troubleshooting, when a pool or VM is stuck in View Administrator inventory and cannot be deleted, this pool or VM need to be deleted from the ADAM database.
How:
In my case, I have VMware Horizon connection server running on a Windows 2012 R2, the one I am using for the creation of the virtual machines in my VDI tested environment.
- Go to Start> AdministrativeTools > ADSI Edit
- From the console window, right-click ADSI Edit and click Connect to…
- In the new window, type any name in Name field: ADAM Database, for example.
- In Connection Point, Select Select or type a Distinguished Name or Naming Context
- In the field below, type: dc=vdi,dc=vmware,dc=int
- In computer, select Select or type a domain or server: (Server | Domain [:port])
- In the field below, type [localhost] or the server name (with domain), in my case is VDIConnection.vdi.local
- Click OK to connect, if the connection cannot be established, verify the user credentials. If the connection is OK, skip to number 11.
- Specify credentials. Here I am using the domain controller credentials I created for the VDI environment.
- Enter again credential in the new window.
- Right-click ADAM Database [Server name] >New > Query…
- In the new window, type any name in Name field (Ex. Test), in Root of Search click Browse…
- Select Server Organizational Unit and click OK
- In Query Stringfield, type (&(objectClass=pae-VM)(pae-displayname=VM)), where VM is the name of the virtual machine you want to find and delete. You can use * to match multiple virtual machines. In my case is VM074, click OK to create the query.
- Click in the new query created on the left panel and delete the record.
- If multiples virtual machines are in the query (wildcard *), get the IDs in CN=<ID>, then locate the OU=SERVERS and match the records you want to delete in the right panel.
By connecting to the ADAM database on the View Connection Server, we were able to delete the VM(s) stuck in the View Administrator inventory.
Hi Juhan,
Recomposer task got stuck in Horizon Administrator, If i try to delete task still task appears in the task list.
The machines which have problem i already deleted from database as mentioned above.
Do you know how to delete task which got stuck ?
Hi Sha, if you already delete the machines from the ADAM database and the issue persists, you need to do some extra workaround in the main database, the one from the Composer, since it might be corrupted. I had to do this once but I don't remember how at this moment, it is not a pleasant process.
Hi Juan,
Thanks for your prompt reply!
I logged in to database but didn't find database for task.
Do you have any idea, if i can create new Desktop Pool and disabled existing desktop pool, because Vms status are good available and connected without any problem but the thing is that i can't recompose image because following message appears while refresh deskstop pool or recompose:
""One or more of the selected virtual machines already has a pending View Composer operation. This new operation cannot be submitted until the pending operation is completed or canceled.""
https://communities.vmware.com/message/2897339#2897339
Regards
Sha
Sha, that seems to be a different problem from the one I described in this post. I thought you were talking about this. That problem you have, I am not sure about the solution at this moment. I haven't faced that issue.
The solution I see related to your issue is in this KB https://kb.vmware.com/s/article/2016091
No problem. thank you very much!