Unable to Delete or Unlicense User on Tableau Server Error "An unexpected error occurred"

Published: 16 May 2022
Last Modified Date: 12 Sep 2022


Although the user does not own any content, it is not possible to remove, reassign, or unlicense the user from Tableau Server and the following error occurs:

An unexpected error occurred.


  • Tableau Server


Option 1

Reset the search server to a clean slate.

Run the following tsm command:
tsm maintenance reset-searchserver 

Please note that this command will require that Tableau Server is stopped prior to running the command.  A simple reindex-search will not resolve this issue.

Option 2

Set the user to be a Server Administrator on all sites and then delete the user.
  1. Log on to Tableau Server as a Server Administrator.
  2. Select All Sites from the left menu pane.
  3. Select Users.
  4. Mark the checkbox of the user you want to delete.
  5. Select Site Membership from Actions. 
  6. Select the checkbox Selected users are Server Administrators and Save.
  7. Delete the user.


 Search index is corrupt.

Additional Information

When the issue occurs an error similar to the following is seen in the Vizportal log:

ERROR com.tableausoftware.api.webclient.util.BatchedActionExecutor - Exception raised by call target for key [7]: System User cannot be deleted because it still has associated site users (errorCode=10040)
com.tableausoftware.domain.exceptions.ForbiddenOperationException: System User cannot be deleted because it still has associated site users (errorCode=10040).

View, Manage, or Remove Users

Did this article resolve the issue?