diff --git a/packages/addons/service/rsyslog/changelog.txt b/packages/addons/service/rsyslog/changelog.txt index 9455e1f3c8..d131823983 100755 --- a/packages/addons/service/rsyslog/changelog.txt +++ b/packages/addons/service/rsyslog/changelog.txt @@ -1,2 +1,7 @@ 8.0.100 - Initial addon + +8.0.101 +- Add RELP Protocol +- Add ability to compress messages using TCP/UDP protocols +- Update configuration files using newer standards diff --git a/packages/addons/service/rsyslog/package.mk b/packages/addons/service/rsyslog/package.mk index b68e36c348..5cfb51d772 100644 --- a/packages/addons/service/rsyslog/package.mk +++ b/packages/addons/service/rsyslog/package.mk @@ -18,7 +18,7 @@ PKG_NAME="rsyslog" PKG_VERSION="8.21.0" -PKG_REV="100" +PKG_REV="101" PKG_ARCH="any" PKG_LICENSE="GPL" PKG_SITE="https://github.com/rsyslog" @@ -37,6 +37,8 @@ PKG_ADDON_REPOVERSION="8.0" PKG_CONFIGURE_OPTS_TARGET="--enable-imfile \ --enable-imjournal \ + --enable-relp \ + --enable-omjournal \ ac_cv_func_malloc_0_nonnull=yes \ ac_cv_func_realloc_0_nonnull=yes" diff --git a/packages/addons/service/rsyslog/source/bin/rsyslog.init b/packages/addons/service/rsyslog/source/bin/rsyslog.init index f7ea1ae287..072bddd0e6 100644 --- a/packages/addons/service/rsyslog/source/bin/rsyslog.init +++ b/packages/addons/service/rsyslog/source/bin/rsyslog.init @@ -26,9 +26,13 @@ oe_setup_addon service.rsyslog if [ ! -z "$RSYSLOG_IP_NAME_FQDN" ] then cat "$ADDON_DIR/config/common.conf" + [ "$RSYSLOG_PROTOCOL" == "RELP" ] && cat "$ADDON_DIR/config/relp.conf" [ "$RSYSLOG_JOURNAL_LOGGING" == "true" ] && cat "$ADDON_DIR/config/journal.conf" [ "$RSYSLOG_KODI_LOGGING" == "true" ] && cat "$ADDON_DIR/config/kodi.conf" - [ "$RSYSLOG_PROTOCOL" == "UDP" ] && PROTOCOL="@" || PROTOCOL="@@" - echo "*.* $PROTOCOL$RSYSLOG_IP_NAME_FQDN:$RSYSLOG_PORT" + [ "$RSYSLOG_PROTOCOL" == "UDP" ] && PROTOCOL="@" + [ "$RSYSLOG_PROTOCOL" == "TCP" ] && PROTOCOL="@@" + [ "$RSYSLOG_PROTOCOL" == "RELP" ] && PROTOCOL="omrelp" + [ "$RSYSLOG_PROTOCOL" == "RELP" ] && ZLIB="0" || [ "$RSYSLOG_ZLIB_COMPRESSION" == "true" ] && ZLIB="$RSYSLOG_ZLIB_COMPRESSION_LEVEL" || ZLIB="0" + [ "$RSYSLOG_PROTOCOL" == "RELP" ] && echo "action(type=\"$PROTOCOL\" target=\"$RSYSLOG_IP_NAME_FQDN\" port=\"$RSYSLOG_PORT\")" || echo "action(type=\"omfwd\" target=\"$RSYSLOG_IP_NAME_FQDN\" protocol=\"$RSYSLOG_PROTOCOL\" port=\"$RSYSLOG_PORT\")" fi ) > "$ADDON_HOME/rsyslog.conf" diff --git a/packages/addons/service/rsyslog/source/config/common.conf b/packages/addons/service/rsyslog/source/config/common.conf index 69ffd9b641..d083a2a3da 100644 --- a/packages/addons/service/rsyslog/source/config/common.conf +++ b/packages/addons/service/rsyslog/source/config/common.conf @@ -1,6 +1,7 @@ -$ModLoad imuxsock -$OmitLocalLogging on +module(load="imuxsock" + SysSock.RateLimit.Interval="1" + sysSock.parseHostname="on") + $AddUnixListenSocket /run/systemd/journal/syslog $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat $WorkDirectory /storage/.kodi/temp - diff --git a/packages/addons/service/rsyslog/source/config/journal.conf b/packages/addons/service/rsyslog/source/config/journal.conf index caaee11c5b..c32e497d33 100644 --- a/packages/addons/service/rsyslog/source/config/journal.conf +++ b/packages/addons/service/rsyslog/source/config/journal.conf @@ -1,3 +1,4 @@ -$ModLoad imjournal -$ModLoad imklog +module(load="imjournal") +module(load="omjournal") +module(load="imklog") diff --git a/packages/addons/service/rsyslog/source/config/kodi.conf b/packages/addons/service/rsyslog/source/config/kodi.conf index 6bb4f9c57e..9e19a2f421 100644 --- a/packages/addons/service/rsyslog/source/config/kodi.conf +++ b/packages/addons/service/rsyslog/source/config/kodi.conf @@ -1,65 +1,74 @@ -$ModLoad imfile -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity emerg -$InputFileFacility local0 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +module(load="imfile") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity alert -$InputFileFacility local1 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="emerg" + Facility="local0" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity crit -$InputFileFacility local2 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="alert" + Facility="local1" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity error -$InputFileFacility local3 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="crit" + Facility="local2" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity warning -$InputFileFacility local4 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="error" + Facility="local3" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity notice -$InputFileFacility local5 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="warning" + Facility="local4" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity info -$InputFileFacility local6 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="notice" + Facility="local5" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") -$InputFileName /storage/.kodi/temp/kodi.log -$InputFileTag kodi -$InputFileStateFile kodi -$InputFileSeverity debug -$InputFileFacility local7 -$InputRunFileMonitor -$InputFilePersistStateInterval 1 +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="info" + Facility="local6" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") + +input(type="imfile" + File="/storage/.kodi/temp/kodi.log" + Tag="kodi" + Severity="debug" + Facility="local7" + deleteStateOnFileDelete="on" + escapeLF="on" + PersistStateInterval="5") diff --git a/packages/addons/service/rsyslog/source/config/relp.conf b/packages/addons/service/rsyslog/source/config/relp.conf new file mode 100644 index 0000000000..9fa84dbb9c --- /dev/null +++ b/packages/addons/service/rsyslog/source/config/relp.conf @@ -0,0 +1,2 @@ +module(load="omrelp") + diff --git a/packages/addons/service/rsyslog/source/resources/language/English/strings.po b/packages/addons/service/rsyslog/source/resources/language/English/strings.po index 4f8d2f8479..1ea19b01e7 100644 --- a/packages/addons/service/rsyslog/source/resources/language/English/strings.po +++ b/packages/addons/service/rsyslog/source/resources/language/English/strings.po @@ -30,3 +30,11 @@ msgstr "" msgctxt "#30006" msgid "Log Kodi" msgstr "" + +msgctxt "#30007" +msgid "Zlib Compression" +msgstr "" + +msgctxt "#30008" +msgid "Level" +msgstr "" diff --git a/packages/addons/service/rsyslog/source/resources/settings.xml b/packages/addons/service/rsyslog/source/resources/settings.xml index a7dc15674f..e740cc15b4 100644 --- a/packages/addons/service/rsyslog/source/resources/settings.xml +++ b/packages/addons/service/rsyslog/source/resources/settings.xml @@ -1,11 +1,13 @@ - - - - - - + + + + + + + + diff --git a/packages/addons/service/rsyslog/source/settings-default.xml b/packages/addons/service/rsyslog/source/settings-default.xml index 3e3fbda1e0..019b23815e 100644 --- a/packages/addons/service/rsyslog/source/settings-default.xml +++ b/packages/addons/service/rsyslog/source/settings-default.xml @@ -5,4 +5,6 @@ + +