[Postfixbuch-users] dovecot wiedermal

Marcel Hartmann (privat) mail at marcel-hartmann.com
Fr Apr 23 12:58:19 CEST 2010


Hi,

Am 22.04.2010 21:02, schrieb Peer Heinlein:
> Am Donnerstag 22 April 2010 16:49:09 schrieb Marcel Hartmann (privat):
>
>    
>> Das Problem dabei ist, er berücksichtigt die aliasse die in postfix
>> unter virtual_alias_maps eingegeben sind nicht.
>>      
> Muß er gar nicht, soll er gar nicht *KANN* er gar nicht.
>
> Was gehen Dovecot Aliase von Postfix an? Der Server sieht ja nur die von
> Postfix fertig umgeschriebenen Adressen.
>
>    
Da ich den standard virtual von Postfix gegen den dovecot delivery agent 
getauscht habe, muss dovecot das machen was virtual normalerweise tut, 
udn ist das nicht auch das mapping von source zu destination? Also auch 
externe destinations? Die gehen nämlcih auch nicht in meinem Setup! Nur 
interne Adressen/Aliasse nutzt er, postfix reicht einfach alles an 
dovecot weiter.
>> Das Problem muss am dovecot liegen,
>>      
> Autschn. Vorsicht mit solchen Aussagen. Je überzeugter solche Aussagen
> getroffen werden, umso unwahrer sind sie oft... :-)
>    
Hmmm, kann sein das ist meine Vermutung wegen des Logfiles von postfix 
(delivered via dovecot) status=send.
>    
>> da virtual_alias_maps einen
>> korrekten Wert zurück bekommt aus MySQL.
>>      
> Wie gesagt: Dein Denkfehler ist schon, daß Dovecot damit was zu tun hat.
> Hat er aber gar nicht.
>    
OK? Kannst Du das genauer erörtern bitte?
>    
>> Lege ich nen Alias an und sende eine Nachricht dahin, habe ich immer
>> neue Maildirs.
>>      
> Heißt: Postfix schreibt nicht um und gibt das dann so 1:1 an Dovecot.
> Das Problem liegt bei Postfix!
>    
OK, und wo genau? Evtl. bei virtual_transport = dovecot ??? Siehe main.cf.
>    
>> Das nervt irgendwie hat
>> dovecot das mapping von alias auf den reellen mailboxnamen
>>   "vergessen".
>>      
> Was er nicht weiß und was er nie wußte kann er folgerichtig gar nicht
> vergessen haben.
>
>    
>> Villeicht hat damit ja jemand Erfahrungen, irgendwie bereue ich fast
>>   schon nit den courier genommen zu haben den Peer in seinem Buch
>>   eingehend erläutert hat.
>>      
> Wenn Du im Jahr 2010 noch Courier nehmen würdest, dann würde ich Dich
> verhauen.
>    
LOOL. *Buchwegwerf* hehe
> Abgesehen kann ich Dir garantieren, daß sich NICHTS ändern würde. Das
> Problem würde genauso auftreten.
>
> Leider hast Du die Postfix-Config nicht mitgepostet. Also kann ich Dir
> auch nicht sagen, wo Du da was falsch gemachst hast.
>    
Postconf -n:

alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
content_filter = smtp-amavis:[127.0.0.1]:10030
daemon_directory = /usr/libexec/postfix
debug_peer_level = 2
disable_vrfy_command = yes
header_checks = pcre:/etc/postfix/delete_10031_header
html_directory = no
inet_interfaces = all
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
mydestination = localhost, $myhostname
myhostname = mx02.insentic.de
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
receive_override_options = no_address_mappings
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_data_restrictions = reject_unauth_pipelining
smtpd_error_sleep_time = 5s
smtpd_etrn_restrictions = permit_mynetworks
smtpd_hard_error_limit = 20
smtpd_helo_required = yes
smtpd_recipient_restrictions = permit_mynetworks        permit_sasl_authenticated        reject_unauth_destination        check_recipient_access hash:/etc/postfix/access        reject_unknown_recipient_domain        reject_unknown_sender_domain        reject_unverified_recipient        reject_non_fqdn_recipient        reject_non_fqdn_sender        reject_invalid_hostname        reject_rbl_client zen.spamhaus.org        reject_rbl_client combined.njabl.org        reject_rbl_client bl.spamcop.net        reject_rhsbl_sender dsn.rfc-ignorant.org        reject_rhsbl_sender bogusmx.rfc-ignorant.org        reject_rhsbl_sender rhsbl.sorbs.net
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = yes
smtpd_sasl_path = private/auth
smtpd_sasl_type = dovecot
smtpd_soft_error_limit = 10
smtpd_tls_auth_only = no
smtpd_tls_cert_file = /etc/pki/postfix/certs/postfix.pem
smtpd_tls_key_file = /etc/pki/postfix/private/postfix.pem
smtpd_use_tls = yes
soft_bounce = no
unknown_local_recipient_reject_code = 550
unverified_recipient_reject_code = 550
unverified_sender_reject_code = 550
virtual_alias_maps = mysql:/etc/postfix/mysql-virtual-alias-maps.cf,mysql:/etc/postfix/mysql-email2email.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql-virtual-mailbox-domains.cf
virtual_mailbox_maps = mysql:/etc/postfix/mysql-virtual-mailbox-maps.cf
virtual_transport = dovecot


> Ich vermute aber mal, daß Du übersehen hast, daß /etc/aliases nur bei
> $mydestination ausgewertet wird und bei $relay_domains&  Co keine Rolle
> spielt.
>    
Nein, das weiss ich das es da nur um lokale User also die der Canonical 
Domain in mydestination/mynetworks/etc. eine Rolle spielen. Ich mappe in 
/etc/aliases nur root: zu email at adresse.de einer Virtuellen Domain damit 
ich die ins richtige Postfach bekomme. Aber auch hier das Phänomen, dass 
eine Mail an root ('echo "test" | mail -s "Testmail" root') laut Log so 
ankommt:

Apr 23 12:51:32 scrooge postfix/anvil[13274]: statistics: max connection 
rate 1/60s for (smtp:213.238.60.165) at Apr 23 12:48:12
Apr 23 12:51:32 scrooge postfix/anvil[13274]: statistics: max connection 
count 1 for (smtp:213.238.60.165) at Apr 23 12:48:12
Apr 23 12:51:32 scrooge postfix/anvil[13274]: statistics: max cache size 
1 at Apr 23 12:48:12
Apr 23 12:52:43 scrooge postfix/pickup[13148]: 44E6ADCE61: uid=0 from=<root>
Apr 23 12:52:43 scrooge postfix/cleanup[13303]: 44E6ADCE61: 
message-id=<20100423105244.44E6ADCE61 at mx02.insentic.de>
Apr 23 12:52:43 scrooge postfix/qmgr[6145]: 44E6ADCE61: 
from=<root at insentic.de>, size=296, nrcpt=1 (queue active)
Apr 23 12:52:44 scrooge postfix/smtpd[13308]: connect from 
unknown[127.0.0.1]
Apr 23 10:52:44 scrooge postfix/smtpd[13308]: 50E8ADCE4E: 
client=unknown[127.0.0.1]
Apr 23 12:52:44 scrooge postfix/cleanup[13303]: 50E8ADCE4E: 
message-id=<20100423105244.44E6ADCE61 at mx02.insentic.de>
Apr 23 12:52:44 scrooge postfix/qmgr[6145]: 50E8ADCE4E: 
from=<root at insentic.de>, size=451, nrcpt=1 (queue active)
Apr 23 10:52:44 scrooge postfix/smtpd[13308]: disconnect from 
unknown[127.0.0.1]
Apr 23 12:52:44 scrooge amavis[13136]: (13136-03) Passed CLEAN, 
<root at insentic.de> -> <root at insentic.de>, Message-ID: 
<20100423105244.44E6ADCE61 at mx02.insentic.de>, mail_id: M6H9zPqnFRsF, 
Hits: 0, size: 296, queued_as: 50E8ADCE4E, 632 ms
Apr 23 12:52:44 scrooge postfix/smtp[13305]: 44E6ADCE61: 
to=<root at insentic.de>, orig_to=<root>, relay=127.0.0.1[127.0.0.1]:10030, 
delay=0.07, delays=0.02/0.01/0/0.64, dsn=2.0.0, status=sent (250 2.0.0 
Ok, id=13136-03, from MTA([127.0.0.1]:10031): 250 2.0.0 Ok: queued as 
50E8ADCE4E)
Apr 23 12:52:44 scrooge postfix/qmgr[6145]: 44E6ADCE61: removed
Apr 23 12:52:44 scrooge postfix/pipe[13309]: 50E8ADCE4E: 
to=<root at insentic.de>, relay=dovecot, delay=0.12, delays=0/0.01/0/0.11, 
dsn=2.0.0, status=sent (delivered via dovecot service)
Apr 23 12:52:44 scrooge postfix/qmgr[6145]: 50E8ADCE4E: removed

Er sendet an root at insentic.de (Hauptdomain des Servers, in mydestination 
steht aber nur mx02.insentic.de drin und kein myorigin, sonst wäre 
insentic.de ja wieder mit dabei. Dovecot macht daraus dann folgendes:

Apr 23 12:52:44 deliver(root at insentic.de): Info: Loading modules from 
directory: /usr/lib64/dovecot/lda
Apr 23 12:52:44 deliver(root at insentic.de): Info: Module loaded: 
/usr/lib64/dovecot/lda/lib90_cmusieve_plugin.so
Apr 23 12:52:44 deliver(root at insentic.de): Info: auth input: uid=5000
Apr 23 12:52:44 deliver(root at insentic.de): Info: auth input: gid=5000
Apr 23 12:52:44 deliver(root at insentic.de): Info: auth input: 
home=/storage/var/vmail/insentic.de/root
Apr 23 12:52:44 deliver(root at insentic.de): Info: maildir: 
data=/storage/var/vmail/insentic.de/root
Apr 23 12:52:44 deliver(root at insentic.de): Info: maildir++: 
root=/storage/var/vmail/insentic.de/root, index=, control=, 
inbox=/storage/var/vmail/insentic.de/root
Apr 23 12:52:44 deliver(root at insentic.de): Info: cmusieve: 
/storage/var/vmail/insentic.de/root/.dovecot.sieve doesn't exist
Apr 23 12:52:44 deliver(root at insentic.de): Info: Namespace : Using 
permissions from /storage/var/vmail/insentic.de/root: mode=0700 gid=-1
Apr 23 12:52:44 auth(default): Info: master in: USER    1       
root at insentic.de        service=deliver
Apr 23 12:52:44 auth(default): Info: master out: USER   1       
root at insentic.de        uid=5000        gid=5000        
home=/storage/var/vmail/insentic.de/root
Apr 23 12:52:44 deliver(root at insentic.de): Info: 
msgid=<20100423105244.44E6ADCE61 at mx02.insentic.de>: saved mail to INBOX

Und schwupps legt mir dovecot wieder ein neues Maildir an nämlich das 
Konto root in der Domain insentic.de. Das selbe Problem wie für 
existierende Aliasse in mysql_virtual_alias_maps. Er solls auf die 
hauptmailbox matchen und DA ablegen nicht ein neues Dir anlegen der 
Hund. Ich hoffe das ist verständlich rübergekommen bisher. Ansonsten 
Gepeinigt fragen bitte... :-)

Danke bisher und Gruß,
Marcel

-- 
Marcel Hartmann (webdeveloper&&  project manager)
mail at marcel-hartmann.com // www.marcel-hartmann.com

-------------- nächster Teil --------------
Ein Dateianhang mit HTML-Daten wurde abgetrennt...
URL: <https://listi.jpberlin.de/pipermail/postfixbuch-users/attachments/20100423/0bac5c43/attachment.html>


Mehr Informationen über die Mailingliste Postfixbuch-users