TIBCO Spotfire® Server and Environment - Installation and Administration

Customizing the service logging configuration

Log4Net.config specifies the logs and logging levels for the Web Player service and Automation Services. To edit this configuration, you must export its contents to an XML file, edit it, import it, and then apply the configuration.

About this task

This task walks you through editing the configuration for the Web Player service. You can also edit the configuration for Automation Services, which includes an additional configuration file.
Note: For the TERR service and Spotfire Service for Python, JMX is the only way to capture logs. For more information, see the following.

Before you begin

You must have administrative credentials for Spotfire Server.

Procedure

  1. On the computer running Spotfire Server, open a command line as an administrator and change the directory to the path of the config.bat file (config.sh on Linux).
    The default file path is <installation dir>/tomcat/spotfire-bin.
  2. Export the configuration using export-service-conf and passing commands for the service to customize.
    For example:
    config export-service-config --tool-password=mypassword
     --capability=WEB_PLAYER --deployment-area=Production c:\temp\config
    • Provide the appropriate password for the configuration tool.
    • The deployment area is usually Production. Check the administration interface page Nodes & Services if you are not sure.
    • If the directory where you want to write the configuration files already exists, you can overwrite the contents by using the --force flag.
    The configuration is exported to the specified directory, creating a root subdirectory that contains the following configuration files.
    • log4net.config
    • Spotfire.Dxp.Worker.Core.config
    • Spotfire.Dxp.Worker.Host.exe.config
    • Spotfire.Dxp.Worker.Web.config
  3. Browse to the directory, and then, using a text editor, open and edit the configuration file log4net.config.
    In the configuration file, each potential log file is specified by an <appender> section. Edit each section for the logs to create. For more information about the logs this file can create, see Web Player service logs.
    1. Set the logging level.
    2. Specify the file path to write the log.
    3. Save and close the configuration file.
  4. Optional: Customize the user and session statistics, and the performance counter logging, specified in the file Spotfire.Dxp.Worker.Web.config, which is also exported and written to the root subdirectory.
    You can customize the performance counters at both the INFO and the DEBUG levels. See Service log levels for more information.
  5. Return to the command line and import the custom configuration using import-service-config, passing in the configuration name, the tools password, and the path for the configuration.
    For example:
    config import-service-config --tool-password=mypassword 
    --config-name=SampleConfig c:\temp\config
    The configuration is successfully imported.
  6. Set the custom configuration using set-service-config, passing in the service ID and the configuration name.
    For example:
    config set-service-config --tool-password=mypassword 
    --service-id="VALUE" --config-name=SampleConfig
    Tip: Use the list-services command to get the service ID. In some cases, you must enclose the service ID in double quotation marks.
    A warning is displayed indicating that setting a new service configuration causes all running instances of the service to restart, and you must indicate whether you want to continue. If you press Y, the service restarts and the new configuration is set.

Results

The configuration setting for the Web Player service is displayed in Nodes & Services, and the log files should be written as specified.