Logrotate errors

I get the following errors when logrotate tries to rotate the logs:

error: error running postrotate script
error: error running postrotate script
error: error running prerotate script, leaving old log in place
error: error running postrotate script
error: error running shared postrotate script for /var/log/messages /var/log/secure /var/log/maillog /var/log/spooler /var/log/boot.log /var/log/cron
error: error running postrotate script
error: error running postrotate script


I am pretty sure this is because /tmp is mounted with noexec.

After about an hour and a half of googling I finally found a website where it says you need to put
export TMPDIR=/tmp_safe
in /etc/cron.daily/logrotate to change the TMPDIR that logrotate uses. So, I did that, did mkdir /tmp_safe and chmodded it to 777 just to make sure that there wasn't going to be any errors (so i could make sure that was, indeed, the problem), however the errors continue.

Any idea what I am doing wrong?

Thanks for your help Logrotate errors

 

 

 

 

Top