diff --git a/fhem/contrib/93_Log2Syslog.pm b/fhem/contrib/93_Log2Syslog.pm
index 42df7c312..75ddf88a9 100644
--- a/fhem/contrib/93_Log2Syslog.pm
+++ b/fhem/contrib/93_Log2Syslog.pm
@@ -1538,7 +1538,8 @@ return ($phost,$paddr);
Log2Syslog
- Send FHEM system log entries and/or FHEM events to an external syslog server.
+ The module sends FHEM systemlog entries and/or FHEM events to an external syslog server or act itself as an Syslog-Server
+ to receive Syslog-messages of other Devices which are able to send Syslog.
The syslog protocol has been implemented according the specifications of RFC5424 (IETF),
RFC3164 (BSD) and the TLS transport protocol according to
RFC5425.
@@ -1555,30 +1556,133 @@ return ($phost,$paddr);
- Define
+ Definition and usage
- define <name> Log2Syslog <destination host> [ident:<ident>] [event:<regexp>] [fhem:<regexp>]
+ Depending of the intended purpose a Syslog-Server (MODEL Collector) or a Syslog-Client (MODEL Sender) can be
+ defined.
+ The Collector receives messages in Syslog-format of other Devices and hence generates Events/Readings for further
+ processing. The Sender-Device forwards FHEM Systemlog entries and/or Events to an external Syslog-Server.
+
+
+
+ The Collector (Syslog-Server)
+
+
+ Definition of a Collector
+
+
+
+ define <name> Log2Syslog
+
+
+
+ The Definition don't need any further parameter.
+ In basic setup the Syslog-Server is initialized with Port=1514/UDP and the Parsingprofil "IETF".
+ By the attribute "parseProfile" another formats (e.g. BSD) can be selected.
+ The Syslog-Server is immediately ready for use, is parsing the Syslog-data accordingly the rules of RFC5424 and
+ generates FHEM-Events from received Syslog-messages (pls. see Eventmonitor for parsed data).
- <destination host> = host where the syslog server is running
- [ident:<ident>] = optional program identifier. If not set the device name will be used as default
- [event:<regexp>] = optional regex to filter events for logging
- [fhem:<regexp>] = optional regex to filter fhem system log for logging
+
+ Example of a Collector:
+
+
+
+ define SyslogServer Log2Syslog
+
+
+
+ The generated events are visible in the FHEM-Eventmonitor.
+
+
+ Example of generated Events with attribute parseProfile=IETF:
+
+
+2018-07-31 17:07:24.382 Log2Syslog SyslogServer HOST: fhem.myds.me || FAC: syslog || SEV: Notice || ID: Prod_event || CONT: USV state: OL
+2018-07-31 17:07:24.858 Log2Syslog SyslogServer HOST: fhem.myds.me || FAC: syslog || SEV: Notice || ID: Prod_event || CONT: HMLAN2 loadLvl: low
+
+
+
+ To separate fields the string "||" is used.
+ The meaning of the fields in the example is:
+
+
+
+
+
+ HOST | the Sender of the dataset |
+ FAC | Facility corresponding to RFC5424 |
+ SEV | Severity corresponding to RFC5424 |
+ ID | Ident-Tag |
+ CONT | the message part of the received message |
+
+
+
+ The timestamp of generated events is parsed from the Syslog-message. If this information isn't delivered, the current
+ timestamp of the operating system is used.
+ The reading name in the generated event match the parsed hostname from Syslog-message.
+ If the message don't contain a hostname, the IP-address of the sender is retrieved from the network interface and
+ the hostname is determined if possible.
+ In this case the determined hostname respectively the IP-address is used as Reading in the generated event.
+
+ After definition of a Collectors Syslog-messages in IETF-format according to RFC5424 are expected. If the data are not
+ delivered in this record format and can't be parsed, the Reading "state" will contain the message
+ "parse error - see logfile" and the received Syslog-data are printed into the FHEM Logfile in raw-format.
+
+ By the attribute "parseProfile" you can try to use another predefined parse-profile
+ or you can create an own parse-profile as well.
+
+ To define an own parse function the
+ "parseProfile = ParseFn" has to be set and with attribute "parseFn" a specific
+ parse function has to be provided.
+ The fields used by the event and their sequential arrangement can be selected from a range with
+ attribute "outputFields". Depending from the used parse-profil all or a subset of
+ the available fields can be selected. Further information about it you can find in description of attribute
+ "parseProfile".
+
+ The behavior of the event generation can be adapted by attribute "makeEvent".
+
+
+
+ The Sender (Syslog-Client)
+
+
+ Definition of a Sender
+
+
+
+
+ define <name> Log2Syslog <destination host> [ident:<ident>] [event:<regexp>] [fhem:<regexp>]
+
+
+
+
+
+
+ <destination host> | host (name or IP-address) where the syslog server is running |
+ [ident:<ident>] | optional program identifier. If not set the device name will be used as default. |
+ [event:<regexp>] | optional regex to filter events for logging |
+ [fhem:<regexp>] | optional regex to filter fhem system log for logging |
+
+
+
+
+
After definition the new device sends all new appearing fhem systemlog entries and events to the destination host,
- port=514/UDP format:IETF, immediately without further settings if the regex for fhem or event were set.
- Without setting regex no fhem system log or event log will be forwarded.
-
- The verbose level of FHEM system logs will convert into equivalent syslog severity level.
+ port=514/UDP format:IETF, immediately without further settings if the regex for fhem or event is set.
+ Without setting a regex, no fhem system log or event log will be forwarded.
+
+ The verbose level of FHEM system logs are converted into equivalent syslog severity level.
Thurthermore the message text will be scanned for signal terms "warning" and "error" (with case insensitivity).
- Dependent off the severity will be set equivalent as well. If a severity is already set by verbose level, it wil be overwritten
- by the level according to the signal term found in the message text.
+ Dependent of it the severity will be set equivalent as well. If a severity is already set by verbose level, it will be
+ overwritten by the level according to the signal term found in the message text.
Lookup table Verbose-Level to Syslog severity level:
-
+
verbose-Level | Severity in Syslog |
0 | Critical |
1 | Error |
@@ -1587,53 +1691,61 @@ return ($phost,$paddr);
4 | Informational |
5 | Debug |
-
-
-
+
+
- Example to log anything:
-
- define splunklog Log2Syslog fhemtest 192.168.2.49 ident:Test event:.* fhem:.*
-
- will produce output like this raw example of a splunk syslog server:
-
Aug 18 21:06:46 fhemtest.myds.me 1 2017-08-18T21:06:46 fhemtest.myds.me Test_event 13339 FHEM - : LogDB sql_processing_time: 0.2306
-Aug 18 21:06:46 fhemtest.myds.me 1 2017-08-18T21:06:46 fhemtest.myds.me Test_event 13339 FHEM - : LogDB background_processing_time: 0.2397
-Aug 18 21:06:45 fhemtest.myds.me 1 2017-08-18T21:06:45 fhemtest.myds.me Test_event 13339 FHEM - : LogDB CacheUsage: 21
-Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.760 fhemtest.myds.me Test_fhem 13339 FHEM - : 4: CamTER - Informations of camera Terrasse retrieved
-Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.095 fhemtest.myds.me Test_fhem 13339 FHEM - : 4: CamTER - CAMID already set - ignore get camid
+
+ Example of a Sender:
+
+
+
+ define splunklog Log2Syslog fhemtest 192.168.2.49 ident:Test event:.* fhem:.*
+
+
+
+ All events are forwarded like this exmple of a raw-print of a Splunk Syslog Servers shows:
+
+Aug 18 21:06:46 fhemtest.myds.me 1 2017-08-18T21:06:46 fhemtest.myds.me Test_event 13339 FHEM [version@Log2Syslog version="4.2.0"] : LogDB sql_processing_time: 0.2306
+Aug 18 21:06:46 fhemtest.myds.me 1 2017-08-18T21:06:46 fhemtest.myds.me Test_event 13339 FHEM [version@Log2Syslog version="4.2.0"] : LogDB background_processing_time: 0.2397
+Aug 18 21:06:45 fhemtest.myds.me 1 2017-08-18T21:06:45 fhemtest.myds.me Test_event 13339 FHEM [version@Log2Syslog version="4.2.0"] : LogDB CacheUsage: 21
+Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.760 fhemtest.myds.me Test_fhem 13339 FHEM [version@Log2Syslog version="4.2.0"] : 4: CamTER - Informations of camera Terrasse retrieved
+Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.095 fhemtest.myds.me Test_fhem 13339 FHEM [version@Log2Syslog version="4.2.0"] : 4: CamTER - CAMID already set - ignore get camid
-
+
The structure of the payload differs dependent of the used logFormat.
logFormat IETF:
- "<PRIVAL>VERSION TIME MYHOST IDENT PID MID [SD-FIELD] :MESSAGE"
+ "<PRIVAL>IETFVERS TIME MYHOST IDENT PID MID [SD-FIELD] :MESSAGE"
PRIVAL | priority value (coded from "facility" and "severity") |
+ IETFVERS | used version of RFC5424 specification |
TIME | timestamp according to RFC5424 |
MYHOST | Internal MYHOST |
IDENT | ident-Tag from DEF if set, or else the own device name. The statement will be completed by "_fhem" (FHEM-Log) respectively "_event" (Event-Log). |
PID | sequential Payload-ID |
MID | fix value "FHEM" |
+ SD-FIELD | contains additional iformation about used module version |
MESSAGE | the dataset to transfer |
logFormat BSD:
- "<PRIVAL>MONAT TAG TIME MYHOST IDENT: : MESSAGE"
-
+ "<PRIVAL>MONTH DAY TIME MYHOST IDENT[PID]:MESSAGE"
+
PRIVAL | priority value (coded from "facility" and "severity") |
- MONAT | month according to RFC3164 |
- TAG | day of month according to RFC3164 |
+ MONTH | month according to RFC3164 |
+ DAY | day of month according to RFC3164 |
TIME | timestamp according to RFC3164 |
MYHOST | Internal MYHOST |
IDENT | ident-Tag from DEF if set, or else the own device name. The statement will be completed by "_fhem" (FHEM-Log) respectively "_event" (Event-Log). |
+ PID | the message-id (sequence number) |
MESSAGE | the dataset to transfer |
@@ -1642,73 +1754,308 @@ Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.095 fhemtest.myds.me Test
+
+ Set
+
+
+
+
+ - sendTestMessage [<Message>]
+
+ With device type "Sender" a testmessage can be transfered. The format of the message depends on attribute "logFormat"
+ and contains data in BSD- or IETF-format.
+ Alternatively an own <Message> can be set. This message will be sent in im raw-format without
+ any conversion. The attribute "disable = maintenance" determines, that no data except test messages are sent
+ to the receiver.
+
+
+
+
+
+
+
Get
- certinfo
+
+ - certinfo
Show informations about the server certificate if a TLS-session was created (Reading "SSL_Version" isn't "n.a.").
-
+
+
+
+
-
-
+
Attributes
-
+
+
+
+
- addStateEvent [0|1]
+
+ - addStateEvent
- If set to 1, events will be completed with "state" if a state-event appears.
+ The attribute is only usable for device type "Sender".
+ If set, events will be completed with "state" if a state-event appears.
Default behavior is without getting "state".
-
-
- disable [0|1]
+
+
+
+
+
+
+ - contDelimiter
- disables the device.
-
+ The attribute is only usable for device type "Sender".
+ You can set an additional character which is straight inserted before the content-field.
+ This possibility is useful in some special cases if the receiver need it (e.g. the Synology-Protokollcenter needs the
+ character ":" for proper function).
+
+
+
+
- logFormat [BSD|IETF]
+
+ - disable [1 | 0 | maintenance]
+ This device will be activated, deactivated respectSeverity set into the maintenance-mode.
+ In maintenance-mode a test message can be sent by the "Sender"-device (pls. see also command "set <name>
+ sendTestMessage").
+
+
+
+
+
+
+ - logFormat [ BSD | IETF ]
+
+ This attribute is only usable for device type "Sender".
Set the syslog protocol format.
Default value is "IETF" if not specified.
-
-
- protocol [TCP|UDP]
+
+
+
+
+
+
+ - makeEvent [ intern | no | reading ]
- Sets the socket protocol which should be used. You can choose UDP or TCP.
- Default value is "UDP" if not specified.
-
+ The attribute is only usable for device type "Collector".
+ With this attribute the behavior of the event- and reading generation is defined.
+
+
+
+
+
+ intern | events are generated by module intern mechanism and only visible in FHEM eventmonitor. Readings are not created. |
+ no | only readings like "MSG_<hostname>" without event generation are created |
+ reading | readings like "MSG_<hostname>" are created. Events are created dependent of the "event-on-.*"-attributes |
+
+
+
+
+
+
+
+
+
+ - outputFields
+
+ The attribute is only usable for device type "Collector".
+ By a sortable list the desired fields of generated events can be selected.
+ The meaningful usable fields are depending on the attribute "parseProfil". Their meaning can be found in
+ the description of attribute "parseProfil".
+ Is "outputFields" not defined, a predefined set of fields for event generation is used.
+
+
+
+
+
+
+ - parseFn {<Parsefunktion>}
+
+ The attribute is only usable for device type "Collector".
+ The provided perl function (has to be set into "{}") will be applied to the received Syslog-message.
+ The following variables are commited to the function. They can be used for programming, processing and for
+ value return. Variables which are provided as blank, are marked as "".
+ In case of restrictions the expected format of variables return is specified in "()".
+ Otherwise the variable is usable for free.
+
+
+
+
+
+ $PRIVAL | "" (0 ... 191) |
+ $FAC | "" (0 ... 23) |
+ $SEV | "" (0 ... 7) |
+ $TS | Timestamp (YYYY-MM-DD hh:mm:ss) |
+ $HOST | "" |
+ $DATE | "" (YYYY-MM-DD) |
+ $TIME | "" (hh:mm:ss) |
+ $ID | "" |
+ $PID | "" |
+ $MID | "" |
+ $SDFIELD | "" |
+ $CONT | "" |
+ $DATA | provided raw-data of received Syslog-message (no evaluation of value return!) |
+ $IGNORE | 0 (0|1), if $IGNORE==1 the Syslog-dataset is ignored |
+
+
+
+
+ The names of the variables corresponding to the field names and their primary meaning denoted in attribute
+ "parseProfile" (explanation of the field data).
+
+
+ Example:
+ # Source text: '<4> <;4>LAN IP and mask changed to 192.168.2.3 255.255.255.0'
+ # Task: The characters '<;4>' are to removed from the CONT-field
+
+{
+($PRIVAL,$CONT) = ($DATA =~ /^<(\d{1,3})>\s(.*)$/);
+$CONT = (split(">",$CONT))[1] if($CONT =~ /^<.*>.*$/);
+}
+
+
+
+
+
+
+
+
+
+ - parseProfile [ BSD | IETF | ... | ParseFn | raw ]
+
+ Selection of a parse profile. The attribute is only usable for device type "Collector".
+
+
+
+
+
+ BSD | Parsing of messages in BSD-format according to RFC3164 |
+ IETF | Parsing of messages in IETF-format according to RFC5424 (default) |
+ ... | further specific parse profiles for selective device are provided |
+ ParseFn | Usage of an own specific parse function provided by attribute "parseFn" |
+ raw | no parsing, events are created from the messages as received without conversion |
+
+
+
+
+ The parsed data are provided in fields. The fields to use for events and their sequence can be defined by
+ attribute "outputFields".
+ Dependent from used "parseProfile" the following fields are filled with values and therefor it is meaningful
+ to use only the namend fields by attribute "outputFields". By the "raw"-profil the received data are not converted
+ and the event is created directly.
+
+
+ The meaningful usable fields in attribute "outputFields" depending of the particular profil:
+
+
+
+
+
+ BSD | -> PRIVAL,FAC,SEV,TS,HOST,ID,CONT |
+ IETF | -> PRIVAL,FAC,SEV,TS,HOST,DATE,TIME,ID,PID,MID,SDFIELD,CONT |
+ ParseFn | -> PRIVAL,FAC,SEV,TS,HOST,DATE,TIME,ID,PID,MID,SDFIELD,CONT |
+ raw | -> no selection is meaningful, the original message is used for event creation |
+
+
+
+
+ Explanation of field data:
+
+
+
+
+
+ PRIVAL | coded Priority value (coded from "facility" and "severity") |
+ FAC | decoded Facility |
+ SEV | decoded Severity of message |
+ TS | Timestamp containing date and time (YYYY-MM-DD hh:mm:ss) |
+ HOST | Hostname / Ip-address of the Sender |
+ DATE | Date (YYYY-MM-DD) |
+ TIME | Time (hh:mm:ss) |
+ ID | Device or application what was sending the Syslog-message |
+ PID | Programm-ID, offen reserved by process name or prozess-ID |
+ MID | Type of message (arbitrary string) |
+ SDFIELD | Metadaten about the received Syslog-message |
+ CONT | Content of the message |
+ DATA | received raw-data |
+
+
+
+
+
+
+
- port
+
+ - protocol [ TCP | UDP ]
+
+ Sets the socket protocol which should be used. You can choose UDP or TCP (MODEL Sender).
+ Default value is "UDP" if not specified.
+ A Syslog-Server (MODEL Collector) uses UDP.
+
+
+
+
+
+
+ - port <Port>
The used port. For a Sender the default-port is 514.
A Collector (Syslog-Server) uses the port 1514 per default.
-
+
+
+
+
- rateCalcRerun
+
+ - rateCalcRerun <Zeit in Sekunden>
- Rerun cycle for calculation of log transfer rate (Reading "Transfered_logs_per_minute") in seconds.
+ Rerun cycle for calculation of log transfer rate (Reading "Transfered_logs_per_minute") in seconds (>=60).
+ Values less than 60 seconds are corrected to 60 seconds automatically.
Default is 60 seconds.
-
+
+
+
+
- ssldebug
+
+ - respectSeverity
+
+ Messages are only forwarded (Sender) respectively the receipt considered (Collector), whose severity is included
+ by this attribute.
+ If "respectSeverity" isn't set, messages of all severity is processed.
+
+
+
+
+
+
+ - ssldebug
Debugging level of SSL messages.
@@ -1717,33 +2064,52 @@ Aug 18 21:26:54 fhemtest.myds.me 1 2017-08-18T21:26:54 fhemtest.myds.me Test_eve
- 2 - Print also information about call flow from IO::Socket::SSL and progress information from Net::SSLeay.
- 3 - Print also some data dumps from IO::Socket::SSL and from Net::SSLeay.
-
-
- TLS
-
- A secured connection to Syslog-server is used. The protocol will be switched to TCP automatically.
-
-
- timeout
-
- Timeout for connection to the destination syslog server (TCP). Only valid in Sender-mode. Default: 0.5 seconds.
-
-
- verbose
-
- To avoid loops, the output of verbose level of the Log2Syslog-Devices will only be reported into the local FHEM Logfile and
- no forwarded.
-
-
-
+
+
+
+
+
+ - TLS
+
+ This attribute is only usable for device type "Sender".
+ A secured connection to a Syslog-Server is used. The protocol will be switched to TCP automatically.
+
+
+
+
+
+
+ - timeout
+
+ This attribute is only usable for device type "Sender".
+ Timeout für die Verbindung zum Syslog-Server (TCP). Default: 0.5s.
+
+
+
+
+
+
+ - verbose
+
+ Please see global attribute "verbose".
+ To avoid loops, the output of verbose level of the Log2Syslog-Devices will only be reported into the local FHEM
+ Logfile and not forwarded.
+
+
+
+
+
+
+
Readings
-
+
+ MSG_<Host> | the last successful parsed Syslog-message from <Host> |
SSL_Algorithm | used SSL algorithm if SSL is enabled and active |
SSL_Version | the used TLS-version if encryption is enabled and is active |
Transfered_logs_per_minute | the average number of forwarded logs/events per minute |
@@ -1753,13 +2119,15 @@ Aug 18 21:26:54 fhemtest.myds.me 1 2017-08-18T21:26:54 fhemtest.myds.me Test_eve
+
+
=end html
=begin html_DE
Log2Syslog
- Sendet das Modul FHEM Systemlog Einträge und/oder Events an einen externen Syslog-Server weiter oder agiert als
+ Das Modul sendet FHEM Systemlog-Einträge und/oder Events an einen externen Syslog-Server weiter oder agiert als
Syslog-Server um Syslog-Meldungen anderer Geräte zu empfangen.
Die Implementierung des Syslog-Protokolls erfolgte entsprechend den Vorgaben von RFC5424 (IETF),
RFC3164 (BSD) sowie dem TLS Transport Protokoll nach
@@ -1804,8 +2172,8 @@ Aug 18 21:26:54 fhemtest.myds.me 1 2017-08-18T21:26:54 fhemtest.myds.me Test_eve
Die Definition benötigt keine weiteren Parameter.
In der Grundeinstellung wird der Syslog-Server mit dem Port=1514/UDP und dem Parsingprofil "IETF" initialisiert.
Mit dem Attribut "parseProfile" können alternativ andere Formate (z.B. BSD) ausgewählt werden.
- Der Syslog-Server ist sofort betriebsbereit, parst die Syslog-Daten entsprechend der Richlinien nach RFC5424 und generiert aus den
- eingehenden Syslog-Meldungen FHEM-Events.
+ Der Syslog-Server ist sofort betriebsbereit, parst die Syslog-Daten entsprechend der Richtlinien nach RFC5424 und generiert
+ aus den eingehenden Syslog-Meldungen FHEM-Events (Daten sind im Eventmonitor sichtbar).
Beispiel für einen Collector:
@@ -1854,14 +2222,14 @@ Aug 18 21:26:54 fhemtest.myds.me 1 2017-08-18T21:26:54 fhemtest.myds.me Test_eve
nicht in diesem Format geliefert bzw. können nicht geparst werden, erscheint im Reading "state" die Meldung
"parse error - see logfile" und die empfangenen Syslog-Daten werden im Logfile im raw-Format ausgegeben.
- In diesem Fall kann mit dem Attribut "parseProfile" ein anderes vordefiniertes Parsing-Profil
+ In diesem Fall kann mit dem Attribut "parseProfile" ein anderes vordefiniertes Parse-Profil
eingestellt bzw. ein eigenes Profil definiert werden.
- Zur Definition einer eigenen Parsingfunktion wird
+ Zur Definition einer eigenen Parse-Funktion wird
"parseProfile = ParseFn" eingestellt und im Attribut "parseFn" eine spezifische
- Parsingfunktion hinterlegt.
+ Parse-Funktion hinterlegt.
Die im Event verwendeten Felder und deren Reihenfolge können aus einem Wertevorrat mit dem
- Attribut "outputFields" bestimmt werden. Je nach verwendeten Parsingprofil können alle oder
+ Attribut "outputFields" bestimmt werden. Je nach verwendeten Parse-Funktion können alle oder
nur eine Untermenge der verfügbaren Felder verwendet werden. Näheres dazu in der Beschreibung des Attributes "parseProfile".
Das Verhalten der Eventgenerierung kann mit dem Attribut "makeEvent" angepasst werden.
@@ -1937,12 +2305,13 @@ Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.095 fhemtest.myds.me Test
Der Aufbau der Payload unterscheidet sich je nach verwendeten logFormat.
logFormat IETF:
- "<PRIVAL>VERSION TIME MYHOST IDENT PID MID [SD-FIELD] :MESSAGE"
+ "<PRIVAL>IETFVERS TIME MYHOST IDENT PID MID [SD-FIELD] :MESSAGE"
PRIVAL | Priority Wert (kodiert aus "facility" und "severity") |
+ IETFVERS | Version der benutzten RFC5424 Spezifikation |
TIME | Timestamp nach RFC5424 |
MYHOST | Internal MYHOST |
IDENT | Ident-Tag aus DEF wenn angegeben, sonst der eigene Devicename. Die Angabe wird mit "_fhem" (FHEM-Log) bzw. "_event" (Event-Log) ergänzt. |
@@ -1955,17 +2324,18 @@ Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.095 fhemtest.myds.me Test
logFormat BSD:
- "<PRIVAL>MONAT TAG TIME MYHOST IDENT: : MESSAGE"
+ "<PRIVAL>MONTH DAY TIME MYHOST IDENT[PID]:MESSAGE"
PRIVAL | Priority Wert (kodiert aus "facility" und "severity") |
- MONAT | Monatsangabe nach RFC3164 |
- TAG | Tag des Monats nach RFC3164 |
+ MONTH | Monatsangabe nach RFC3164 |
+ DAY | Tag des Monats nach RFC3164 |
TIME | Zeitangabe nach RFC3164 |
MYHOST | Internal MYHOST |
IDENT | Ident-Tag aus DEF wenn angegeben, sonst der eigene Devicename. Die Angabe wird mit "_fhem" (FHEM-Log) bzw. "_event" (Event-Log) ergänzt. |
+ PID | Die ID der Mitteilung (= Sequenznummer) |
MESSAGE | der zu übertragende Datensatz |
@@ -2020,10 +2390,10 @@ Aug 18 21:08:27 fhemtest.myds.me 1 2017-08-18T21:08:27.095 fhemtest.myds.me Test
- addTimestamp
Das Attribut ist nur für "Sender" verwendbar. Wenn gesetzt, werden FHEM Timestamps im Content-Feld der Syslog-Meldung
- mit übertragen.
+ mit übertragen.
Per default werden die Timestamps nicht im Content-Feld hinzugefügt, da innerhalb der Syslog-Meldungen im IETF- bzw.
- BSD-Format bereits Zeitstempel gemäß RFC-Vorgabe erstellt werden.
- Die Einstellung kann hilfeich sein wenn mseclog in FHEM aktiviert ist.
+ BSD-Format bereits Zeitstempel gemäß RFC-Vorgabe erstellt werden.
+ Die Einstellung kann hilfeich sein wenn mseclog in FHEM aktiviert ist.
Beispielausgabe (raw) eines Splunk Syslog Servers:
@@ -2038,7 +2408,7 @@ Aug 18 21:26:54 fhemtest.myds.me 1 2017-08-18T21:26:54 fhemtest.myds.me Test_eve
- addStateEvent
- Das Attribut ist nur für "Sender" verwendbar. Wenn gesetzt, werden state-events mit dem Reading "state" ergänzt.
+ Das Attribut ist nur für "Sender" verwendbar. Wenn gesetzt, werden state-events mit dem Reading "state" ergänzt.
Die Standardeinstellung ist ohne state-Ergänzung.
@@ -2100,6 +2470,7 @@ Aug 18 21:26:54 fhemtest.myds.me 1 2017-08-18T21:26:54 fhemtest.myds.me Test_eve
- outputFields
+ Das Attribut ist nur für "Collector" verwendbar.
Über eine sortierbare Liste können die gewünschten Felder des generierten Events ausgewählt werden.
Die abhängig vom Attribut "parseProfil" sinnvoll verwendbaren Felder und deren Bedeutung ist der Beschreibung
des Attributs "parseProfil" zu entnehmen.
@@ -2306,6 +2677,7 @@ $CONT = (split(">",$CONT))[1] if($CONT =~ /^<.*>.*$/);
- verbose
+ Verbose-Level entsprechend dem globalen Attribut "verbose".
Die Ausgaben der Verbose-Level von Log2Syslog-Devices werden ausschließlich im lokalen FHEM Logfile ausgegeben und
nicht weitergeleitet um Schleifen zu vermeiden.