summaryrefslogtreecommitdiff
path: root/interface-definitions/system-logs.xml.in
diff options
context:
space:
mode:
authorzsdc <taras@vyos.io>2021-12-13 20:05:25 +0200
committerzsdc <taras@vyos.io>2021-12-13 21:45:47 +0200
commit945ab070b72ebd9f5ccfe0052ed138a93b83b297 (patch)
tree9e3c40eba1190f9e8edff9fb9c1219b18cc91fc0 /interface-definitions/system-logs.xml.in
parenta22ba14999a38217155a7a999f61e855d813cc41 (diff)
downloadvyos-1x-945ab070b72ebd9f5ccfe0052ed138a93b83b297.tar.gz
vyos-1x-945ab070b72ebd9f5ccfe0052ed138a93b83b297.zip
logs: T3774: Added new CLI item
Added the ability to control the `/var/log/messages` rotation. Renamed the option `maxsize` to `max-size`.
Diffstat (limited to 'interface-definitions/system-logs.xml.in')
-rw-r--r--interface-definitions/system-logs.xml.in37
1 files changed, 36 insertions, 1 deletions
diff --git a/interface-definitions/system-logs.xml.in b/interface-definitions/system-logs.xml.in
index 5f81b8f00..dc5751372 100644
--- a/interface-definitions/system-logs.xml.in
+++ b/interface-definitions/system-logs.xml.in
@@ -18,7 +18,7 @@
<help>Atop logs options (system resources usage)</help>
</properties>
<children>
- <leafNode name="maxsize">
+ <leafNode name="max-size">
<properties>
<help>Size of a single log file that triggers rotation</help>
<valueHelp>
@@ -48,6 +48,41 @@
</leafNode>
</children>
</node>
+ <node name="messages">
+ <properties>
+ <help>The /var/log/messages file rotation</help>
+ </properties>
+ <children>
+ <leafNode name="max-size">
+ <properties>
+ <help>Size of a single log file that triggers rotation</help>
+ <valueHelp>
+ <format>u32:1-1024</format>
+ <description>Size in MB (default: 1)</description>
+ </valueHelp>
+ <constraint>
+ <validator name="numeric" argument="--range 1-1024" />
+ </constraint>
+ <constraintErrorMessage>The size must be between 1 and 1024 MB</constraintErrorMessage>
+ </properties>
+ <defaultValue>10</defaultValue>
+ </leafNode>
+ <leafNode name="rotate">
+ <properties>
+ <help>Count of rotations before old logs will be deleted</help>
+ <valueHelp>
+ <format>u32:1-100</format>
+ <description>Rotations (default: 10)</description>
+ </valueHelp>
+ <constraint>
+ <validator name="numeric" argument="--range 1-100" />
+ </constraint>
+ <constraintErrorMessage>The count must be between 1 and 100</constraintErrorMessage>
+ </properties>
+ <defaultValue>10</defaultValue>
+ </leafNode>
+ </children>
+ </node>
</children>
</node>
</children>