slrtscn.py Unable to open /var/log/maillog

Use this forum for questions regarding installation, upgrading and configuration of OpenEMM

Moderator: moderator

w0
Posts: 1
Joined: Thu Jun 04, 2009 10:58 am

slrtscn.py Unable to open /var/log/maillog

Post by w0 »

We have been using OpenEmm for about a year (not without difficulties) and since a few days slrtscn.py seems to be unable to open maillog for reading. We ge thousands of the following in ~openemm/var/log/<date>-<host>-slrtscn.log:

ERROR/main: Unable to open /var/log/maillog: Invalid input for /var/log/maillog:

/var/log/maillog has permissions 644 and should be readable by all users.

Any help or hints would be greatly appreciated.
neat
Posts: 5
Joined: Tue Jul 07, 2009 3:42 pm

Re: slrtscn.py Unable to open /var/log/maillog

Post by neat »

w0 wrote:We have been using OpenEmm for about a year (not without difficulties) and since a few days slrtscn.py seems to be unable to open maillog for reading. We ge thousands of the following in ~openemm/var/log/<date>-<host>-slrtscn.log:

ERROR/main: Unable to open /var/log/maillog: Invalid input for /var/log/maillog:

/var/log/maillog has permissions 644 and should be readable by all users.

Any help or hints would be greatly appreciated.
Hallo,

since a few days, we got the same problem with the maillog.
Could you solve the problem?

mfg
tjenkins
Posts: 1
Joined: Fri Oct 23, 2009 8:46 pm

Post by tjenkins »

I had the same problem and I believe I found the answer. I'm not a python programmer but here goes.

The real problem seems to be that it cant work with the savefile (On Centos 5 "/home/openemm/var/run/slrtscan.save"). I changed my save file to point at /tmp/slrtscan.save to see what happened. It created a new copy of the file and the error went away. I then went to /home/openemm/var/run and found that the slrtscan.save file contained 0 bytes. I moved the slrtscan.save file then put the slrtscn.py file back to normal. I then started up slrtscan.sh and it created a new slrtscan.save file where the old one was. A quick check of the log and the error is gone.

For some reason the python script wont use the existing slrtscan.save. In my case, the answer was to delete it then let the script recreate it.

I hope this helps. If someone finds out that I am incorrect let me know!
maschoff
Site Admin
Posts: 2628
Joined: Thu Aug 03, 2006 10:20 am
Location: Munich, Germany
Contact:

Post by maschoff »

The issue with file slrtscn.save has been fixed in release 6.0 (background: if file slrtscan.save was created with 0 bytes size because of a special condition like full harddisk the file couldn't be parsed correctly by python script slrtscn.py and it simply stopped working).

If /var/log/maillog can not be read it could be that either a super directory like /var/log has no read permission for others or a security policy for SELinux is missing.
OpenEMM Maintainer
neat
Posts: 5
Joined: Tue Jul 07, 2009 3:42 pm

Post by neat »

@ tjenkins

thank you for your workaround. It works!

mfg
Post Reply