Hello
I would need to commit support for the syslog sent on Huawei VRP devices when the config changes. I implemented if in our current (28th of March) librenms system. The user is unfortunately not provided by the syslog so the value is fixed so far in my syslog-notify-oxidized.php
Here is the patch against our current (28th of March) librenms system.
-bash-4.2$ git diff
diff --git a/scripts/syslog-notify-oxidized.php b/scripts/syslog-notify-oxidized.php
index 6eab39d…3451ef3 100755
— a/scripts/syslog-notify-oxidized.php
+++ b/scripts/syslog-notify-oxidized.php
@@ -41,4 +41,7 @@ if (preg_match(‘/(SYS-(SW[0-9]±)?5-CONFIG_I|VSHD-5-VSHD_SYSLOG_CONFIG_I): Confi
} elseif (preg_match(’/startup-config was changed by (?P.+) from telnet client .*/‘, $msg, $matches)) {
$username = $matches[‘user’];
oxidized_node_update($hostname, $username, $msg);
-}
+} elseif (preg_match(’/HWCM/4/CFGCHANGE/', $msg, $matches)) {
+$username = ‘not_provided’;
+oxidized_node_update($hostname, $username, $msg);
+}
Here is an example of syslog:
00 deviceName HWCM/4/CFGCHANGE:OID 1.3.6.1.4.1.2011.6.10.2.1 Configure changed. (EventIndex=295, CommandSource=1, ConfigSource=2, ConfigDestination=4)
Could somebody review the patch and commit it ?
Thanx