# GatherLogs

SUM provides a tool that collects all log files in to one file. If you are troubleshooting an issue, run `gatherlogs`. The script is available in the same directory that holds SUM.

NOTE:

Always shut down SUM before running the GatherLogs utility.

If the GatherLogs utility is executed while SUM is running, it might report an error such as CNodeData table is not present. Databases do not flush all the transactions into the file for performance reasons. The transactions are in the cache of the process and the content is flushed onto the file system based on several criteria. However, all the tables are available to SUM for all operations from its cache. When SUM is shut down, the contents of the cache will be flushed to the file system. Therefore, the GatherLogs utility executed while SUM is running will not be able to access all the data/tables. As a result, it might report the error.

When using the `/debuglogdir` (Windows) or `--debuglogdir` (Linux) parameter to launch SUM, also provide the parameter when you launch the `gatherlogs` script so that it can collect the log files from `debug log directory`.