Easy Fix if Users Can’t Logon to Citrix Xen App

I recently came across a Citrix XenApp 6.0 server that wasn’t letting people logon to the Citrix XenApp site.  Instead they got a large box of text at the bottom saying something about the user not able to be logged in, even when they correctly entered their credentials.  A check of the server’s Event Log  revealed things like this:

The Citrix Independent Management Architecture service terminated unexpectedly.
…and this…
Faulting application imasrv.exe
…and this…
The server running Citrix XenApp failed to connect to the data store. The database is down or there is a network failure. Error: IMA_RESULT_DBCONNECT_FAILURE

To fix it I needed to recreate the local host cache from the farm’s data store. If you are having the same problem, you can do that by doing this:

  1. Stop the Independent Management Architecture service.
  2. Open an administrator-level command prompt.
  3. Run this at the prompt: dsmaint recreatelhc
  4. Start the Independent Management Architecture service.

That’s all you have to do.  The important thing to realize here is that this is also just good practice to do occasionally anyway, so if you did this to fix your server, then make a note somewhere to run it again from time to time, even when things are running smoothly – to keep them that way!

Steve