I just activatet the REFRESH of my Homematic Variables over the Gateway. But with every refresh I get this Infowarnings in my log:
2019-02-20 11:12:40.057 [ome.event.ItemCommandEvent] - Item 'Homematic_Fensterstatus' received command REFRESH
==> /var/log/openhab2/openhab.log <==
2019-02-20 11:12:40.100 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name '${sysVarAlarmZone1}' contains invalid characters, new Datapoint name '__sysVarAlarmZone1_'
2019-02-20 11:12:40.103 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name '${sysVarPresence}' contains invalid characters, new Datapoint name '__sysVarPresence_'
2019-02-20 11:12:40.106 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Fenster/TΓΌren' contains invalid characters, new Datapoint name 'Fenster_T_ren'
2019-02-20 11:12:40.109 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Servicemeldungen Telegram' contains invalid characters, new Datapoint name 'Servicemeldungen_Telegram'
2019-02-20 11:12:40.111 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom ENERGY_COUNTER' contains invalid characters, new Datapoint name 'Strom_ENERGY_COUNTER'
2019-02-20 11:12:40.114 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Leistungsaufnahme aktuell' contains invalid characters, new Datapoint name 'Strom_Leistungsaufnahme_aktuell'
2019-02-20 11:12:40.116 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Referenz Verbrauch heute' contains invalid characters, new Datapoint name 'Strom_Referenz_Verbrauch_heute'
2019-02-20 11:12:40.119 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Referenz Verbrauch laufende Woche' contains invalid characters, new Datapoint name 'Strom_Referenz_Verbrauch_laufende_Woche'
2019-02-20 11:12:40.121 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Referenz Verbrauch laufender Monat' contains invalid characters, new Datapoint name 'Strom_Referenz_Verbrauch_laufender_Monat'
2019-02-20 11:12:40.123 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Referenz Verbrauch laufendes Kalenderjahr' contains invalid characters, new Datapoint name 'Strom_Referenz_Verbrauch_laufendes_Kalenderjahr'
2019-02-20 11:12:40.126 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Referenz Verbrauch seit letzter Ablesung' contains invalid characters, new Datapoint name 'Strom_Referenz_Verbrauch_seit_letzter_Ablesung'
2019-02-20 11:12:40.128 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Referenz Zaehlerstand' contains invalid characters, new Datapoint name 'Strom_Referenz_Zaehlerstand'
2019-02-20 11:12:40.130 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Verbrauch heute' contains invalid characters, new Datapoint name 'Strom_Verbrauch_heute'
2019-02-20 11:12:40.133 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Verbrauch laufende Woche' contains invalid characters, new Datapoint name 'Strom_Verbrauch_laufende_Woche'
2019-02-20 11:12:40.135 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Verbrauch laufender Monat' contains invalid characters, new Datapoint name 'Strom_Verbrauch_laufender_Monat'
2019-02-20 11:12:40.138 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Verbrauch laufendes Kalenderjahr' contains invalid characters, new Datapoint name 'Strom_Verbrauch_laufendes_Kalenderjahr'
2019-02-20 11:12:40.140 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Verbrauch seit letzter Ablesung' contains invalid characters, new Datapoint name 'Strom_Verbrauch_seit_letzter_Ablesung'
2019-02-20 11:12:40.143 [INFO ] [ng.homematic.internal.misc.MiscUtils] - Datapoint name 'Strom Zaehlerstand' contains invalid characters, new Datapoint name 'Strom_Zaehlerstand'
I try to change the log level but nothing happend
openhab> log:get
Logger β Level
ββββββββββββββββββββββββββββββββββββββββββββββββββββΌββββββ
ROOT β WARN
javax.jmdns β ERROR
ng.homematic.internal.misc.MiscUtils β OFF
org.apache.karaf.jaas.modules.audit β INFO
org.apache.karaf.kar.internal.KarServiceImpl β ERROR
org.apache.karaf.shell.support β OFF
org.apache.sshd β WARN
org.eclipse.jetty.util.thread.ThreadPoolBudget β ERROR
org.eclipse.smarthome β INFO
org.jupnp β ERROR
org.openhab β INFO
org.openhab.binding.gpstracker β ERROR
org.openhab.binding.homematic β ERROR
org.ops4j.pax.url.mvn.internal.AetherBasedResolver β ERROR
org.ops4j.pax.web.pax-web-runtime β OFF
smarthome.event β INFO
smarthome.event.InboxUpdatedEvent β ERROR
smarthome.event.ItemAddedEvent β ERROR
smarthome.event.ItemRemovedEvent β ERROR
smarthome.event.ItemStateEvent β ERROR
smarthome.event.ThingAddedEvent β ERROR
smarthome.event.ThingRemovedEvent β ERROR
smarthome.event.ThingStatusInfoEvent β ERROR
How can I change it?
Vradatta
(Eric Zenz-Matzl)
February 20, 2019, 4:27pm
3
You could also remove the spaces and other invalid characters (replaced by _ )
Then there would be no log you have to hide
There is already
log4j2.logger.ng_homematic_internal_misc_miscutils.level = OFF
log4j2.logger.ng_homematic_internal_misc_miscutils.name = ng.homematic.internal.misc.MiscUtils
in the log config
This is supposed to switch it off, or?
That a possibility, but wouldnβt work with some system variables (${sysVarAlarmZone1}; ${sysVarPresence})
rlkoshak
(Rich Koshak)
February 20, 2019, 8:41pm
6
It depends on which appender that logger is using and where you are looking. There is a file appender that writes to openhab.log and there is an OSGI appender that defines what gets logged, by default, to the karaf console.
I want to get rid off the entries in the openhab.log, can you give me a hint what i have to change then in the config?
# Common pattern layout for appenders
#log4j2.pattern = %d{ISO8601} | %-5p | %-16t | %-32c{1} | %X{bundle.id} - %X{bundle.name} - %X{bundle.version} | %m%n
# Root logger
log4j2.rootLogger.level = WARN
log4j2.rootLogger.appenderRefs = out, osgi
log4j2.rootLogger.appenderRef.out.ref = LOGFILE
log4j2.rootLogger.appenderRef.osgi.ref = OSGI
# Karaf Shell logger
log4j2.logger.shell.name = org.apache.karaf.shell.support
log4j2.logger.shell.level = OFF
log4j2.logger.shell.appenderRefs = stdout
log4j2.logger.shell.appenderRef.stdout.ref = STDOUT
# Security audit logger
log4j2.logger.audit.name = org.apache.karaf.jaas.modules.audit
log4j2.logger.audit.level = INFO
log4j2.logger.audit.additivity = false
log4j2.logger.audit.appenderRefs = audit
log4j2.logger.audit.appenderRef.audit.ref = AUDIT
# openHAB specific logger configuration
log4j2.logger.openhab.name = org.openhab
log4j2.logger.openhab.level = INFO
log4j2.logger.smarthome.name = org.eclipse.smarthome
log4j2.logger.smarthome.level = INFO
log4j2.logger.smarthomeItemStateEvent.name = smarthome.event.ItemStateEvent
log4j2.logger.smarthomeItemStateEvent.level = ERROR
log4j2.logger.smarthomeItemAddedEvent.name = smarthome.event.ItemAddedEvent
log4j2.logger.smarthomeItemAddedEvent.level = ERROR
log4j2.logger.smarthomeItemRemovedEvent.name = smarthome.event.ItemRemovedEvent
log4j2.logger.smarthomeItemRemovedEvent.level = ERROR
log4j2.logger.smarthomeThingStatusInfoEvent.name = smarthome.event.ThingStatusInfoEvent
log4j2.logger.smarthomeThingStatusInfoEvent.level = ERROR
log4j2.logger.smarthomeThingAddedEvent.name = smarthome.event.ThingAddedEvent
log4j2.logger.smarthomeThingAddedEvent.level = ERROR
log4j2.logger.smarthomeThingRemovedEvent.name = smarthome.event.ThingRemovedEvent
log4j2.logger.smarthomeThingRemovedEvent.level = ERROR
log4j2.logger.smarthomeInboxUpdatedEvent.name = smarthome.event.InboxUpdatedEvent
log4j2.logger.smarthomeInboxUpdatedEvent.level = ERROR
log4j2.logger.events.name = smarthome.event
log4j2.logger.events.level = INFO
log4j2.logger.events.additivity = false
log4j2.logger.events.appenderRefs = event
log4j2.logger.events.appenderRef.event.ref = EVENT
log4j2.logger.events.appenderRef.osgi.ref = OSGI
log4j2.logger.jupnp.name = org.jupnp
log4j2.logger.jupnp.level = ERROR
log4j2.logger.jmdns.name = javax.jmdns
log4j2.logger.jmdns.level = ERROR
# This suppresses all Maven download issues from the log when doing feature installations
# as we are logging errors ourselves in a nicer way anyhow.
log4j2.logger.paxurl.name = org.ops4j.pax.url.mvn.internal.AetherBasedResolver
log4j2.logger.paxurl.level = ERROR
# Filters known issues of pax-web (issue link to be added here).
# Can be removed once the issues are resolved in an upcoming version.
log4j2.logger.paxweb.name = org.ops4j.pax.web.pax-web-runtime
log4j2.logger.paxweb.level = OFF
# Filters known issues of lsp4j, see
# https://github.com/eclipse/smarthome/issues/4639
# https://github.com/eclipse/smarthome/issues/4629
# https://github.com/eclipse/smarthome/issues/4643
# Can be removed once the issues are resolved in an upcoming version.
log4j2.logger.lsp4j.name = org.eclipse.lsp4j
log4j2.logger.lsp4j.level = OFF
# Filters known issues of KarServiceImpl, see
# https://github.com/openhab/openhab-distro/issues/519#issuecomment-351944506
# Can be removed once the issues are resolved in an upcoming version.
log4j2.logger.karservice.name = org.apache.karaf.kar.internal.KarServiceImpl
log4j2.logger.karservice.level = ERROR
# Filters warnings about small thread pools.
# The thread pool is kept small intentionally for supporting resource constrained hardware.
log4j2.logger.threadpoolbudget.name = org.eclipse.jetty.util.thread.ThreadPoolBudget
log4j2.logger.threadpoolbudget.level = ERROR
# Appenders configuration
# Console appender not used by default (see log4j2.rootLogger.appenderRefs)
log4j2.appender.console.type = Console
log4j2.appender.console.name = STDOUT
log4j2.appender.console.layout.type = PatternLayout
log4j2.appender.console.layout.pattern = %d{HH:mm:ss.SSS} [%-5.5p] [%-36.36c] - %m%n
# Rolling file appender
log4j2.appender.out.type = RollingRandomAccessFile
log4j2.appender.out.name = LOGFILE
log4j2.appender.out.fileName = /home/openhabian/LOGS/openhab.log
log4j2.appender.out.filePattern = /home/openhabian/LOGS/openhab.log.%i
log4j2.appender.out.immediateFlush = true
log4j2.appender.out.append = true
log4j2.appender.out.layout.type = PatternLayout
log4j2.appender.out.layout.pattern = %d{yyyy-MM-dd HH:mm:ss.SSS} [%-5.5p] [%-36.36c] - %m%n
log4j2.appender.out.policies.type = Policies
log4j2.appender.out.policies.size.type = SizeBasedTriggeringPolicy
log4j2.appender.out.policies.size.size = 16MB
# Event log appender
log4j2.appender.event.type = RollingRandomAccessFile
log4j2.appender.event.name = EVENT
log4j2.appender.event.fileName = /home/openhabian/LOGS/events.log
log4j2.appender.event.filePattern = /home/openhabian/LOGS/events.log.%i
log4j2.appender.event.immediateFlush = true
log4j2.appender.event.append = true
log4j2.appender.event.layout.type = PatternLayout
log4j2.appender.event.layout.pattern = %d{yyyy-MM-dd HH:mm:ss.SSS} [%-26.26c] - %m%n
log4j2.appender.event.policies.type = Policies
log4j2.appender.event.policies.size.type = SizeBasedTriggeringPolicy
log4j2.appender.event.policies.size.size = 16MB
# Audit file appender
log4j2.appender.audit.type = RollingRandomAccessFile
log4j2.appender.audit.name = AUDIT
log4j2.appender.audit.fileName = ${openhab.logdir}/audit.log
log4j2.appender.audit.filePattern = ${openhab.logdir}/audit.log.%i
log4j2.appender.audit.append = true
log4j2.appender.audit.layout.type = PatternLayout
log4j2.appender.audit.layout.pattern = %d{yyyy-MM-dd HH:mm:ss.SSS} [%-5.5p] [%-36.36c] - %m%n
log4j2.appender.audit.policies.type = Policies
log4j2.appender.audit.policies.size.type = SizeBasedTriggeringPolicy
log4j2.appender.audit.policies.size.size = 8MB
# OSGi appender
log4j2.appender.osgi.type = PaxOsgi
log4j2.appender.osgi.name = OSGI
log4j2.appender.osgi.filter = *
log4j2.logger.org_openhab_binding_gpstracker.level = ERROR
log4j2.logger.org_openhab_binding_gpstracker.name = org.openhab.binding.gpstracker
log4j2.logger.ng_homematic_internal_misc_miscutils.level = OFF
log4j2.logger.ng_homematic_internal_misc_miscutils.name = ng.homematic.internal.misc.MiscUtils
log4j2.logger.org_apache_sshd.level = WARN
log4j2.logger.org_apache_sshd.name = org.apache.sshd
log4j2.logger.org_openhab_binding_homematic.level = ERROR
log4j2.logger.org_openhab_binding_homematic.name = org.openhab.binding.homematic
rlkoshak
(Rich Koshak)
February 20, 2019, 9:45pm
8
As shown in the example in the link I provided, create a logger and an appender for this binding. Then change the logging level to WARN instead of INFO.
Compare the βdefault configβ with the βcustom configβ and you will quickly see the additions needed.
hilbrand
(Hilbrand Bouwkamp)
February 20, 2019, 10:01pm
9
The log message cutsoff the whole path. You need to set the correct path:
log:set OFF org.openhab.binding.homematic.internal.misc
(Or just set it to WARN
)
Edit: Removed classname MiscUtils
from command above. The log is set on package.
1 Like
aingidh
(Thomas H.)
November 29, 2020, 10:56pm
10
Has anyone solved this? I still have the problem and am unable to solve it
log:get shows
Logger Level
org.eclipse.smarthome.binding.homematic.internal.misc.MiscUtils ERROR
but I am still receiving INFO messages in the openhab.log file.
namraccr
(namraccr)
November 29, 2020, 11:49pm
11
Which package are you receiving INFO messages from? Just turn them off.
aingidh
(Thomas H.)
November 30, 2020, 12:18pm
12
hilbrand:
org.openhab.binding.homematic.internal.misc.MiscUtils
from org.openhab.binding.homematic.internal.misc.MiscUtils, like
[INFO ] [ing.homematic.internal.misc.MiscUtils] - Datapoint name '${sysVarAlarmZone1}' contains invalid characters, new Datapoint name '__sysVarAlarmZone1_'
I want only warnings from this package, but somehow I am unable to configure this.
I did
log:set WARN org.openhab.binding.homematic.internal.misc.MiscUtils
but that didnΒ΄t do anything.
namraccr
(namraccr)
November 30, 2020, 1:35pm
13
I believe you need either
log:set WARN org.openhab.binding.homematic.internal.misc
or just
log:set WARN org.openhab.binding.homematic
1 Like
aingidh
(Thomas H.)
November 30, 2020, 2:14pm
14
Thanks,
log:set WARN org.openhab.binding.homematic.internal.misc
did it!
But I would consider this a bug, the package in the log message should be the same are for the level to setβ¦
hilbrand
(Hilbrand Bouwkamp)
November 30, 2020, 3:53pm
15
Setting log level should be done on packages. MiscUtils
is a class and thus should not be part of the setting of the log level. (Apparently I missed that in my comment as I was only looking at the invalid left part of the package in the comment I gave). Not sure what you consider a bug though?
aingidh
(Thomas H.)
November 30, 2020, 5:20pm
16
Maybe itΒ΄s not a bug, but my code usually logs on class level and not on package level so that you can set a level for every class or the whole package.