• This forum has a zero tolerance policy regarding spam. If you register here to publish advertising, your user account will be deleted without further questions.

Maillog ist und bleibt leer

angsap

New Member
gelöst / solved: Maillog ist und bleibt leer

Hallo zusammen,

ich habe einen VServer bei Strato.
‪CentOS Linux 7.2.1511
Plesk Version 12.5.30.

Es ist eine Maschine, die seit ein paar Wochen läuft. Mein großes Problem sind die maillogs. Seit 2 Tagen wird nichts in die maillogs geschrieben, weder postfix noch dovecot. Ich habe natürlich die google und forum suche bemüht und einiges probiert alles ohne Erfolg.

Als erstes habe ich dovecot und postfix neu gestartet. Dann habe ich den Syslog-Daemon (rsyslogd) neu gestartet:
service rsyslog status
Code:
Redirecting to /bin/systemctl status  rsyslog.service
● rsyslog.service - System Logging Service
   Loaded: loaded (/usr/lib/systemd/system/rsyslog.service; enabled; vendor preset: enabled)
   Active: active (running) since Do 2016-03-03 10:35:11 CET; 7s ago
 Main PID: 28925 (rsyslogd)
   CGroup: /system.slice/rsyslog.service
           └─28925 /usr/sbin/rsyslogd -n


cat /etc/rsyslog.conf bringt folgendes Ergebnis:
Code:
# rsyslog configuration file

# For more information see /usr/share/doc/rsyslog-*/rsyslog_conf.html
# If you experience problems, see http://www.rsyslog.com/doc/troubleshoot.html

#### MODULES ####

# The imjournal module bellow is now used as a message source instead of imuxsock.
$ModLoad imuxsock # provides support for local system logging (e.g. via logger command)
$ModLoad imjournal # provides access to the systemd journal
#$ModLoad imklog # reads kernel messages (the same are read from journald)
#$ModLoad immark  # provides --MARK-- message capability

# Provides UDP syslog reception
#$ModLoad imudp
#$UDPServerRun 514

# Provides TCP syslog reception
#$ModLoad imtcp
#$InputTCPServerRun 514


#### GLOBAL DIRECTIVES ####

# Where to place auxiliary files
$WorkDirectory /var/lib/rsyslog

# Use default timestamp format
$ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat

# File syncing capability is disabled by default. This feature is usually not required,
# not useful and an extreme performance hit
#$ActionFileEnableSync on

# Include all config files in /etc/rsyslog.d/
$IncludeConfig /etc/rsyslog.d/*.conf

# Turn off message reception via local log socket;
# local messages are retrieved through imjournal now.
$OmitLocalLogging on

# File to store the position in the journal
$IMJournalStateFile imjournal.state


#### RULES ####

# Log all kernel messages to the console.
# Logging much else clutters up the screen.
#kern.*                                                 /dev/console

# Log anything (except mail) of level info or higher.
# Don't log private authentication messages!
*.info;mail.none;authpriv.none;cron.none                /var/log/messages

# The authpriv file has restricted access.
authpriv.*                                              /var/log/secure

# Log all the mail messages in one place.
mail.*                                                  -/var/log/maillog
Habs auch so probiert:
mail.*                                                  -/usr/local/psa/var/log/maillog
da dies ein symlink auf /var/log/maillog ist der auch funzt.


# Log cron stuff
cron.*                                                  /var/log/cron

# Everybody gets emergency messages
*.emerg                                                 :omusrmsg:*

# Save news errors of level crit and higher in a special file.
uucp,news.crit                                          /var/log/spooler

# Save boot messages also to boot.log
local7.*                                                /var/log/boot.log


# ### begin forwarding rule ###
# The statement between the begin ... end define a SINGLE forwarding
# rule. They belong together, do NOT split them. If you create multiple
# forwarding rules, duplicate the whole block!
# Remote Logging (we use TCP for reliable delivery)
#
# An on-disk queue is created for this action. If the remote host is
# down, messages are spooled to disk and sent when it is up again.
#$ActionQueueFileName fwdRule1 # unique name prefix for spool files
#$ActionQueueMaxDiskSpace 1g   # 1gb space limit (use as much as possible)
#$ActionQueueSaveOnShutdown on # save messages to disk on shutdown
#$ActionQueueType LinkedList   # run asynchronously
#$ActionResumeRetryCount -1    # infinite retries if host is down
# remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional
#*.* @@remote-host:514
# ### end of the forwarding rule ###

Das scheint für mich alles zu passen, oder? Es finden sich Postfix-Einträge im Journal: journalctl | grep postfix es wird also protokolliert. Maillog Dateirechte & Besitzer, stimmen diese?:
Code:
-rw-r-----  1 root   root                  0  2. Mär 21:23 maillog

.logrotate config:
cat /etc/logrotate.conf
Code:
# see "man logrotate" for details
# rotate log files weekly
weekly

# keep 4 weeks worth of backlogs
rotate 4

# create new (empty) log files after rotating old ones
create

# use date as a suffix of the rotated file
dateext

# uncomment this if you want your log files compressed
#compress

# RPM packages drop log rotation information into this directory
include /etc/logrotate.d

# no packages own wtmp and btmp -- we'll rotate them here
/var/log/wtmp {
    monthly
    create 0664 root utmp
        minsize 1M
    rotate 1
}

/var/log/btmp {
    missingok
    monthly
    create 0600 root utmp
    rotate 1
}

Sieht für mich auch gut aus. Ich habe logrotate zur Sicherheit neu gestartet:/usr/sbin/logrotate -f /etc/logrotate.conf, brachte auch nichts.

Leider habe ich nur rudimentäre Linux Kenntnisse und bin mit meinem Latein am Ende. Hat irgendjemand bitte einen Hinweis warum ich die Logs nicht zum Laufen kriege?

LG Angie
 
Last edited by a moderator:
Guck mal in der Odin-Hilfe zu dem Fehler -> https://kb.plesk.com/en/118350

Wenn ich das richtig verstehe müsste die Zeile in der /etc/rsyslog.conf so lauten:

#$ModLoad imuxsock # provides support for local system logging (e.g. via logger command)

also auskommentiert werden.
Vielleicht hilft das ja schon. Ansonsten steht da auch noch ein Workaround.
 
#$ModLoad imuxsock # provides support for local system logging (e.g. via logger command)

also auskommentiert werden.

Ich lese das genau anders herum:

Following string should not be commented. If they are commented, correct it

Denkbar ist allerdings tatsächlich das Problem mit der Uhrzeit (aus dem Redhat-Bugreport), das Löschen der imjournal.state (darin merkt sich rsyslog, bis wohin das journal gelesen wurde) könnte hier helfen.
 
Hallo zusammen und Danke für die Hilfe soweit.


Ich lese das genau anders herum:
Denkbar ist allerdings tatsächlich das Problem mit der Uhrzeit (aus dem Redhat-Bugreport), das Löschen der imjournal.state (darin merkt sich rsyslog, bis wohin das journal gelesen wurde) könnte hier helfen.

rm /var/lib/rsyslog/imjournal.state hatte iczh gestern schon probiert... nichts gebracht.

Guck mal in der Odin-Hilfe zu dem Fehler -> https://kb.plesk.com/en/118350

Wenn ich das richtig verstehe müsste die Zeile in der /etc/rsyslog.conf so lauten:

#$ModLoad imuxsock # provides support for local system logging (e.g. via logger command)
also auskommentiert werden.
Vielleicht hilft das ja schon. Ansonsten steht da auch noch ein Workaround.

Ich habe beide Versionen probiert, ohne Erfolg. Die Seite habe ich gestern bereits gefunden und Workaround ohne Erfolg getestet... leider.
Weiß irgendwer noch Rat? Kann ich rsyslog einfach reinstallieren und gut is, gibbet es da was zu beachten oder irgendwelche Fallstricke ?

LG Angie
 
noch ne n00b Frage:

syslog und rsyslog, müssen beide Dienste laufen?
service syslog status bringt das:
Code:
Redirecting to /bin/systemctl status  syslog.service
● syslog.service
   Loaded: not-found (Reason: No such file or directory)
   Active: inactive (dead)

und service syslog start das:
Code:
service syslog start
Redirecting to /bin/systemctl start  syslog.service
Failed to start syslog.service: Unit syslog.service failed to load: No such file or directory.

Kann das der Fehler sein?

LG Angie
 
syslog und rsyslog sind zwei unterschiedliche Syslog-Daemons - wenn der Paketmanager das richtig auflöst, ist nur einer installiert - rsyslog ist ein vollwertiger Ersatz für syslog mit zusätzlichen Features.
 
syslog und rsyslog sind zwei unterschiedliche Syslog-Daemons - wenn der Paketmanager das richtig auflöst, ist nur einer installiert - rsyslog ist ein vollwertiger Ersatz für syslog mit zusätzlichen Features.

OK, dann sollte in diesem Punkt alles in Ordnung sein, denn rsyslog ist installiert und läuft. Langsam wirds unheimlich... :confused:
 
Hallo Leute und schonmal Danke für Eure Mühen,

Werden denn andere Sachen (xferlog) geschrieben ?

Nein, ist auch leer. Das .processed file endet zum gleichen Zeitpunkt wie beim maillog. Die Apache und fail2ban Logs funktionieren. Die files modsec_audit.log, secure und sa-update.log sind ebenso leer...:confused:

Das sollte das Problem aber doch eingrenzen, oder? Mir fehlt leider der "große Überblick". seufz

Hast Du den zweiten Workaround aus dem KB-Artikel ausprobiert, also das
auskommentieren von $OmitLocalLogging on

Das Modul imuxsock lädst Du ja schon. rsyslog nach der Änderung neustarten.

Siehe zur genauen Erläuterung

https://access.redhat.com/documenta...de/s1-interaction_of_rsyslog_and_journal.html

Das waren meine Einstellungen:
Code:
# Turn off message reception via local log socket;
# local messages are retrieved through imjournal now.
#$OmitLocalLogging on

Ich habs jetzt wie auf der Seite so geändert:
Code:
$OmitLocalLogging off
Danach rsyslog neugestartet mit service rsyslog restart.

Allerdings sind keine Änderungen feststellbar. Ich bin kurz davor den ganzen Server nochmal platt zu machen...

LG Angie
 
Da ja fail2ban nicht funzt, weil ja nichts in den maillogs steht toben sich die scriptkiddie k...bratzen schön aus. Da wird sich grade tot gebruteforced. Kurzer Auszug aus journalctl zeigt:
Code:
[...]
Mär 04 10:08:02 xxx.stratoserver.net postfix/smtpd[26343]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:03 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=13)
Mär 04 10:08:03 xxx.stratoserver.net postfix/smtpd[26343]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:04 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=13)
Mär 04 10:08:04 xxx.stratoserver.net postfix/smtpd[26343]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:05 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=13)
Mär 04 10:08:05 xxx.stratoserver.net postfix/smtpd[26343]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:06 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=13)
Mär 04 10:08:06 xxx.stratoserver.net postfix/smtpd[26343]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:07 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=12)
Mär 04 10:08:07 xxx.stratoserver.net postfix/smtpd[26343]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:08 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=15)
Mär 04 10:08:08 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:09 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=15)
Mär 04 10:08:09 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:10 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=15)
Mär 04 10:08:10 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:11 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:11 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:12 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:12 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:13 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:13 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:14 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:14 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:15 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:15 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:16 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:16 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:17 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:17 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:18 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:18 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:20 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:20 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:21 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:21 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:22 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:22 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
Mär 04 10:08:23 xxx.stratoserver.net plesk_saslauthd[26126]: failed mail authenticatication attempt for user 'info@blablub.de' (password len=11)
Mär 04 10:08:23 xxx.stratoserver.net postfix/smtpd[26356]: warning: static-173-55-6-45.lsanca.fios.verizon.net[173.55.6.45]: SASL LOGIN authentication failed: authentication failure
[...]
 
GELÖST!!!

Meine Logs werden wieder beschrieben. Aus einem anderen Forum kam die Lösung:
Nach
Code:
$ModLoad imuxsock # provides support for local system logging (e.g. via logger command)
habe ich das eingefügt:
Code:
add input(type="imuxsock" HostName="localhost" Socket="/dev/log")

und jetzt funzen meine logs und damit auch fail2ban wieder... FREU :)

LG Angie
 
Back
Top