[logback-user] [LOGBACK] : broken symlink in linux

Arnaud B. boinarnaud at gmail.com
Tue Jun 13 15:08:43 CEST 2023


Hello,

I need your help in creating log files by LOGBACK on LINUX environment,
version 1.1.4.
When starting the application server, it generates symbolic links between
/proc/<PID>/fd/<NUM> to /appli/test/log/server_fonc.log,
appli/test/log/application.log, ...
When using the LOGBACK rollover, for example, on the hast file, the
application.log.5 file is deleted but it nevertheless generated a symbolic
link between "/proc/<PID>/fd/<NUM>" and "/appli/test/log/application.log.5".
Suddenly, I end up with a broken symbolic link and a message
"/appli/test/log/application.log.5 (deleted)" via the command "lsof -nP +L1
| grep java"
For what? Is this a logback issue? Or, an OS problem?
Thank you in advance for your help ;)

Example Configuration Logback for server_fonc.log :
      <appender name="GENERAL_APPENDER"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>/application/test/log/applicatif.log</file> <filter
class="ch.qos.logback.classic.filter.ThresholdFilter"> <level>TRACE</level>
</filter> <encoder> <Pattern>%d;%level;%X{adresseIp};%X{sessionId};%X{Art
ifactId};%X{Version};%logger;%marker;%m%n%ex{full}</Pattern> </encoder>
<rollingPolicy
class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
<fileNamePattern>/appli/test/log/applicatif.log.%i</fileNamePattern>
<minIndex>1</minIndex> <maxIndex>5</maxIndex> </rollingPolicy>
<triggeringPolicy
class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
<maxFileSize>10MB</maxFileSize> </triggeringPolicy> </appender>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.qos.ch/pipermail/logback-user/attachments/20230613/0787e535/attachment.htm>


More information about the logback-user mailing list