2

Somewhat recent versions of logrotate fail to execute postrotate actions that invoke Java when logrotate is started via systemd. In my logs I see:

logrotate[123]: Error occurred during initialization of VM
logrotate[123]: Failed to mark memory page as executable - check if grsecurity/PaX is enabled
C-Otto
  • 334
  • 5
  • 18

1 Answers1

2

The following commit added hardening options to logrotate's systemd script: https://github.com/logrotate/logrotate/commit/1008bdf391e35684d8eeb2217c859f11e273ebb3

These changes were released with logrotate v3.14 (also included in Debian 10, released July 2019).

One of the configured options (MemoryDenyWriteExecute=true) causes execution of Java programs to fail. Setting this option to false fixes the issue for me, possibly making the system less secured/hardened.

C-Otto
  • 334
  • 5
  • 18