feat(logs): log level, retention, size limits and rotation on server and desktop
Owner review 2, R11 asked for more log settings. The file sink now writes daily or hourly files, continues a full file in numbered parts and prunes by age and by the total size (never the file being written); its options change while it runs. Server: the file and console levels are separate and read by the logging filters at every line, so the admin panel's new Logs group applies without a restart; the engine's level follows the lower of the two. This also fixes a bug: the file logger was fixed at Information, so CHRONOS_LOG_LEVEL=Debug or Trace never reached the files. New variables CHRONOS_LOG_CONSOLE_LEVEL, CHRONOS_LOG_RETENTION_DAYS, CHRONOS_LOG_MAX_FILE_MB, CHRONOS_LOG_MAX_TOTAL_MB, CHRONOS_LOG_ROTATION, CHRONOS_AUDIT_RETENTION_DAYS and CHRONOS_DIAGNOSTICS_LOG_MB lock their settings like the others; the diagnostics zip keeps the configured share of each log. Desktop: Settings > Advanced gains Log level, Keep logs, File size, Logs total, Rotation and Diagnostics logs, applied at every save; Advanced's Reset section restores them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit cc875784e4952ee0e4c807b9d9c18496d3d5a8c3)
This commit is contained in:
1 parent
1f089888e8
commit
0e84392f4f
35 files changed
+1485
-119
No files matched your search
@@ -42,8 +42,19 @@ services:
|
||||
# admin panel's Settings.
|
||||
# CHRONOS_PARALLELISM: "4"
|
||||
# CHRONOS_PRIORITY_QUEUE: "true"
|
||||
# Trace, Debug, Information, Warning or Error
|
||||
# The log files' and the console's level: Trace, Debug, Information, Warning, Error, Critical or None
|
||||
CHRONOS_LOG_LEVEL: Information
|
||||
# The log files (/data/logs) and the audit log: the console's own level, the days files are kept, the size (MB) at
|
||||
# which a file continues in a numbered one and that of all files (the oldest go beyond it; 0: no limit for either),
|
||||
# daily or hourly files, the days audit entries are kept (0: forever) and the MB of each log in the diagnostics zip.
|
||||
# Set here, they can no longer be changed in the admin panel's Settings › Logs.
|
||||
# CHRONOS_LOG_CONSOLE_LEVEL: Warning
|
||||
# CHRONOS_LOG_RETENTION_DAYS: "14"
|
||||
# CHRONOS_LOG_MAX_FILE_MB: "50"
|
||||
# CHRONOS_LOG_MAX_TOTAL_MB: "1024"
|
||||
# CHRONOS_LOG_ROTATION: daily
|
||||
# CHRONOS_AUDIT_RETENTION_DAYS: "0"
|
||||
# CHRONOS_DIAGNOSTICS_LOG_MB: "4"
|
||||
# The admin panel shows the archive volume's free space. An Unraid share (/mnt/user/<share>) reports its primary
|
||||
# storage, often the cache: map the share's array view to /space (volumes below) and show that one instead.
|
||||
# CHRONOS_SPACE_PATH: /space
|
||||
|
||||
Reference in new issue
Block a user