Please enable JavaScript to view this site.

CopiaFacts Reference

Trace File Writer

CFTRCSERVICE /install] | /uninstall
NET START CFTRCSERVICE

For sites where a large amount of trace data is produced, this service can reduce the overhead of tracing on the COPIAFACTS engine, by efficiently writing data sent from the process, communicated using TCP/IP.  The service receives trace data from the COPIAFACTS process only, including from its DLL libraries, and normally writes it to a local trace file on the same machine.  It is intended that CFTRCSERVICE should be left running at all times that COPIAFACTS is running.

FFTRACE is used to select trace options for the COPIAFACTS program and its DLLs, but does not need to be left running to write the trace files. In this respect FFTRACE is used in the same way as it is when the applications run as services themselves.  To view the trace files, use TRCVIEW.

To use CFTRCSERVICE to collect COPIAFACTS and FFTRACE output from the COPIAFACTS process for a node, you require:

The service to be installed and configured as described below/

COPIAFACTS to be started with its node name on the command line.

"Use CFTRCSERVICE" to be enabled in the options menu of FFTRACE.  This enables both TRx and FTx trace output for the node to be sent to CFTRCSERVICE.

In most cases you will want to install CFTRCSERVICE on a node or nodes other than that on which the COPIAFACTS processes are running.  Installing the service on the same node as the COPIAFACTS process is less advantageous, because the multiple threads used in the service process will steal resources from the engine.

Installation

To make use of this service, first install it by running the application with the /install command-line parameter.  Then add the following $environment variable definitions to FAXFACTS.CFG.  Each such command can take a node name parameter to specify the applicable CopiaFacts node. The variables other than the first two are optional.

TRC_TRACEFOLDER[Required] The pathname of a folder into which the TRx and FTx trace files are to be saved by CFTRCSERVICE.  This value overrides the folder specified by the FFTRC environment variable, but if you also run applications other than COPIAFACTS on the same machine, which will also create trace files using FFTRACE, you must choose a different folder for CFTRCSERVICE so that it does not attempt to write to the same .FTx trace file.
TRC_INDEX[Required] An index (base 1) must be supplied for each COPIAFACTS node. This must be specified on a $environment command also specifying the nodename, not one with * as its node parameter.
TRC_SERVICEIPThe IP address of the machine on which the service is running.  If omitted the IP address of the first network adapter is used.  This value allows selection of the network adapter when multiple adapters are in use.
TRC_LOCALIPThe IP address of the machine running the node's COPIAFACTS instance. If omitted the IP address of the first network adapter is used. This value allows selection of the network adapter when multiple adapters are in use.
TRC_SERVICEPORTThe port to be used by the service. If omitted, the service uses port 54300 and a sequentially following port for each node. The TRC_INDEX value is added to the service port to form the local port number used to send messages from the node to the service.
TRC_SWAPTIMEOUTThe interval in seconds after which a trace buffer is written to disk while the alternate buffer is being filled. Default 10 seconds.
TRC_COUNTLIMITThe number of trace lines processed after which a trace buffer is written to disk while the alternate buffer is being filled. Default 400 trace lines.

We recommend that the trace file is written to a local folder on the same machine as the service.  If you run multiple CopiaFacts nodes, the service can collect data from more than one node.  Note that currently, when trace files are automatically picked up to be 'sent to Copia' with a notification, trace files in the specified folder may not be found.

If you use a firewall, it must be configured to allow communication on the specified ports between the nodes in use.

If you need to change the above variables in FAXFACTS.CFG, both the service and all affected nodes should be stopped while you are making the changes.

Using CFTRCSERVICE with COPIAFACTS

Writing to CFTRCSERVICE also requires that COPIAFACTS is started with its node name on the command line. Having the node name on the command line is also a requirement when the engine is to be run as a service.

You should use FFTRACE In the normal way to select required tracing for COPIAFACTS DLL libraries, such as CF8EMAIL, CF8IMAGE, CF8DATABASE or CF8SUPPORT.  In FFTRACE, you must also enable "Use CFTRCSERVICE" in the options menu. This menu item will only be visible if the active node name has a TRC_INDEX value in FAXFACTS.CFG (see above).

Changes to the trace options in the File/Applications dialog are effective as soon as you close the dialog and the application or DLL next checks them.  However if you enable or disable 'Use CFTRCSERVICE' you must restart COPIAFACTS to effect the change.

Configuration Examples

Minimum configuration (one node, all on one machine):

$environment * TRC_TRACEFOLDER C:\FAXTEMP

$environment M1 TRC_INDEX 1

Multiple nodes, separate CFTRCSERVICE node (M1).

$environment * TRC_TRACEFOLDER C:\FAXTEMP

$environment * TRC_SERVICEIP 192.168.1.21

$environment M2 TRC_INDEX 2

$environment M3 TRC_INDEX 3

$environment M4 TRC_INDEX 4

Multiple nodes, two separate CFTRCSERVICE nodes (M10, M20)

$environment * TRC_TRACEFOLDER C:\FAXTEMP

$environment M10 TRC_SERVICEIP 192.168.1.10

$environment M11 TRC_SERVICEIP 192.168.1.10

$environment M11 TRC_INDEX 1

$environment M12 TRC_SERVICEIP 192.168.1.10

$environment M12 TRC_INDEX 2

$environment M20 TRC_SERVICEIP 192.168.1.20

$environment M21 TRC_SERVICEIP 192.168.1.20

$environment M21 TRC_INDEX 3

$environment M22 TRC_SERVICEIP 192.168.1.20

$environment M22 TRC_INDEX 4