Use different tools depending on whether you are deleting a user from a hosted domain or a non-hosted domain:
There is no undelete command.
Once users in hosted domains are deleted using Delegated Administrator, they must be purged and re-added from scratch. The user name can not be reused until the purge happens.
For non-hosted domains, see For Non-Hosted Domains Only: Undeleting Users Marked for Deletion but Not Purged.
You can mark users for deletion with either Delegated Administrator interface. However you can not purge users from LDAP with Delegated Administrator Console. You must use the Delegated Administrator Utility for that. The following task lists the steps for deleting a user from LDAP. The user is not actually removed from LDAP until the last step is complete.
Mark a user entry for deletion.
For Delegated Administrator Console: Select the users to delete in the User List page and click Delete.
For Delegated Administrator Utility: Use the commadmin user delete command. For example:
commadmin user delete -D chris -n siroe.com -w bolton -l jsmith
In both cases the icsStatus attribute in the user LDAP entry is changed from active to deleted.
Use the Calendar Server Utility csclean to remove all calendars belonging to all deleted users in one or all domains, as shown in the following example:
csclean clean “*”
Or to remove calendars belonging to all deleted users in one domain, specify the actual domain, as shown in the following example: csclean clean sesta.com
If you inadvertently purge the users from LDAP before deleting the users' calendars, you can remove them later using the cscal utility, as described in Managing User Calendars.
Purge the domain of all users marked for deletion, using Delegated Administrator Utility command commadmin domain purge.
commadmin domain purge -D chris -d sesta.com -n siroe.com -w bolton
In this example, all users in sesta.com that are marked as deleted will be purged, that is, permanently removed.
Run this utility manually from time to time to clean up your LDAP directory. For more information about this command, see the Sun Java System Communications Services 6 2005Q4 Delegated Administrator Guide.
To remove the specified user’s LDAP entry and the user’s default calendar, use the Calendar Server utility csuser with the delete command.
For example, to delete the LDAP entry and the default calendar for user jsmith use the following command:
csuser delete jsmith
If you wish to remove the other calendars belonging to this user, you must use cscal as described in Managing User Calendars.
For a non-hosted domain, to undelete users marked for deletion but not yet purged, it is necessary to reset the users' icsStatus attributes to active. You can achieve this by directly changing the LDAP entries (using ldapmodify), or by using the Calendar Server Utility csattribute.
However, in a non-hosted domain, once the user is purged, you can only recover the LDAP server information by restoring it from a backup.