Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error parsing log4j2.xml #1285

Open
lolodomo opened this issue May 4, 2021 · 6 comments
Open

Error parsing log4j2.xml #1285

lolodomo opened this issue May 4, 2021 · 6 comments
Labels
bug An unexpected problem or unintended behavior karaf

Comments

@lolodomo
Copy link
Contributor

lolodomo commented May 4, 2021

At the very first startup of openHAB (from an offline distribution) snapshot 2631, I got this error:

13:44:23.308 [INFO ] [org.openhab.ui.internal.UIService    ] - Started UI on port 8080
[Fatal Error] log4j2.xml:1:1: Fin prématurée du fichier.
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Error parsing /home/pi/openhab/userdata/etc/log4j2.xml

Not occurring again after a restart.

@lolodomo
Copy link
Contributor Author

This is still happening sometimes, I saw this error in recent snapshots

@wborn wborn added the karaf label Apr 2, 2022
@wborn
Copy link
Member

wborn commented Apr 2, 2022

Based on the timestamps it looks like the log4j2.xml file is always modified on startup. So maybe it is sometimes written/read at the same time causing this issue?

@wborn
Copy link
Member

wborn commented Apr 2, 2022

Karaf always updates this logger on startup:

<!-- Added by Karaf to prevent debug logging loops, see -->
<!-- https://issues.apache.org/jira/browse/KARAF-5559 -->
<Logger level="WARN" name="org.apache.sshd"/>

which probably causes the file to be modified.

@wborn wborn added the bug An unexpected problem or unintended behavior label Apr 2, 2022
@lolodomo
Copy link
Contributor Author

lolodomo commented Dec 8, 2022

I saw this error again few minutes ago when installing today snapshot (3209).

@lolodomo
Copy link
Contributor Author

lolodomo commented Mar 9, 2023

I got it again when starting snapshot 3360:

$ ./start.sh
Launching the openHAB runtime...

                           _   _     _     ____
   ___   ___   ___   ___  | | | |   / \   | __ )
  / _ \ / _ \ / _ \ / _ \ | |_| |  / _ \  |  _ \
 | (_) | (_) |  __/| | | ||  _  | / ___ \ | |_) )
  \___/|  __/ \___/|_| |_||_| |_|/_/   \_\|____/
       |_|       4.0.0-SNAPSHOT - Build #3360

Use '<tab>' for a list of available commands
and '[cmd] --help' for help on a specific command.
To exit, use '<ctrl-d>' or 'logout'.

openhab>
openhab> log:tail
19:08:04.213 [INFO ] [org.openhab.core.Activator           ] - Starting openHAB 4.0.0 (build Build #3360)
[Fatal Error] log4j2.xml:1:1: Fin prématurée du fichier.
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Error parsing /home/xxx/openhab/userdata/etc/log4j2.xml
[Fatal Error] log4j2.xml:1:1: Fin prématurée du fichier.
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Error parsing /home/xxx/openhab/userdata/etc/log4j2.xml

@lolodomo
Copy link
Contributor Author

Just got it again when I started the snapshot 3434 for the first time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An unexpected problem or unintended behavior karaf
Projects
None yet
Development

No branches or pull requests

2 participants