When you need to free up user licenses you should start by running the housekeeping tasks "Clear expired tokens" and "Clear deleted LDAP users".
The "Clear expired tokens" Task
This task will remove expired tokens from the repository, can be found on the task list (in the example below on page 2);
The task number will probably not match, but you should find it near the end of the list of tasks.
The "Clear deleted LDAP users" Task
When users are deleted from an external LDAP identity sources, the user deletion may result in licenses being allocated to users that cannot be accessed in the management console.
This housekeeping task can be used to remove tokens that are assigned to users that have been deleted from LDAP.
From the management console select “Administration | Tasks”, left click on the context menu of the task “Clear deleted LDAP users”, then select “Run”;
Once executed the task helps free up licenses by removing the deleted LDAP users.
Identifying License Usage Details
License details may be obtained from the Management Console either through the "Home" menu-bar option, by navigating to "Configuration | Licenses", or by running the report “Users use License”.
If you can't find the template "Users use License", first check the other pages (the report is usually found on one of the last pages), but if the report still cannot be found you will need to download the file from the support site.