Logging
Capture Edge can write logs to three destinations:
- Log files (recommended for troubleshooting and support)
- Console (useful when you already aggregate stdout/stderr, e.g., Docker)
- Capture portal (realtime diagnostics view - no history)
File logging should be enabled in virtually all cases. If disk writes are a concern, move logs to separate storage using CAPTURE_LOGS_DIR.
Logging settings
Older versions only read Debug mode and Log to file, see Older Capture Edge versions.
Logging page in the configuration
Cloud3.10.0+ Logging is set in the gateway configuration, on the Logging page of the configuration editor. The settings apply to every Capture service on the gateway (CloudManager, Collector, Syncer and Analytics).
Console
- Minimum level: the lowest level written to the console. Platform default uses the platform default.
File
- Enabled: on by default. See File logging off before turning it off.
- Minimum level: the lowest level written to the log files.
Informationby default. - Max file size, in MB: see File size limit.
- Retained files and Retained error files: see Retention limits.
- Separate error log: see Disable separate error files.
An empty setting uses the default. Changes take effect when the services restart.
Environment variable, then configuration, then default
Every setting on the Logging page can also be set on the gateway itself with an environment variable. For every setting, Capture Edge uses the first of:
- The environment variable on the gateway.
- The configuration (the Logging page).
- The default.
An environment variable wins over the configuration on that gateway. Use it for a setting that should differ on one gateway, or per service in a multi-container setup. An invalid value (for example an unknown level) is ignored with a warning at startup, and the next source is used.
The defaults:
- Console: the platform default:
Informationon Linux, in Docker or with a debugger attached, errors only on a Windows service. - File logging: enabled, at
Information, with the size and retention limits below.
To see which value each service uses and where it comes from, open the Log settings on the CloudManager Logs page.
Older Capture Edge versions
The Logging page replaces the Debug mode and Log to file settings. A gateway on an older version still reads those two, so they are derived from the Logging page every time the configuration is saved:
- Debug mode is on when the console or the enabled log file is at
DebugorVerbose. - Log to file is on when file logging is enabled at a level below
Fatal.
An older version has only one level for everything, so it runs at Debug or Information. A level above Information,
for example a console at Error, runs at Information there.
When a gateway is updated, its Logging settings are filled in from its current Debug mode and Log to file:
the log file keeps its level, and a gateway with Log to file off gets a log file at Fatal, which is what it wrote
before. The console goes to the platform default, so on Linux and Docker a gateway in debug mode logs Information to
the console instead of Debug, while its log file keeps Debug. With Debug mode on and Log to file off, the
console gets Debug, since that is where the debug lines went.
Log destinations
Log files (recommended)
File logging is the primary method for troubleshooting because it provides persistent history and can be collected and shared.
How to enable
- File logging is on by default.
- Edge2.4.0+upcoming On the Logging page, under File, turn on Enabled, or set
CAPTURE_LOG_FILE_ENABLED=trueon the gateway. - Older versions: in the Source configuration, go to General and enable Log to file.
File logging off
Edge2.4.0+upcoming With file logging off, no log file is written at all. Crashes and startup failures leave no trace on the gateway, and diagnostics packages and the CloudManager Logs page have no history.
To keep only crashes, leave file logging on and set File › Minimum level to Fatal.
Before 2.4.0, fatal errors were still written to disk with Log to file disabled, even if debug logging was enabled.
Console
Console logging is useful when other tools make it easy to follow logs (for example Docker, systemd journal, Kubernetes).
Defaults (platform default)
- Linux, Docker, or with a debugger attached:
Informationand above go to the console. - Windows service: only errors and fatal errors go to the console (performance reasons).
How to change
- Edge2.4.0+upcoming Set Console › Minimum level on the Logging page, or
CAPTURE_LOG_CONSOLE_LEVELon the gateway, for exampleCAPTURE_LOG_CONSOLE_LEVEL=Informationon Windows orCAPTURE_LOG_CONSOLE_LEVEL=Erroron Linux. - Older versions:
CAPTURE_LOG_TO_CONSOLE=truesends all logs to the console, and Edge2.3.1+CAPTURE_LOG_TO_CONSOLE=falselimits it to errors and fatal errors.
CAPTURE_LOG_TO_CONSOLE is deprecatedEdge2.4.0+upcoming CAPTURE_LOG_TO_CONSOLE is still read, with a warning at startup. false limits the
console to errors and fatal errors; true uses the configured Console › Minimum level, or Information when none is
set. CAPTURE_LOG_CONSOLE_LEVEL wins over it. Use CAPTURE_LOG_CONSOLE_LEVEL instead.
Console logging works best when you already have centralized log collection for stdout/stderr.
Edge2.4.0+upcoming On a Linux install without Docker, the diagnostics package includes the console output from the systemd journal when file logging is off, or when the log file is at a higher level than the console, so turning file logging off there does not leave support without logs. In Docker and on Windows it does not, so keep file logging on there.
Capture portal (realtime diagnostics)
Logs can be viewed in the Capture portal when you open:
- Sources → Edge Gateways → Your gateway → Messages
How it works
- Logging to the portal is enabled only while the page is open. All log messages generated from that point are sent over the realtime connection to the Capture portal.
- One minute after closing the page, Capture Edge will stop sending realtime logs.
- There is no history: you see logs from the moment you open the page onward.
- Cloud3.10.0+ Pick a Minimum level per service to see more or less detail than the gateway logs. Gateway default shows everything the service sends.
- Edge2.4.0+upcomingCloud3.10.0+ The gateway streams that service at the picked level, including
DebugandVerbose, without changing the configuration. The console and file levels stay as they are, and the level lapses one minute after the page is closed. Older versions stream at their configured level, and the portal hides the lines below the picked level.
Portal logging requires a realtime connection between the device and the Capture portal. Port 8883 outbound is the fast path. Since Capture Edge 2.3, log streaming also works when 8883 is blocked, using MQTT over WebSocket on port 443. See If port 8883 is blocked. Older versions need port 8883.
Log level (minimum severity)
Edge2.4.0+upcoming The console and the log files each have their own minimum level, set with
Console › Minimum level and File › Minimum level on the Logging page, or with
CAPTURE_LOG_CONSOLE_LEVEL and CAPTURE_LOG_FILE_LEVEL. For example, keep the console at Information and write
Debug to the log files.
The levels, from most to least detail: Verbose, Debug, Information, Warning, Error, Fatal. A minimum
level also logs every level after it. Environment variables take the level's name, in any case.
The live log on the CloudManager Logs page and the Capture portal each pick their own level per service, for as long as they are open, independent of the console and file levels.
Edge2.4.0+upcoming With the console or an enabled log file at Verbose, the OPC UA mirror
also traces its requests. This replaces CAPTURE_OPCUA_MIRROR_DEBUG.
Older versions have one level for all destinations, set with the Debug mode checkbox:
- Debug mode OFF: Information level and above is logged.
- Debug mode ON: Debug level and above is logged.
Debug and Verbose logging produce significantly more output, but help with troubleshooting.
Retrieving logs
Option A: CloudManager Logs page (recommended)
Open http://localhost:5004 on the device running Capture Edge, and go to Logs.
- Download logs collects all the log files from the Capture services. To send fewer days, use Download diagnostics and its history choice instead.
- Each service has its own tab with its log.
This also works in containerized deployments, as long as CloudManager can reach the other services over HTTP.
Live log
Edge2.4.0+upcoming Each service tab shows the last History lines from the log file, followed by a live stream that refreshes every 2 seconds:
- Pick a Min level to see more or less detail, including
DebugandVerbose. The level applies to that service only, for as long as the page is open; the console and file levels stay as they are. - When the log file holds less detail than the level you picked, a marker shows where the file history ends and the live stream starts, for example: Before 14:03:22: Information and above (from the log file). From 14:03:22: Debug and above (live).
- With file logging off, there is no history: File logging is off: no history before 14:03:22.
- Changing the level adds the same kind of marker.
A service on an older version shows its log file instead, refreshed every 30 seconds.
Log settings per service
Edge2.4.0+upcoming Under each service tab, Log settings lists every logging setting as that service runs it:
- Setting and Value.
- Source: the environment variable, the configuration, the default or the platform default.
- How to change: the Config page, or the environment variable on the device.
Warnings, such as an invalid environment variable or a deprecated one that is still set, are listed above it. The settings are per service, because environment variables are set per service process or container.
The same settings are in the diagnostics package, and in the Logging block each service writes to
its log at startup.
Option B: Copy log files manually
Copy log files directly from the log directories described below.
Log file locations
Default log directory
By default, each Capture service writes logs into its own logs folder.
-
Windows
C:\Program Files (x86)\Capture\<service>\logs- Example:
C:\Program Files (x86)\Capture\Collector\logs
-
Linux
/opt/capture/<service>/logs- Example:
/opt/capture/Collector/logs - Linux paths are case-sensitive: the service folder is capitalised exactly as in the list below.
These Capture services generate logs:
- CloudManager
- Collector
- Syncer
- Analytics
If services run in separate containers, each service’s logs are inside its own container filesystem unless you mount a shared volume.
Custom log directory
You can override the log directory with:
CAPTURE_LOGS_DIR
CAPTURE_LOGS_DIR is a parent folder: each Capture Edge service logs to its own subfolder,
{CAPTURE_LOGS_DIR}/{ServiceName}. For example, with CAPTURE_LOGS_DIR=/var/log/capture the Collector logs to /var/log/capture/Collector.
The log directory can only be set with this environment variable, not from the configuration.
If disk writes are an issue, mount a dedicated volume for logs and point CAPTURE_LOGS_DIR to that location.
Log rotation and retention
Daily log files
A new log file is created each day, for example:
log20260211.log(all logs for Feb 11, 2026)
A separate error-only file is also created by default:
errors20260211.log(errors only)
Even though logYYYYMMDD.log also contains errors, the separate errorsYYYYMMDD.log keeps a longer error trace if the main file hits its size and/or retention limit.
Disable separate error files
To disable error-only files:
- Edge2.4.0+upcoming Turn off Separate error log on the Logging page, or
CAPTURE_SEPARATE_ERROR_LOG=false
File size limit
Each daily log file has a default size limit of 100 MB. You can override the limit using:
- Edge2.4.0+upcoming Max file size (MB) on the Logging page, or
CAPTURE_LOGS_MAX_SIZE(bytes)
The file does not roll over to a new file when it reaches the limit. Once a daily file is full, nothing more is written to it for the rest of the day; file logging resumes in the next day's file. This is by design. Console and portal logging carry on. The error-only file is a separate file with the same limit, so errors are usually still recorded.
Retention limits
Defaults:
- Keep 14 normal log files
- Keep 30 error log files (when error logs are separate)
Override using:
- Edge2.4.0+upcoming Retained files and Retained error files on the Logging page, or
- Edge2.2.0+
CAPTURE_LOG_FILE_COUNT_LIMITandCAPTURE_LOG_ERROR_FILE_COUNT_LIMIT
Startup log
A separate file startups.log records service startups (time + version). The last 1000 startups are kept.
Environment variables
Environment variables apply per service process/container. In multi-container setups, configure them for each container. Edge2.4.0+upcoming An environment variable wins over the same setting on the Logging page.
| Variable | Purpose | Default | Example value |
|---|---|---|---|
CAPTURE_LOG_CONSOLE_LEVEL Edge2.4.0+upcoming | Lowest level written to the console. Overrides Console › Minimum level. | Linux, Docker or debugger attached: InformationWindows service: Error | Debug |
CAPTURE_LOG_FILE_ENABLED Edge2.4.0+upcoming | Write log files. false writes no log file at all, see File logging off. Overrides File › Enabled. | true | false |
CAPTURE_LOG_FILE_LEVEL Edge2.4.0+upcoming | Lowest level written to the log files. Overrides File › Minimum level. | Information | Debug |
CAPTURE_LOG_TO_CONSOLE | Deprecated since 2.4.0, use CAPTURE_LOG_CONSOLE_LEVEL. false limits the console to errors and fatal errors. true uses the configured console level, or Information when none is set. | Not set | true |
CAPTURE_LOGS_DIR | Parent folder for the log files: each service logs to {CAPTURE_LOGS_DIR}/{ServiceName}. Environment variable only. | Windows: C:\Program Files (x86)\Capture\<service>\logsLinux: /opt/capture/<service>/logs | /var/log/capture |
CAPTURE_SEPARATE_ERROR_LOG | Create separate errorsYYYYMMDD.log files. Overrides Separate error log. | true | false |
CAPTURE_LOGS_MAX_SIZE | Max size of each daily log file in bytes. Once reached, file logging stops until the next day's file. Overrides Max file size (MB). | 104857600 (100 MB) | 209715200 (200 MB) |
CAPTURE_LOG_FILE_COUNT_LIMIT | Number of daily normal log files to keep. Overrides Retained files. | 14 | 30 |
CAPTURE_LOG_ERROR_FILE_COUNT_LIMIT | Number of daily error log files to keep (when separate errors are enabled). Overrides Retained error files. | 30 | 60 |
Levels take one of Verbose, Debug, Information, Warning, Error or Fatal. Counts and sizes take a whole
number of at least 1. An empty variable counts as not set.
Removed variables
CAPTURE_OPCUA_MIRROR_DEBUGEdge2.4.0+upcoming: no longer read. The OPC UA mirror traces its requests when the console or an enabled log file is atVerbose. A gateway that still sets it logs a warning at startup.