Multiple web application deployed on payara server and running as a windows services configured, the windows configuration xml file include --watchdog and log rotation in domain.xml is set to log-rotation-limit-in-bytes="2000000
, logging properties com.sun.enterprise.server.logging.GFFileHandler.maxHistoryFiles=10
, once it reaches the threshold it throws the 'COULD NOT DELETE LOG FILE.'
[2020-10-20T17:13:26.634+0530] [Payara 5.194] [SEVERE] [] [] [tid: _ThreadID=28 _ThreadName=GFFileHandler log pump] [timeMillis: 1603194206634] [levelValue: 1000] [[ java.io.IOException: Could not delete log file: D:\Tools\server\Webapps\logs\server.log.lck at com.sun.enterprise.server.logging.GFFileHandler.cleanUpHistoryLogFiles(GFFileHandler.java:827) at com.sun.enterprise.server.logging.GFFileHandler.lambda$rotate$2(GFFileHandler.java:905) at java.base/java.security.AccessController.doPrivileged(Native Method) at com.sun.enterprise.server.logging.GFFileHandler.rotate(GFFileHandler.java:845) at com.sun.enterprise.server.logging.GFFileHandler.log(GFFileHandler.java:967) at com.sun.enterprise.server.logging.GFFileHandler$1.run(GFFileHandler.java:581) ]]
Found the similar behavior observed in glassfish gitbub link https://github.com/eclipse-ee4j/glassfish/issues/21275 but no proper solution.
Any suggestion on this?
PS:: Found the similar issue when just running the payara server with asadmin command "start-domain --verbose --debug --domainDir webApps"