服务器管理 > Workflow and SCM Projects > Deleting Projects and Archives From Database
  
Deleting Projects and Archives From Database
To delete specified projects that are no longer in use from the database, use the si deleteproject command. Deleting a project from the database deletes the project itself and its history. Deleting a project from the database also deletes all of the member archives for members in that project. However, shared projects and archives are retained in the database. You can also specify to delete only specified archives rather than projects by using the si deletearchive command.
Deleting projects and archives is a multi-phase process referred to as delete session. Delete session is identical for both si deleteproject and si deletearchive, but only one type of session may be in progress for the same database and server. At any phase before the final commit of the delete, you can roll back the operation and end the delete session with the projects and archives intact.
* 
Once the delete session has been completed, you cannot roll back the changes to the database. You must restore the project.
As part of the delete session, projects and archives marked for removal from the database are archived (if using the --dump subcommand) and can later be restored by migrating them back into the database. However, broken linkages between deleted projects and those projects retained in the repository are not restored.
Key Considerations
Both si deleteproject and si deletearchive commands require either the AdminServer or DebugServer ACL permission. The deleteproject and deletearchive permissions are required to delete projects and their member archives.
Only one type of delete session can be in process at one time (either si deleteproject or si deletearchive). If the command type does not match the type of an existing session, an error is returned.
The unit of delete is an entire member archive or a project and all its variants. There is no support for purging only member revisions, only some variants, or for purging revisions or checkpoints based on date.
References by name to deleted objects are not modified by the delete. These references include change package entries, ACLs, policies, trigger registrations, pending operations, lock origination, and Sandbox registries.
Restoring deleted objects does not re-establish links between those objects and objects not deleted. Links are permanently broken by a delete operation.
You cannot delete a project if a checkpoint is in progress on that project.
Logs of the delete session are provided as part of the si migrate command functionality. For more information, see the Database Repository Migrator Guide.
Before deleting projects and archives, consult the key considerations for restoring them.
The si deletearchive command is intended for global clean-up of files, (not for removing individual archives), because links may exist between that archive another objects in the database. For more information, refer to documentation on the --nodeleteIfInUse option in the subsequent sections.
Delete Session Phases
Viewing Repository Post-Delete
To delete projects from the database using the CLI
To delete archives from the database using the CLI