2016-06-04 18:39:05 +00:00
---
layout: documentation
2016-08-05 10:10:20 +00:00
title: Logging
2016-06-04 18:39:05 +00:00
---
{% include base.html %}
2016-06-11 10:48:53 +00:00
# Logging in openHAB
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
This article describes the logging functionality in openHAB.
2018-11-19 12:00:40 +00:00
This includes how to access logging information and configure logging for user-defined rules.
2016-06-04 18:39:05 +00:00
There are two ways to check log entries:
2016-11-12 18:28:23 +00:00
1. Through files stored on the **file system**
2. During runtime in the **Karaf Console**
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
## Filesystem
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
Log files are written to either `userdata/log` (manual setup) or `/var/log/openhab` (package based setup) and can be accessed using standard OS tools for text files. The default installation of openHAB generates two log files:
2016-06-04 18:39:05 +00:00
2016-11-12 18:28:23 +00:00
- `events.log`
- `openhab.log`
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
## Console
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
The [openHAB console ](console.html ) allows to monitor the log in real-time.
2016-06-04 18:39:05 +00:00
2016-06-11 10:48:53 +00:00
The log shell comes with the following commands:
2016-06-04 18:39:05 +00:00
2018-11-19 12:00:40 +00:00
| Log Command | Description |
|-------------------------|-------------------------------------------------------------------|
| `log:clear` | Clear log entries |
| `log:display` | Display the last log entries |
| `log:exception-display` | Displays the last occurred exception from the log |
| `log:get` | Show the currently set log level |
| `log:list` | List the currently set loggers with their levels |
| `log:log` | Log a message |
| `log:set` | Set the log level |
| `log:tail` | Continuously display log entries. Use ctrl-c to quit this command |
2016-06-04 18:39:05 +00:00
2018-11-19 12:00:40 +00:00
For example, the following command enables the real-time monitoring of the default log:
2016-06-04 18:39:05 +00:00
```
2016-06-11 10:48:53 +00:00
openhab> log:tail
2016-08-02 09:35:18 +00:00
20:38:00.031 [DEBUG] [sistence.rrd4j.internal.RRD4jService] - Stored 'Temperature_FF_Child' with state '19.1' in rrd4j database
20:38:00.032 [DEBUG] [sistence.rrd4j.internal.RRD4jService] - Stored 'Temperature_FF_Bed' with state '19.5' in rrd4j database
20:38:20.463 [DEBUG] [thome.io.rest.core.item.ItemResource] - Received HTTP POST request at 'items/Light_FF_Bath_Ceiling' with value 'ON'.
20:38:21.444 [DEBUG] [thome.io.rest.core.item.ItemResource] - Received HTTP POST request at 'items/Light_FF_Bath_Mirror' with value 'ON'.
2016-06-11 10:48:53 +00:00
```
2018-01-04 21:29:53 +00:00
A useful functionality is that filters can be applied:
2016-06-04 18:39:05 +00:00
2016-06-11 10:48:53 +00:00
```
2020-12-12 11:27:08 +00:00
openhab> log:tail org.openhab.io.rest.core.item.ItemResource
2016-08-02 09:35:18 +00:00
20:36:52.879 [DEBUG] [thome.io.rest.core.item.ItemResource] - Received HTTP POST request at 'items/Light_FF_Bath_Ceiling' with value 'ON'.
20:36:53.545 [DEBUG] [thome.io.rest.core.item.ItemResource] - Received HTTP POST request at 'items/Light_FF_Bath_Ceiling' with value 'OFF'.
2016-06-11 10:48:53 +00:00
```
2016-06-04 18:39:05 +00:00
2016-06-11 10:48:53 +00:00
Please see the [Karaf documentation ](http://karaf.apache.org/manual/latest/#_commands_2 ) for more examples and details.
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
## Config file
2016-11-12 18:28:23 +00:00
2020-12-13 14:52:45 +00:00
The config file for logging is located in the `userdata/etc` folder (manual setup) or in `/var/lib/openhab/etc` (apt/deb-based setup).
::: tip Attention OH2 users
The format and filename to store log settings has changed. It used to be `org.ops4j.pax.logging.cfg` in openHAB 2 and became `log4j2.xml` in openHAB 3.
:::
2016-06-04 18:39:05 +00:00
2016-06-11 10:48:53 +00:00
## Defining what to log
2016-06-04 18:39:05 +00:00
2018-11-19 12:00:40 +00:00
By default, openHAB comes with logging enabled for several standard packages.
In order to enable logging for additional packages, you need to define what should be logged and in which detail.
This can be done in Karaf using the following console command:
2016-06-04 18:39:05 +00:00
2016-11-12 18:28:23 +00:00
```text
2016-06-04 18:39:05 +00:00
log:set LEVEL package.subpackage
```
2018-11-19 12:00:40 +00:00
The **what** is defined by `package.subpackage` and is in most cases a binding (like `org.openhab.binding.zwave` ).
2016-06-04 18:39:05 +00:00
The **detail** of logging is defined by one of the following levels:
2019-01-13 13:25:05 +00:00
| Log Level | Log Weight | When it should be used |
|-----------|------------|-----------------------------------------------------------------------------------------|
| OFF | 0 | When no events will be logged |
| ERROR | 200 | When an error in the application, possibly recoverable |
| WARN | 300 | When an event that might possible lead to an error |
| INFO | 400 | When an event for informational purposes |
| DEBUG | 500 | When a general debugging event required |
| TRACE | 600 | When a fine grained debug message, typically capturing the flow through the application |
| ALL | MAX | When all events should be logged |
2018-11-19 12:00:40 +00:00
The levels build a hierarchy with **ERROR** logging critical messages only and **DEBUG** logging nearly everything.
**DEBUG** combines all logs from weight 100 to 500, while **TRACE** adds further messages in addition to what **DEBUG** displays.
**ALL** includes every log level from weight 100 to 600.
2017-01-22 13:31:39 +00:00
Setting the log level to **DEFAULT** will log to the level defined in the package.subpackage (in most cases a binding).
2016-06-04 18:39:05 +00:00
Merge 2.5.x into main (#1266)
* Update README (2.5.x) (#1153)
Change branch name.
Signed-off-by: Yannick Schaus <github@schaus.net>
* Update items.md (#1156)
* Added var and VA units to UoM (#1146)
VA (Volt-Ampere - apparent power) and var (Volt-Ampere reactive) are used to measure power and energy consumption in AC circuits.
Signed-off-by: Nagy Attila Gabor <mrbig@sneaker.hu>
* Fix filepath to keystore (#1148)
Default openHAB userdata environment variable should be `$OPENHAB_USERDATA`, not `$USER_DATA` shouldn't it? At least, this is the default on my fresh openHABian and also the most popular variant to find in the docs.
* Slight language corrections (#1150)
I think it reads better this way
Signed-off-by: Richard Davies <rwdrich@gmail.com>
* additional example for non default persistence service (#1152)
For me it was confusing how to pass on the serviceId into methods that already had an argument. An extra example is always good.
Signed-off-by: jaco <jaco.waes@gmail.com>
* Adding 12 new logos for OH Add-Ons page on website (#1158)
Signed-off-by: bracklanna bracklanna@users.noreply.github.com
* Added missing preset variables (#1104)
* Added missing preset variables
Signed-off-by: Scott Rushworth <openhab@5iver.com>
* Cleaned up blank lines, fixed table, and added file name for SimpleRule
Signed-off-by: Scott Rushworth <openhab@5iver.com>
* Fix broken link (#1165)
* Added Hotlink from "label" section to "state presentation" (#1167)
* Added note about broken action (#1164)
* Added note about broken action
See https://github.com/openhab/openhab-core/issues/1374
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Incorporated changes from review
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Incorporated changes from review
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Update index.md (#1170)
Link appears to be wrong and does not work when I click on it in Edge. Loads the same page again instead of loading the correct new page from the hyperlink.
https://www.openhab.org/docs/developer/guidelines.html
* Added Airthings logo (#1171)
* typo in exambp (#1172)
`Temperature.averageSince(now.minusMinutes(5),"influxdb")`
* file.encoding=UTF-8 (#1173)
* Update demo URL and add demo.rules URL (#1174)
Based on: https://community.openhab.org/t/demo-setup-missing/94850
Old Link is broken leading to 404.
The link to the demo.rules on github is an extra :)
* Replace outdated zulu.org link. (#1177)
* Replace outdated zulu.org link.
As of 3/23/2020 zulu.org has an SSL cert that expired on 9/28/2019. Changed link to azul.com/downloads, since that appears to be the new official source.
Signed-off-by: Billy Stevens <contact@wasv.me>
* Changed all http links to https for installation/index.md.
All changed links working, tested on 3/24/2020.
Signed-off-by: Billy Stevens <contact@wasv.me>
* Minor language tweak (#1178)
* Ending an active scan/stopScan (#1179)
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Add files via upload (#1184)
* Update persistence.md (#1185)
Clarify return objects for max/min rules extensions.
Signed-off-by: Ross Kennedy rossko@culzean.clara.co.uk
* Update things.md (#1186)
Amended example code to include using label and location when defining a Thing with a bridge that is defined elsewhere.
* Correct typos (#1190)
* Correct usage of its/it's
"It's" is always a contraction of "it is" or "it has". "Its" is a
possessive. Correct a few places where they were used backwards.
Signed-off-by: Bjorn Helgaas <bjorn@helgaas.com>
* Correct "Z-Wave" spelling
Per https://www.z-wave.com/, the canonical spelling appears to be "Z-Wave".
Most places use "Z-Wave" already; change the remaining references to match.
Signed-off-by: Bjorn Helgaas <bjorn@helgaas.com>
* Correct typos and grammatical errors
Correct some typos and grammatical errors.
Signed-off-by: Bjorn Helgaas <bjorn@helgaas.com>
* Update sitemap.md section charts (#1191)
I observed that the unique first word in the labels of items charted in a group isn't causing an empty chart anymore. I'm on openHAB 2.5.1.
Signed-off-by: Juergen Baginski opus42@gmx.de
* Add image for insteon binding (#1196)
Signed-off-by: Rob Nielsen <rob.nielsen@yahoo.com>
* typo (#1198)
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Installation details (#1197)
Added more details around the installation and configuration process.
Fixed that engine no longer logs "Activated scripting support..."
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Update sitemaps.md (#1202)
Added full item definition for usage of visibility. See https://community.openhab.org/t/sitemap-visibility-basic-ui/97304/9
* Updated ecobee logo (https://brand.ecobee.com/) (#1203)
Signed-off-by: Rob Nielsen <rob.nielsen@yahoo.com>
* tutorial: Fix description of sitemap 'type' (#1204)
In the tutorial, the generic sitemap description says that ItemType has
to be the same as the type defined in default.items.
Looking at
https://www.openhab.org/docs/configuration/items.html#type and
https://www.openhab.org/docs/configuration/sitemaps.html#element-types
this is incorrect as they take different values.
The example is even mislading as `Switch` is one of the only types which
is common between items and sitemaps. Might be better to describe
`Default` instead.
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
* Added information about DateTime Group functions LATEST/EARLIEST (#1206)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Add section for documentation contributions (#1205)
Hopefully this will lower the hurdle for people to submit documentation contributions. I know from myself that I didn't submit various documentation improvements, because I didn't know git and thought it would be a much more involved process.
Ideally there would be a separate documentation section, but submitting this under the development contribution page for now (as per discussion with @Confectrician in https://github.com/openhab/openhab-docs/pull/1179#issuecomment-605642091).
Note that I am addressing the issue of DCO failures wrt specifying the full name that I ran into myself in https://github.com/openhab/openhab-docs/pull/1197#issuecomment-615597308. I found a good discussion of the issue at https://github.com/probot/dco/issues/43.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* fix typo (#1209)
* add description of Ephemeris localization support (#1210)
Add a new section to describe the localization support and how-to steps
Signed-off-by: Michael Roßner Schrott.Micha@web.de
* Line 115 broken link - should be: (#1217)
* Line 115 broken link - should be:
({{base}}/docs/configuration/sitemaps.html#element-types)
was:
({{base}}/configuration/configuration/sitemaps.html#element-types)
* Removed diplicated docs breadcrumb
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
* add missing space between words (#1212)
* Update configuration.md (#1215)
I'm a beginner myself. Though I liked this tutorial very much, it took me some time trying and erroring and finally reading forum posts to get behind this. I didn't even know there was something like a more modern ping. So maybe others are happy to learn this right from the beginning.
* Remove architecture from Docker tags (#1220)
Docker automatically detects the architecture and downloads the appropriate image (openhab/openhab-docker#213).
BuildKit will no longer generate new tags having the architecture (openhab/openhab-docker#293).
Signed-off-by: Wouter Born <github@maindrain.net>
* slight readability improvements (#1221)
* slight readability improvements
* Update introduction.md
* Update introduction.md
* minor wording update
* Update eclipse.md (#1225)
Clarifying that it's no longer possible to make changes in the Core Framework for 2.5.x.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* [fmiweather] logo for FMI Weather binding (#929)
Signed-off-by: Sami Salonen <ssalonen@gmail.com>
* Update eclipse.md (#1226)
Added additional structure around install, run, debug and update steps. Provided more pointers to interactions with Eclipse, Maven and Git.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Update contributing.md (#1227)
Need to escape \< and \> in the sign off message format so users see them explicitly in the Contributing to the Documentation section.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Update contributing.md (#1228)
Small refinement on documentation change submission flow.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Add doc folder to the binding directory structure (#1230)
Signed-off-by: Fabian Wolter <github@fabian-wolter.de>
* Make Subheadings Use Proper Subheading Syntax (#1234)
This way they render out as proper markdown and don't look weird on the website
Signed-off-by: Stefan Zabka <zabkaste@informatik.hu-berlin.de>
* Remove unnecessary isCancelled() from code example (#1235)
Cancelling an already canceled task has no effect. IMHO this check is not necesssary and removal would simplify the code. I came to this because I saw this pattern in many bindings during reviewing.
Signed-off-by: Fabian Wolter <github@fabian-wolter.de>
* Update thing-xml.md (#1236)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Fix broken ESH links (#1231)
Signed-off-by: Wouter Born <github@maindrain.net>
* Update logging.md (#1238)
Add information on how to find out the symbolic names of the bundles
* Remove Apache Commons from Default Libraries (#1229)
See openhab/openhab-addons#7722
Signed-off-by: Fabian Wolter <git@fabian-wolter.de>
* Update introduction.md (#1239)
* Update introduction.md
Signed-off-by: Markus Storm markus.storm@gmx.net
* Update introduction.md
* Revise Java recommendations (#1240)
* Revise Java recommendations
* Delete pine.md
Do not recommend PINE, it's not supported any longer by openHABian.
* Removed sidebar link in config
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
* Update security.md (#1241)
Been using FreeDNS for many years (ever since all these companies got rid of their free tiers) and never an issue!
* Fix DecimalType hex conversion example (#1243)
See: https://github.com/openhab/openhab-core/issues/1526
Signed-off-by: Wouter Born <github@maindrain.net>
* Fix typo (#1244)
Signed-off-by: Wouter Born <github@maindrain.net>
* Update persistence.md (#1246)
Fixes link to quartz docs page.
* Revision. (openhab#1187) (#1237)
* Revision. (openhab#1187)
- Update of screenshots, removal of old screenshots
- Chapters for better formatting
- Removal of ZWave chapter (one example of adding things should be enough IMHO)
- Adding items in simple mode and in "manual" mode
Signed-off-by: Sascha Billian <sascha.billian@googlemail.com>
* Use one line per sentence
Signed-off-by: Sascha Billian <sascha.billian@googlemail.com>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
* Add notes for configuring Synology Diskstation (#1219)
* Add notes for configuring Synology Diskstation
I have a working set up for SSL enabled remote access on a Synology diskstation, taking advantage of the GUI as much as possible, to ensure automatic renewal of certs from Let's Encrypt, etc. It took me about 8 hours to suss it all out, but it could be achieved in about 30 mins if you knew exactly what to do... may not be widely useful, but since Synology is officially supported, I figured this might be a good addition.
There's also a minor error in the 'allow' masks - these should be 192.168.0.0/24 to allow access to anything in the 192.168.0.xxx range.
* Updated to use one line per sentence
Updated to use one line per sentence - sorry for the delay!
* Update security.md
* Updated for one line per sentence
Updated for one line per sentence
Signed-off-by: Andrew Mills mills@prettymachine.co.nz
* Bad subnet (#1245)
Nginx warns about low address bits of `192.168.0.1/24` because they are meaningless.
The correct subnet mask should be `192.168.0.0/24`
Signed-off-by: Olivier Béraud <olivierberaud@free.fr>
* Fixed broken images. (#1247)
* Fixed broken images.
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
* Fix image path
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
* [documentation] clarification of representation property (#1248)
* [documentation] clarification of representation property
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] adopt suggestions of reviewers
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] commas
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] addopted suggestions of @bobadair
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentaion] example added back
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentaion] simplified text
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] adopted reviewer comment
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* Add Alexa mapping along side a channel mapping (#1249)
* Add Alexa mapping along side a channel mapping
It took me a while to find this https://community.openhab.org/t/tagging-devices-for-alexa-support/98155/3 on the Forum and its not clearly documented in the openHAB Amazon Alexa Smart Home Skill or here in Item Metadata.
I originally suggested this as an update to the openHAB Amazon Alexa Smart Home Skill documentaion, but it fits better here, then other integrations using metadata (e.g. HomeKit or Google Assistant) could refer to it as well.
* Update items.md
* Mention defaults for element type setpoint. (#1250)
Mention defaults for min, max and step value for element type setpoint.
Signed-off-by: Thomas Weiler <toweosp@gmail.com>
* Update index.md (#1251)
I thought 'workl' was probably intended to be 'work'.
* Items - Bedroom_Light written as Light_Bedroom (#1252)
Fix small error which might mislead some readers.
* Added example for time-weighted averages (#1253)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Remove deprecated UIs, Eclipse Marketplace from sidebar
Signed-off-by: Yannick Schaus <github@schaus.net>
* Update branch name in README
Signed-off-by: Yannick Schaus <github@schaus.net>
Co-authored-by: Markus Storm <markus.storm@gmx.net>
Co-authored-by: Nagy Attila Gábor <mrbig@sneaker.hu>
Co-authored-by: Christoph Thiede <38782922+LinqLover@users.noreply.github.com>
Co-authored-by: Richard Davies <rwdrich@gmail.com>
Co-authored-by: jwaes <50528773+jwaes@users.noreply.github.com>
Co-authored-by: bracklanna <16140600+bracklanna@users.noreply.github.com>
Co-authored-by: Scott Rushworth <openhab@5iver.com>
Co-authored-by: cpmeister <mistercpp2000@gmail.com>
Co-authored-by: Ross Kennedy <rossko@culzean.clara.co.uk>
Co-authored-by: Christoph Weitkamp <github@christophweitkamp.de>
Co-authored-by: Skinah <32607303+Skinah@users.noreply.github.com>
Co-authored-by: pali <pauli.anttila@gmail.com>
Co-authored-by: ljsquare <laurens-jan@merkx-ewals.nl>
Co-authored-by: PatrikG <40170469+PatrikG8@users.noreply.github.com>
Co-authored-by: Elias H <E.Hackradt@web.de>
Co-authored-by: Billy Stevens <contact@wasv.me>
Co-authored-by: theiding <mark.theiding@gmail.com>
Co-authored-by: jadcx <60408305+jadcx@users.noreply.github.com>
Co-authored-by: Bjorn Helgaas <bjorn@helgaas.com>
Co-authored-by: Jürgen Baginski <opus42@gmx.de>
Co-authored-by: robnielsen <rob.nielsen@yahoo.com>
Co-authored-by: GumbyMan82 <40233411+GumbyMan82@users.noreply.github.com>
Co-authored-by: Christophe Fergeau <teuf@gnome.org>
Co-authored-by: Paulo "JCranky" Siqueira <paulo.siqueira@gmail.com>
Co-authored-by: Michael Rossner <Schrott.Micha@web.de>
Co-authored-by: BugSmurF <52825547+bugsmurf@users.noreply.github.com>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
Co-authored-by: josefscript <64727123+josefscript@users.noreply.github.com>
Co-authored-by: Wouter Born <github@maindrain.net>
Co-authored-by: Sami Salonen <ssalonen@gmail.com>
Co-authored-by: Fabian Wolter <github@fabian-wolter.de>
Co-authored-by: Stefan Zabka <zabkaste@informatik.hu-berlin.de>
Co-authored-by: TRS-80 <25938297+TRSx80@users.noreply.github.com>
Co-authored-by: sihui <10405486+sihui62@users.noreply.github.com>
Co-authored-by: Andrew Mills <amil109@users.noreply.github.com>
Co-authored-by: Olivier Béraud <olivbd@users.noreply.github.com>
Co-authored-by: Andrew Fiddian-Green <software@whitebear.ch>
Co-authored-by: LeeC77 <LeeC77@users.noreply.github.com>
Co-authored-by: Thomas Weiler <18066810+toweosp@users.noreply.github.com>
Co-authored-by: garretcook <garretcook@gmail.com>
Co-authored-by: Michael Fielding <michael.fielding@gmail.com>
2020-09-21 11:29:39 +00:00
If the name of `package.subpackage` is not known, the name can be found out in the console:
```text
list -s
```
returns a list of all modules and the last column contains the information about the symbolic name of the bundle:
```text
openhab> list -s
START LEVEL 100 , List Threshold: 50
ID │ State │ Lvl │ Version │ Symbolic name
────┼────────┼─────┼─────────────────────────┼───────────────────────────────────────────────────────────────────────────────────────────────────────────────────
19 │ Active │ 80 │ 5.3.1.201602281253 │ com.eclipsesource.jaxrs.publisher
20 │ Active │ 80 │ 2.8.2.v20180104-1110 │ com.google.gson
21 │ Active │ 80 │ 18.0.0 │ com.google.guava
22 │ Active │ 80 │ 27.1.0.jre │ com.google.guava
23 │ Active │ 80 │ 1.0.1 │ com.google.guava.failureaccess
24 │ Active │ 80 │ 3.0.0.v201312141243 │ com.google.inject
```
The list can be also filtered with grep. To find out the Z-Wave binding the following command can be used
```Text
openhab> list -s | grep zwave
253 x Active x 80 x 2.5.5 x org.openhab.binding.zwave
```
2016-11-12 18:28:23 +00:00
Following example sets the logging for the Z-Wave binding to **DEBUG**
2016-06-04 18:39:05 +00:00
2016-11-12 18:28:23 +00:00
```text
2016-07-16 19:50:38 +00:00
log:set DEBUG org.openhab.binding.zwave
2016-06-04 18:39:05 +00:00
```
Merge 2.5.x into main (#1266)
* Update README (2.5.x) (#1153)
Change branch name.
Signed-off-by: Yannick Schaus <github@schaus.net>
* Update items.md (#1156)
* Added var and VA units to UoM (#1146)
VA (Volt-Ampere - apparent power) and var (Volt-Ampere reactive) are used to measure power and energy consumption in AC circuits.
Signed-off-by: Nagy Attila Gabor <mrbig@sneaker.hu>
* Fix filepath to keystore (#1148)
Default openHAB userdata environment variable should be `$OPENHAB_USERDATA`, not `$USER_DATA` shouldn't it? At least, this is the default on my fresh openHABian and also the most popular variant to find in the docs.
* Slight language corrections (#1150)
I think it reads better this way
Signed-off-by: Richard Davies <rwdrich@gmail.com>
* additional example for non default persistence service (#1152)
For me it was confusing how to pass on the serviceId into methods that already had an argument. An extra example is always good.
Signed-off-by: jaco <jaco.waes@gmail.com>
* Adding 12 new logos for OH Add-Ons page on website (#1158)
Signed-off-by: bracklanna bracklanna@users.noreply.github.com
* Added missing preset variables (#1104)
* Added missing preset variables
Signed-off-by: Scott Rushworth <openhab@5iver.com>
* Cleaned up blank lines, fixed table, and added file name for SimpleRule
Signed-off-by: Scott Rushworth <openhab@5iver.com>
* Fix broken link (#1165)
* Added Hotlink from "label" section to "state presentation" (#1167)
* Added note about broken action (#1164)
* Added note about broken action
See https://github.com/openhab/openhab-core/issues/1374
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Incorporated changes from review
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Incorporated changes from review
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Update index.md (#1170)
Link appears to be wrong and does not work when I click on it in Edge. Loads the same page again instead of loading the correct new page from the hyperlink.
https://www.openhab.org/docs/developer/guidelines.html
* Added Airthings logo (#1171)
* typo in exambp (#1172)
`Temperature.averageSince(now.minusMinutes(5),"influxdb")`
* file.encoding=UTF-8 (#1173)
* Update demo URL and add demo.rules URL (#1174)
Based on: https://community.openhab.org/t/demo-setup-missing/94850
Old Link is broken leading to 404.
The link to the demo.rules on github is an extra :)
* Replace outdated zulu.org link. (#1177)
* Replace outdated zulu.org link.
As of 3/23/2020 zulu.org has an SSL cert that expired on 9/28/2019. Changed link to azul.com/downloads, since that appears to be the new official source.
Signed-off-by: Billy Stevens <contact@wasv.me>
* Changed all http links to https for installation/index.md.
All changed links working, tested on 3/24/2020.
Signed-off-by: Billy Stevens <contact@wasv.me>
* Minor language tweak (#1178)
* Ending an active scan/stopScan (#1179)
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Add files via upload (#1184)
* Update persistence.md (#1185)
Clarify return objects for max/min rules extensions.
Signed-off-by: Ross Kennedy rossko@culzean.clara.co.uk
* Update things.md (#1186)
Amended example code to include using label and location when defining a Thing with a bridge that is defined elsewhere.
* Correct typos (#1190)
* Correct usage of its/it's
"It's" is always a contraction of "it is" or "it has". "Its" is a
possessive. Correct a few places where they were used backwards.
Signed-off-by: Bjorn Helgaas <bjorn@helgaas.com>
* Correct "Z-Wave" spelling
Per https://www.z-wave.com/, the canonical spelling appears to be "Z-Wave".
Most places use "Z-Wave" already; change the remaining references to match.
Signed-off-by: Bjorn Helgaas <bjorn@helgaas.com>
* Correct typos and grammatical errors
Correct some typos and grammatical errors.
Signed-off-by: Bjorn Helgaas <bjorn@helgaas.com>
* Update sitemap.md section charts (#1191)
I observed that the unique first word in the labels of items charted in a group isn't causing an empty chart anymore. I'm on openHAB 2.5.1.
Signed-off-by: Juergen Baginski opus42@gmx.de
* Add image for insteon binding (#1196)
Signed-off-by: Rob Nielsen <rob.nielsen@yahoo.com>
* typo (#1198)
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Installation details (#1197)
Added more details around the installation and configuration process.
Fixed that engine no longer logs "Activated scripting support..."
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Update sitemaps.md (#1202)
Added full item definition for usage of visibility. See https://community.openhab.org/t/sitemap-visibility-basic-ui/97304/9
* Updated ecobee logo (https://brand.ecobee.com/) (#1203)
Signed-off-by: Rob Nielsen <rob.nielsen@yahoo.com>
* tutorial: Fix description of sitemap 'type' (#1204)
In the tutorial, the generic sitemap description says that ItemType has
to be the same as the type defined in default.items.
Looking at
https://www.openhab.org/docs/configuration/items.html#type and
https://www.openhab.org/docs/configuration/sitemaps.html#element-types
this is incorrect as they take different values.
The example is even mislading as `Switch` is one of the only types which
is common between items and sitemaps. Might be better to describe
`Default` instead.
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
* Added information about DateTime Group functions LATEST/EARLIEST (#1206)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Add section for documentation contributions (#1205)
Hopefully this will lower the hurdle for people to submit documentation contributions. I know from myself that I didn't submit various documentation improvements, because I didn't know git and thought it would be a much more involved process.
Ideally there would be a separate documentation section, but submitting this under the development contribution page for now (as per discussion with @Confectrician in https://github.com/openhab/openhab-docs/pull/1179#issuecomment-605642091).
Note that I am addressing the issue of DCO failures wrt specifying the full name that I ran into myself in https://github.com/openhab/openhab-docs/pull/1197#issuecomment-615597308. I found a good discussion of the issue at https://github.com/probot/dco/issues/43.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* fix typo (#1209)
* add description of Ephemeris localization support (#1210)
Add a new section to describe the localization support and how-to steps
Signed-off-by: Michael Roßner Schrott.Micha@web.de
* Line 115 broken link - should be: (#1217)
* Line 115 broken link - should be:
({{base}}/docs/configuration/sitemaps.html#element-types)
was:
({{base}}/configuration/configuration/sitemaps.html#element-types)
* Removed diplicated docs breadcrumb
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
* add missing space between words (#1212)
* Update configuration.md (#1215)
I'm a beginner myself. Though I liked this tutorial very much, it took me some time trying and erroring and finally reading forum posts to get behind this. I didn't even know there was something like a more modern ping. So maybe others are happy to learn this right from the beginning.
* Remove architecture from Docker tags (#1220)
Docker automatically detects the architecture and downloads the appropriate image (openhab/openhab-docker#213).
BuildKit will no longer generate new tags having the architecture (openhab/openhab-docker#293).
Signed-off-by: Wouter Born <github@maindrain.net>
* slight readability improvements (#1221)
* slight readability improvements
* Update introduction.md
* Update introduction.md
* minor wording update
* Update eclipse.md (#1225)
Clarifying that it's no longer possible to make changes in the Core Framework for 2.5.x.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* [fmiweather] logo for FMI Weather binding (#929)
Signed-off-by: Sami Salonen <ssalonen@gmail.com>
* Update eclipse.md (#1226)
Added additional structure around install, run, debug and update steps. Provided more pointers to interactions with Eclipse, Maven and Git.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Update contributing.md (#1227)
Need to escape \< and \> in the sign off message format so users see them explicitly in the Contributing to the Documentation section.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Update contributing.md (#1228)
Small refinement on documentation change submission flow.
Signed-off-by: Mark Theiding <mark.theiding@gmail.com>
* Add doc folder to the binding directory structure (#1230)
Signed-off-by: Fabian Wolter <github@fabian-wolter.de>
* Make Subheadings Use Proper Subheading Syntax (#1234)
This way they render out as proper markdown and don't look weird on the website
Signed-off-by: Stefan Zabka <zabkaste@informatik.hu-berlin.de>
* Remove unnecessary isCancelled() from code example (#1235)
Cancelling an already canceled task has no effect. IMHO this check is not necesssary and removal would simplify the code. I came to this because I saw this pattern in many bindings during reviewing.
Signed-off-by: Fabian Wolter <github@fabian-wolter.de>
* Update thing-xml.md (#1236)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Fix broken ESH links (#1231)
Signed-off-by: Wouter Born <github@maindrain.net>
* Update logging.md (#1238)
Add information on how to find out the symbolic names of the bundles
* Remove Apache Commons from Default Libraries (#1229)
See openhab/openhab-addons#7722
Signed-off-by: Fabian Wolter <git@fabian-wolter.de>
* Update introduction.md (#1239)
* Update introduction.md
Signed-off-by: Markus Storm markus.storm@gmx.net
* Update introduction.md
* Revise Java recommendations (#1240)
* Revise Java recommendations
* Delete pine.md
Do not recommend PINE, it's not supported any longer by openHABian.
* Removed sidebar link in config
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
* Update security.md (#1241)
Been using FreeDNS for many years (ever since all these companies got rid of their free tiers) and never an issue!
* Fix DecimalType hex conversion example (#1243)
See: https://github.com/openhab/openhab-core/issues/1526
Signed-off-by: Wouter Born <github@maindrain.net>
* Fix typo (#1244)
Signed-off-by: Wouter Born <github@maindrain.net>
* Update persistence.md (#1246)
Fixes link to quartz docs page.
* Revision. (openhab#1187) (#1237)
* Revision. (openhab#1187)
- Update of screenshots, removal of old screenshots
- Chapters for better formatting
- Removal of ZWave chapter (one example of adding things should be enough IMHO)
- Adding items in simple mode and in "manual" mode
Signed-off-by: Sascha Billian <sascha.billian@googlemail.com>
* Use one line per sentence
Signed-off-by: Sascha Billian <sascha.billian@googlemail.com>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
* Add notes for configuring Synology Diskstation (#1219)
* Add notes for configuring Synology Diskstation
I have a working set up for SSL enabled remote access on a Synology diskstation, taking advantage of the GUI as much as possible, to ensure automatic renewal of certs from Let's Encrypt, etc. It took me about 8 hours to suss it all out, but it could be achieved in about 30 mins if you knew exactly what to do... may not be widely useful, but since Synology is officially supported, I figured this might be a good addition.
There's also a minor error in the 'allow' masks - these should be 192.168.0.0/24 to allow access to anything in the 192.168.0.xxx range.
* Updated to use one line per sentence
Updated to use one line per sentence - sorry for the delay!
* Update security.md
* Updated for one line per sentence
Updated for one line per sentence
Signed-off-by: Andrew Mills mills@prettymachine.co.nz
* Bad subnet (#1245)
Nginx warns about low address bits of `192.168.0.1/24` because they are meaningless.
The correct subnet mask should be `192.168.0.0/24`
Signed-off-by: Olivier Béraud <olivierberaud@free.fr>
* Fixed broken images. (#1247)
* Fixed broken images.
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
* Fix image path
Signed-off-by: Jerome Luckenbach <github@luckenba.ch>
* [documentation] clarification of representation property (#1248)
* [documentation] clarification of representation property
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] adopt suggestions of reviewers
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] commas
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] addopted suggestions of @bobadair
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentaion] example added back
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentaion] simplified text
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] typo
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* [documentation] adopted reviewer comment
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
* Add Alexa mapping along side a channel mapping (#1249)
* Add Alexa mapping along side a channel mapping
It took me a while to find this https://community.openhab.org/t/tagging-devices-for-alexa-support/98155/3 on the Forum and its not clearly documented in the openHAB Amazon Alexa Smart Home Skill or here in Item Metadata.
I originally suggested this as an update to the openHAB Amazon Alexa Smart Home Skill documentaion, but it fits better here, then other integrations using metadata (e.g. HomeKit or Google Assistant) could refer to it as well.
* Update items.md
* Mention defaults for element type setpoint. (#1250)
Mention defaults for min, max and step value for element type setpoint.
Signed-off-by: Thomas Weiler <toweosp@gmail.com>
* Update index.md (#1251)
I thought 'workl' was probably intended to be 'work'.
* Items - Bedroom_Light written as Light_Bedroom (#1252)
Fix small error which might mislead some readers.
* Added example for time-weighted averages (#1253)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
* Remove deprecated UIs, Eclipse Marketplace from sidebar
Signed-off-by: Yannick Schaus <github@schaus.net>
* Update branch name in README
Signed-off-by: Yannick Schaus <github@schaus.net>
Co-authored-by: Markus Storm <markus.storm@gmx.net>
Co-authored-by: Nagy Attila Gábor <mrbig@sneaker.hu>
Co-authored-by: Christoph Thiede <38782922+LinqLover@users.noreply.github.com>
Co-authored-by: Richard Davies <rwdrich@gmail.com>
Co-authored-by: jwaes <50528773+jwaes@users.noreply.github.com>
Co-authored-by: bracklanna <16140600+bracklanna@users.noreply.github.com>
Co-authored-by: Scott Rushworth <openhab@5iver.com>
Co-authored-by: cpmeister <mistercpp2000@gmail.com>
Co-authored-by: Ross Kennedy <rossko@culzean.clara.co.uk>
Co-authored-by: Christoph Weitkamp <github@christophweitkamp.de>
Co-authored-by: Skinah <32607303+Skinah@users.noreply.github.com>
Co-authored-by: pali <pauli.anttila@gmail.com>
Co-authored-by: ljsquare <laurens-jan@merkx-ewals.nl>
Co-authored-by: PatrikG <40170469+PatrikG8@users.noreply.github.com>
Co-authored-by: Elias H <E.Hackradt@web.de>
Co-authored-by: Billy Stevens <contact@wasv.me>
Co-authored-by: theiding <mark.theiding@gmail.com>
Co-authored-by: jadcx <60408305+jadcx@users.noreply.github.com>
Co-authored-by: Bjorn Helgaas <bjorn@helgaas.com>
Co-authored-by: Jürgen Baginski <opus42@gmx.de>
Co-authored-by: robnielsen <rob.nielsen@yahoo.com>
Co-authored-by: GumbyMan82 <40233411+GumbyMan82@users.noreply.github.com>
Co-authored-by: Christophe Fergeau <teuf@gnome.org>
Co-authored-by: Paulo "JCranky" Siqueira <paulo.siqueira@gmail.com>
Co-authored-by: Michael Rossner <Schrott.Micha@web.de>
Co-authored-by: BugSmurF <52825547+bugsmurf@users.noreply.github.com>
Co-authored-by: Jerome Luckenbach <github@luckenba.ch>
Co-authored-by: josefscript <64727123+josefscript@users.noreply.github.com>
Co-authored-by: Wouter Born <github@maindrain.net>
Co-authored-by: Sami Salonen <ssalonen@gmail.com>
Co-authored-by: Fabian Wolter <github@fabian-wolter.de>
Co-authored-by: Stefan Zabka <zabkaste@informatik.hu-berlin.de>
Co-authored-by: TRS-80 <25938297+TRSx80@users.noreply.github.com>
Co-authored-by: sihui <10405486+sihui62@users.noreply.github.com>
Co-authored-by: Andrew Mills <amil109@users.noreply.github.com>
Co-authored-by: Olivier Béraud <olivbd@users.noreply.github.com>
Co-authored-by: Andrew Fiddian-Green <software@whitebear.ch>
Co-authored-by: LeeC77 <LeeC77@users.noreply.github.com>
Co-authored-by: Thomas Weiler <18066810+toweosp@users.noreply.github.com>
Co-authored-by: garretcook <garretcook@gmail.com>
Co-authored-by: Michael Fielding <michael.fielding@gmail.com>
2020-09-21 11:29:39 +00:00
2018-11-19 12:00:40 +00:00
Note that the log levels set using the `log:set` commands are persistent and will be applied upon restart.
To modify the stored log levels, use the console or edit the [configuration file ](#config-file ).
2016-06-11 10:48:53 +00:00
2020-12-13 14:52:45 +00:00
## Create log entries in rules
2016-06-04 18:39:05 +00:00
2020-12-13 14:52:45 +00:00
There are times, especially when troubleshooting rules, when it can be helpful to log information or Item state values.
2016-06-04 18:39:05 +00:00
2017-11-08 12:23:08 +00:00
For each log level there is an corresponding command for creating log entries.
You may use these log levels to filter or better differentiate the generated logging output.
2020-12-13 14:52:45 +00:00
The logging commands require two parameters: the subpackage, in the examples below `heating` , and the text which should appear in the log:
2016-06-04 18:39:05 +00:00
2016-11-12 18:28:23 +00:00
```java
2020-12-13 14:52:45 +00:00
logError("heating", "This is a log entry of type Error!")
logWarn("heating", "Heating control failed while in mode {}", Heating_Mode.state)
logInfo("heating", "Heating mode set to normal")
logDebug("heating", "Bedroom: Temperature: {}, Mode: {}", Bedroom_Temp.state, Bedroom_Heater_Mode.state)logWarn("heating", "This is a log entry of type Warn!")
2016-06-04 18:39:05 +00:00
```
2020-12-13 14:52:45 +00:00
The main package of all script/rules based log entries is predefined as `org.openhab.core.model.script` .
2017-11-08 12:23:08 +00:00
The chosen subpackage is appended to the end of the main package.
It can be useful for filtering or package-based log level settings.
2020-12-13 14:52:45 +00:00
For example you can use `log:set info org.openhab.core.model.script` and `log:set info org.openhab.core.model.script.heating` while you work on the heating rules to get debug level output for heating rules and only info level for the rest of your rules files so you don't flood the log with too many entries that are irrelevant at that point in time.
2016-06-04 18:39:05 +00:00
2017-11-08 12:23:08 +00:00
An example output of the last log statement above is:
2016-06-04 18:39:05 +00:00
```
2020-12-13 14:52:45 +00:00
2016-06-04 16:28:39.482 [DEBUG] [org.openhab.core.model.script.heating] Bedroom: Temperature 21.3°C, Mode NORMAL
2016-06-11 10:48:53 +00:00
```
2020-12-13 20:16:06 +00:00
Note that, in the last example above, inclusion and formatting of values is done using [Java Formatter String Syntax ](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Formatter.html ).
2017-11-08 12:23:08 +00:00
2020-12-13 14:52:45 +00:00
## Log4j configuration and logging into separate files
2016-06-11 10:48:53 +00:00
2020-12-13 14:52:45 +00:00
As per default, all log entries are saved in the file `openhab.log` and event specific entries are saved in `events.log` .
2018-11-19 12:00:40 +00:00
Additional files can be defined in order to write specifics logs to a separate place.
2016-06-11 10:48:53 +00:00
2020-12-13 14:52:45 +00:00
In order to define custom log patterns, log to network sockets and so on we can prepare a logging configuration in `log4j2.xml` .
There are several things that you might want to change in the configuration:
2019-05-02 18:52:37 +00:00
- the log level for a logger;
- the pattern of an appender;
- redirect the log to a text file.
### Further Reading
- < http: // www . slf4j . org / manual . html >