PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Abenteuer Mailserver



blade74
20.08.04, 09:52
Hallo,
ich habe mal wieder ein neues Problem mit meinen Mailserver
Ja das Abenteuer geht weiter
Ich habe meinen Mailserver nach der Anleitung von linux-tin.org
Um einen Virenscanner und Spam Filter erweitert
Das heizt Mails werden von postfix angenommen an port 10025
Und dann an newamavis übergeben Port 10024
Nur leider funktioniert er jetzt nicht mehr so wie er soll

Wenn ich mich mit telnet an den Port 10025 und 10024 verbinde
Kommt die Meldung das alles ok ist

Beim Start von amavis

Steht im Mail log folgendes
daemon started -- version 2.0.14
Aug 20 11:23:51 linux amavis[2415]: starting. amavisd at linux amavisd-new-20030616-p5, Unicode aware
Aug 20 11:23:51 linux amavis[2415]: Perl version 5.008001
Aug 20 11:23:51 linux amavis[2415]: Module Amavis::Conf 1.15
Aug 20 11:23:51 linux amavis[2415]: Module Archive::Tar 0.23
Aug 20 11:23:51 linux amavis[2415]: Module Archive::Zip 1.05
Aug 20 11:23:51 linux amavis[2415]: Module Compress::Zlib 1.16
Aug 20 11:23:51 linux amavis[2415]: Module Convert::TNEF 0.17
Aug 20 11:23:51 linux amavis[2415]: Module Convert::UUlib 0.31
Aug 20 11:23:51 linux amavis[2415]: Module MIME::Entity 5.404
Aug 20 11:23:51 linux amavis[2415]: Module MIME::Parser 5.406
Aug 20 11:23:51 linux amavis[2415]: Module MIME::Tools 5.411
Aug 20 11:23:51 linux amavis[2415]: Module Mail::Header 1.64
Aug 20 11:23:51 linux amavis[2415]: Module Mail::Internet 1.64
Aug 20 11:23:51 linux amavis[2415]: Module Mail::SpamAssassin 2.55
Aug 20 11:23:51 linux amavis[2415]: Module Net::Cmd 2.26
Aug 20 11:23:51 linux amavis[2415]: Module Net::DNS 0.38
Aug 20 11:23:51 linux amavis[2415]: Module Net::SMTP 2.29
Aug 20 11:23:51 linux amavis[2415]: Module Net::Server 0.87
Aug 20 11:23:51 linux amavis[2415]: Module Time::HiRes 1.6
Aug 20 11:23:51 linux amavis[2415]: Module Unix::Syslog 0.99
Aug 20 11:23:51 linux amavis[2415]: Found myself: /usr/sbin/amavisd -c /etc/amavisd.conf
Aug 20 11:23:51 linux amavis[2415]: Lookup::SQL code NOT loaded
Aug 20 11:23:51 linux amavis[2415]: Lookup::LDAP code NOT loaded
Aug 20 11:23:51 linux amavis[2415]: AMCL-in protocol code loaded
Aug 20 11:23:51 linux amavis[2415]: SMTP-in protocol code loaded
Aug 20 11:23:51 linux amavis[2415]: ANTI-VIRUS code loaded
Aug 20 11:23:51 linux amavis[2415]: ANTI-SPAM code loaded
Aug 20 11:23:51 linux amavis[2416]: Net::Server: Process Backgrounded
Aug 20 11:23:51 linux amavis[2416]: Net::Server: 2004/08/20-11:23:51 Amavis (type Net::Server::PreForkSimple) starting! pid(2416)
Aug 20 11:23:51 linux amavis[2416]: Net::Server: Binding to UNIX socket file /var/spool/amavis/amavisd.sock using SOCK_STREAM
Aug 20 11:23:51 linux amavis[2416]: Net::Server: Binding to TCP port 10024 on host 127.0.0.1
Aug 20 11:23:51 linux amavis[2416]: Net::Server: Setting gid to "322 322"
Aug 20 11:23:51 linux amavis[2416]: Net::Server: Setting uid to "65"
Aug 20 11:23:51 linux amavis[2416]: Found $file at /usr/bin/file
Aug 20 11:23:51 linux amavis[2416]: Found $arc at /usr/bin/arc
Aug 20 11:23:51 linux amavis[2416]: Found $gzip at /usr/bin/gzip
Aug 20 11:23:51 linux amavis[2416]: Found $bzip2 at /usr/bin/bzip2
Aug 20 11:23:51 linux amavis[2416]: No $lzop, not using it
Aug 20 11:23:51 linux amavis[2416]: Found $lha at /usr/bin/lha
Aug 20 11:23:51 linux amavis[2416]: Found $unarj at /usr/bin/unarj
Aug 20 11:23:51 linux amavis[2416]: Found $uncompress at /usr/bin/uncompress
Aug 20 11:23:51 linux amavis[2416]: No $unfreeze, not using it
Aug 20 11:23:51 linux amavis[2416]: Found $unrar at /usr/bin/unrar
Aug 20 11:23:51 linux amavis[2416]: Found $zoo at /usr/bin/zoo
Aug 20 11:23:51 linux amavis[2416]: Found $cpio at /usr/bin/cpio
Aug 20 11:23:51 linux amavis[2416]: Found secondary av scanner Sophos Anti Virus (sweep) at /usr/local/bin/sweep
Aug 20 11:23:51 linux amavis[2416]: SpamControl: initializing Mail::SpamAssassin
Aug 20 11:23:51 linux amavis[2416]: SpamControl: turning on SA auto-whitelisting (AWL)
Aug 20 11:23:51 linux amavis[2416]: SpamControl: done


Wenn ich aber nun eine Mail versende

mail –s test test@linux.local

erhalte ich die volgende Meldung

Aug 20 11:28:03 linux postfix/pickup[2349]: 51DB519EB8C: uid=0 from=<root>
Aug 20 11:28:03 linux postfix/cleanup[2459]: 51DB519EB8C: message-id=<4125C423.mail1W81HQY1A@linux.local>
Aug 20 11:28:03 linux postfix/qmgr[2350]: 51DB519EB8C: from=<root@linux.local>, size=402, nrcpt=1 (queue active)
Aug 20 11:28:03 linux postfix/smtp[2461]: fatal: parameter smtp_data_done_timeout: bad time unit:
Aug 20 11:28:04 linux postfix/master[2346]: warning: process /usr/lib/postfix/smtp pid 2461 exit status 1
Aug 20 11:28:04 linux postfix/master[2346]: warning: /usr/lib/postfix/smtp: bad command startup – throttling



Ich hoffe ihr könnt mir helfen

Terran Marine
20.08.04, 10:14
Post dochmal die main.cf.

blade74
20.08.04, 10:29
Hallo,
der Fehler scheint in der master.cf zu liegen

die Fehlermeldung von oben habe ich beseitigt
war eine option in der master.cf

Ich habe sie mal mit beigefügt
Ich habe keine Ahnung was da falsch sein soll

Hier also mal die master.cf

# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
# ================================================== ========================
smtp inet n - n - 50 smtpd -o content_filter=smtp:[localhost]:10024
#smtp inet n - n - - smtpd
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
rewrite unix - - n - - trivial-rewrite
bounce unix - - n - 0 bounce
defer unix - - n - 0 bounce
flush unix n - n 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - n - - smtp
relay unix - - n - - smtp
showq unix n - n - - showq
error unix - - n - - error
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - n - - lmtp
maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
Cyrus unix - n n - - pipe
user=cyrus argv=/usr/lib/cyrus/bin/deliver -e -r ${sender} -m ${extension} ${user}
uucp unix - n n - - pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
ifmail unix - n n - - pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix - n n - - pipe
flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient
vscan unix - n n - 10 pipe
user=vscan argv=/usr/sbin/amavis ${sender} ${recipient}
procmail unix - n n - - pipe
flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc ${sender} ${recipient}
localhost:10025 inet n - y - - smtpd
-o content_filter=
-o local_recipient_maps=
-o relay_recipient_maps=
-o smtpd_restriction_classes=
-o smtpd_client_restrictions=
-o smtpd_helo_restrictions=
-o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,rej ect
-o mynetworks=127.0.0.0/8
-o strict_rfc821_envelopes=yes
-o smtpd_error_sleep_time=0
-o smtpd_soft_error_limit=1001
-o smtpd_hard_error_limit=1000
smtp-amavis unix - - y - 50 smtp
-o smtp_data_done_timeout=1200


Und das ist das neue Fehlermeldung



Aug 20 11:57:55 linux postfix/pickup[2918]: 046B919EB91: uid=0 from=<root>
Aug 20 11:57:55 linux postfix/cleanup[2949]: 046B919EB91: message-id=<4125CB22.mail29U1GV8CI@linux.local>
Aug 20 11:57:55 linux postfix/qmgr[2919]: 046B919EB91: from=<root@linux.local>, size=400, nrcpt=1 (queue active)
Aug 20 11:57:55 linux amavis[2944]: (02944-01) ESMTP::10024 /var/spool/amavis/amavis-20040820T115755-02944: <root@
linux.local> -> <test@linux.local> Received: SIZE=400 from linux.local ([127.0.0.1]) by localhost (linux [127.0.0.
1]) (amavisd-new, port 10024) with ESMTP id 02944-01 for <test@linux.local>; Fri, 20 Aug 2004 11:57:55 +0200 (CEST
)
Aug 20 11:57:55 linux amavis[2944]: (02944-01) Checking: <root@linux.local> -> <test@linux.local>
Aug 20 11:57:55 linux amavis[2944]: (02944-01) WARN: all primary virus scanners failed, considering backups
Aug 20 11:57:58 linux amavis[2944]: (02944-01) spam_scan: hits=0 tests=USER_AGENT
Aug 20 11:57:58 linux amavis[2944]: (02944-01) FWD via SMTP: [127.0.0.1:10025] <root@linux.local> -> <test@linux.l
ocal>
Aug 20 09:57:58 linux postfix/smtpd[2954]: connect from unknown[127.0.0.1]
Aug 20 09:57:58 linux postfix/smtpd[2954]: 25DA219EBA9: client=unknown[127.0.0.1]
Aug 20 11:57:58 linux postfix/cleanup[2949]: 25DA219EBA9: message-id=<4125CB22.mail29U1GV8CI@linux.local>
Aug 20 11:57:58 linux postfix/qmgr[2919]: 25DA219EBA9: from=<root@linux.local>, size=804, nrcpt=1 (queue active)
Aug 20 11:57:58 linux amavis[2944]: (02944-01) Passed, <root@linux.local> -> <test@linux.local>, Message-ID: <4125
CB22.mail29U1GV8CI@linux.local>, Hits: 0
Aug 20 11:57:58 linux amavis[2944]: (02944-01) TIMING [total 3140 ms] - SMTP EHLO: 3 (0%), SMTP pre-MAIL: 0 (0%),
mkdir tempdir: 0 (0%), create email.txt: 1 (0%), SMTP pre-DATA-flush: 4 (0%), SMTP DATA: 37 (1%), body hash: 1 (0%
), mkdir parts: 1 (0%), mime_decode: 14 (0%), get-file-type: 8 (0%), decompose_part: 2 (0%), parts: 0 (0%), AV-sca
n-1: 2790 (89%), SA msg read: 2 (0%), SA parse: 1 (0%), SA check: 114 (4%), fwd-connect: 30 (1%), fwd-mail-from: 2
(0%), fwd-rcpt-to: 2 (0%), write-header: 4 (0%), fwd-data: 0 (0%), fwd-data-end: 120 (4%), fwd-rundown: 1 (0%), u
nlink-1-files: 4 (0%), rundown: 0 (0%)
Aug 20 09:57:58 linux postfix/smtp[2951]: 046B919EB91: to=<test@linux.local>, relay=127.0.0.1[127.0.0.1], delay=4,
status=sent (250 2.6.0 Ok, id=02944-01, from MTA: 250 Ok: queued as 25DA219EBA9)
Aug 20 09:57:58 linux postfix/smtpd[2954]: disconnect from unknown[127.0.0.1]
Aug 20 11:57:58 linux postfix/local[2955]: warning: connect #1 to subsystem private/cyrus: Connection refused
Aug 20 11:58:08 linux postfix/local[2955]: warning: connect #2 to subsystem private/cyrus: Connection refused
^[[B^[[BAug 20 11:58:18 linux postfix/local[2955]: warning: connect #3 to subsystem private/cyrus: Connection refused


Also jetzt sendet er nach extern aber bekommt anscheinet keine Verbindung mehr zum
Cyrus

blade74
20.08.04, 10:36
und auch noch mal die main.cf


queue_directory = /var/spool/postfix/
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
mail_owner = postfix
mydomain = linux.local
myorigin = $mydomain
unknown_local_recipient_reject_code = 450
mynetworks = 192.168.1.0/24, 127.0.0.0/8
mailbox_command = /usr/lib/cyrus/bin/deliver
mailbox_transport = cyrus
smtpd_banner = $myhostname ESMTP
debug_peer_level = 2
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5
sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
setgid_group = maildrop
manpage_directory = /usr/share/man
sample_directory = /usr/share/doc/packages/postfix/samples
readme_directory = /usr/share/doc/packages/postfix/README_FILES
mail_spool_directory = /var/mail
canonical_maps = hash:/etc/postfix/canonical
virtual_maps = hash:/etc/postfix/virtual
relocated_maps = hash:/etc/postfix/relocated
transport_maps = hash:/etc/postfix/transport
sender_canonical_maps = hash:/etc/postfix/sender_canonical
masquerade_exceptions = root
masquerade_classes = envelope_sender, header_sender, header_recipient
myhostname = linux.local
default_transport = smtp
program_directory = /usr/lib/postfix
inet_interfaces = all
masquerade_domains =
mydestination = $myhostname,localhost.$mydomain,$mydomain
defer_transports =
disable_dns_lookups = no
relayhost =mein.provider.de
content_filter = smtp-amavis:[127.0.0.1]:10024
smtpd_sender_restrictions = hash:/etc/postfix/access
smtpd_client_restrictions =
smtpd_helo_required = no
smtpd_helo_restrictions =
strict_rfc821_envelopes = no
smtpd_recipient_restrictions = permit_mynetworks,reject_unauth_destination
smtp_sasl_auth_enable = yes
alias_maps = hash:/etc/aliases
mailbox_size_limit = 51200000
message_size_limit = 10240000
smtp_use_tls = no
smtp_sasl_security_options =
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd

Terran Marine
20.08.04, 10:39
Der Cyrus läuft auch ?

und die Pfade aus der main und master.cf zum cyrus stimmen ?

blade74
20.08.04, 10:52
ja cyrus läuft

ich kann auch auf meine alten Mails zugreifen

bewor ich die amavis und spamassassin installiert habe

lief er ja auch uch an der main.cf habe ich ja auch nichts bes auf den eintrag
content_filter = smtp-amavis:[127.0.0.1]:10024
der ist neu sonst alles wie vorher

und diese einträge habe ich in der master.cf gesetzt

smtp inet n - n - 50 smtpd -o content_filter=smtp:[localhost]:10024



localhost:10025 inet n - y - - smtpd
-o content_filter=
-o local_recipient_maps=
-o relay_recipient_maps=
-o smtpd_restriction_classes=
-o smtpd_client_restrictions=
-o smtpd_helo_restrictions=
-o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,rej ect
-o mynetworks=127.0.0.1/8
-o strict_rfc821_envelopes=yes
-o smtpd_error_sleep_time=0
-o smtpd_soft_error_limit=1001
-o smtpd_hard_error_limit=1000
smtp-amavis unix - - y - 50 smtp
-o smtp_data_done_timeout = 1200



cyrus antwortet auch über telnet localhost 143

Connected to localhost.
Escape character is '^]'.
* OK linux Cyrus IMAP4 v2.1.15 server ready

Terran Marine
20.08.04, 11:14
Sehe jetzt auch nichts besonders,

in der master.cf schreibst du Cyrus einmal groß,

in der main.cf allerdings klein.

Hast du da mal rumprobiert?

blade74
20.08.04, 12:31
ich versteh die Welt nicht mehr

nichts geändert aber jetzt geht es

Kann mir jetzt noch jemant sagen wie ich die Mails zu guter letzt noch durch Procmail bekomme.
Damit die Mails die als Spam gegenzeichnet sind auch gleich Serverseitig gefiltert werden.