This utility can be used to start and stop tracing (logging) of specified sessions on the content server. The
logging must be configured with the log facility trace
. All sessions traced by
tracesession
will log in the same file. See the [Operations Basics Manual] for details on the logging of CoreMedia CMS.
Caution | |
---|---|
Use this utility with care! |
usage: cm tracesession -u <user> [other options] -s <session> [-q] tracesession -u <user> [other options] -t <type> [-q] available options: -d,--domain <domain name> domain for login (default=<builtin>) -p,--password <password> password for login -q quit tracing -s,--session <session> ID of the session to be traced -t,--type <type> type of the sessions to be traced (one of: unknown, editor, generator, publisher,replicator, watchdog, importer, utility, uapi, all) -u,--user <user name> user for login (required) -url <ior url> url to connect to -v,--verbose enables verbose output
The options have the following meaning:
Parameter | Description |
---|---|
-q
| Stop tracing the specified sessions |
-s
| Specify a session by its ID. You can obtain the IDs of all sessions with the
sessions tool (see Section 3.14.1.10, “Sessions”). |
-t
| Specify the sessions to be traced by their common type. Run the
sessions tool with the -v option to find out about the
types of the open sessions. The legal values for this parameter (see usage) are
obvious shortcuts for those types. There are two special values,
unknown and all . all denotes all
sessions, unknown denotes all sessions but those of the concrete type
values. |
Table 3.32. Options of tracesession
CoreMedia recommends that you separate the tracesession
logging from the standard logging (which
usually goes to capserver.log
), because a mixture of both looks pretty cluttered and is hard to
read. Just configure an additional log action in contentserver.properties
, for example
# write all trace output to a log file log.action.2.class=FileAction log.action.2.selectors=trace:debug log.action.2.initArgs=\ file=var/logs/capserver-trace.log,fileSize=4000,writeOps=1000
Now you can start tracesession
, for example a user's editor session which you found with the
sessions
tool:
> cm tracesession -u admin -p admin -s coremedia:///cap/session/14
Traces started by ID and by type are independent of each other. That is, you cannot stop tracing the above session with the following command, although it is an editor session:
> cm tracesession -u admin -p admin -t editor -q
You can only stop it by ID, just like you started it.