Content Server Manual / Version 2310
Table Of Contents
With the destroy
tool you can delete resources from the repository.
Warning
By means of the destroy tool, you remove the indicated objects permanently and irrevocably. Use with great care. This tool is typically needed to recover from error conditions only.
usage: cm destroy -u <user> <other options> [ -f ] [ -R ] [ -l <limit> ] [ <id1>... | -I <id1>... | -U <uuid1>... | -t <path1>... | -cq <query1>... | -vq <query1>... ] available options: -cq,--contentquery <query> query/queries to select contents -d,--domain <domain name> domain for login (default=<builtin>) -f,--force force destruction of folders with children -I,--id <id> id(s) to select content objects -l,--limit <limit> limits the number of content objects to select, negative for unlimited which is also the default -p,--password <password> password for login -R,--recyclebin include contents from recycle bin -t,--path <path> path(s) to select content objects -u,--user <user name> user for login (required) -U,--uuid <uuid> UUID(s) to select contents -url <ior url> url to connect to -v,--verbose enables verbose output -vq,--versionquery <query> query/queries to select versions
The options have the following meaning:
Parameter | Description |
---|---|
-f | Force the destruction of non-empty folders, which is normally forbidden due to safety considerations |
-cq <query> |
Object Selection
Content Query to locate contents. For versions see -vq .
Parameter can be used multiple times. Results will be linked by OR.
|
-vq <query> |
Object Selection
Version Query to locate versions. For contents see -cq .
Parameter can be used multiple times. Results will be linked by OR.
|
-R |
Object Selection
Add contents from recycle bin. Could also be done via -cq .
|
-I <id> | Object Selection Select objects via explicit id. This is an alternative if you want to mix explicit ids with for example content queries. Parameter can be used multiple times. Results will be linked by OR. |
-U <uuid> | Object Selection Select contents via UUID. This is an alternative if you want to mix UUIDs with for example content queries. Parameter can be used multiple times. Results will be linked by OR. |
-t <path> | Object Selection Path of a resource to be destroyed. Parameter can be used multiple times. Results will be linked by OR. |
<ids> |
Object Selection
IDs of objects to be destroyed. If mixing with other content selection parameters, it is recommended
to explicitly use the parameter -I
Parameter can be used multiple times. Results will be linked by OR.
|
-l <limit> | Object Selection Limit the number of selected objects to the given value. Default is unlimited. |
Table 3.44. Options of destroy
Note
For information about the UAPI query syntax see Section 5.7, “Query Service” in Unified API Developer Manual.
In order to keep Content Management Server and
Master Live Server in sync, destroy
tries to withdraw the
resources from the Master Live Server before it destroys them on a
Content Management Server. To avoid dead links on the
Master Live Server, all referencing content items are also
withdrawn. On the Content Management Server however, the
referencing content items are not destroyed, and thus dead links may arise.
Warning
This tool might affect your live site.
As stated above, the destroy tool tries to withdraw the content that should be deleted and all content that recursively links to this content! That is, if the content to be deleted is linked by other content, more content might be withdrawn from your live site than you expected.
So when you use the tool, be sure that only content you want to remove from the live site links to the content you want to destroy and keep in mind that destroy is an emergency tool.
destroy
is an emergency tool. The normal way to get rid of resources without causing dead links
is to move them to trash and have them deleted by the cleaners (see
Section 3.13.2.3, “Cleaners”).
Concerning users and groups, destroy
is not an LDAP tool. If you apply destroy
to
LDAP users, the users will only be logged out and synchronized with the LDAP
repository on the next access. If you apply destroy
to
LDAP groups, the groups will lose their roles and be synchronized with the LDAP
repository on the next access.
Unless the users have been deleted from the LDAP server, they will not disappear
from the CoreMedia CMS. If you delete users
and groups on the LDAP server, the CoreMedia CMS notices this
automatically. So you don't need destroy
in the regular case but only to expedite the
synchronization process and remove special privileges immediately.