Hi
while I’ve never had logs overwritten I did experience new logs not being
written due to permission issues a fair amount of times. The main issue is that
by default Artemis instance doesn’t follow FHS and puts everything in one
folder under /var/lib/yourinstancename, which is not really meant to be
writable. On modern distributions this conflicts with things like SELinux. If
let’s say your /var/lib/artemis/log folder and log files were set to “artemis”
user owner, and then for some reason folder owner was reset to root but the
Artemis instance is still run as “artemis” user, then log files won’t be
written after log file rotation.
Setting permissions once doesn’t help much because, again, on modern
distributions they are reset by restorecon and other mechanics during updates,
etc.
You didn’t specify which distribution you are running, but if you are running
any flavor with SELinux I would recommend to configure Artemis logs to be
written to /var/log/artemis or similar folder dedicated to logs, and then apply
your own SELinux module rules.
Also, experiment with log4j2 configuration to understand how rotation works and
if you need adjust it for your system.
Hope that helps.
--
Vilius
From: [email protected] <[email protected]>
Sent: Wednesday, May 28, 2025 3:28 PM
To: [email protected]
Subject: artenis.log overwritten
Hello comunity,
normally on artemis broker start the artemis.log is created if not present or
the output is attached to artemis.log, if the file is there.
On a broker restart after a failure we faced a recreate (overwrite) of the
present artemis.log with artemis 2.41.
Unfortunately we have no idea now, what was the reason for the restart.
Did sombody else observe this and what can be the reason for it?
Regards
Herbert
________________________________
Herbert Helmstreit
Senior Software Engineer
Phone: +49 941 / 7 83 92 36
[email protected]<mailto:[email protected]>
[cid:PORAubjYZh0gUvWk8PCSCxCd9@fv3RU62mkghIxB6jiYZlkQcgx]
www.systema.com<https://www.systema.com/>
[LinkedIn]<https://www.linkedin.com/company/systema-gmbh/>[Facebook]<https://de-de.facebook.com/SYSTEMA.automation/>[XING]<https://www.xing.com/pages/systemagmbh>
SYSTEMA
Systementwicklung Dipl.-Inf. Manfred Austen GmbH
Manfred-von-Ardenne-Ring 6 | 01099 Dresden
HRB 11256 Amtsgericht Dresden | USt.-ID DE 159 607 786
Geschäftsführer: Manfred Austen, CEO und Dr. Ulf Martin, COO
P Please check whether a printout of this e-mail is really necessary.