Hi I'm getting strange behaviour when I try to put any virtual domain address in /etc/aliases: # /etc/aliases mailer-daemon: postmaster postmaster: root nobody: root hostmaster: root usenet: root news: root webmaster: root www: root ftp: root abuse: root noc: root security: root root: david auriasistemas net I'm obviously trying to forward all mailer-daemon@*, postmaster@* ... to the virtual account david auriasistemas net. There is a local user "david", and all mail goes to /home/david/Maildir instead of /var/www/webX This is the log of a message sent from root console to postmaster garabana com, another virtual domain: Jul 24 03:41:47 eneri postfix/pickup[8995]: B3E9EBB3: uid=0 from=<root> Jul 24 03:41:47 eneri postfix/cleanup[9265]: B3E9EBB3: message-id=<20060724014147.B3E9EBB3@eneri> Jul 24 03:41:47 eneri postfix/qmgr[8996]: B3E9EBB3: from=<root eneri auriasistemas net>, size=311, nrcpt=1 (queue active) Jul 24 03:41:47 eneri postfix/local[9267]: B3E9EBB3: to=<david auriasistemas net>, orig_to=<postmaster garabana com>, relay=local, delay=0, status=sent (delivered to maildir) Jul 24 03:41:47 eneri postfix/qmgr[8996]: B3E9EBB3: removed If I put any (I mean ANY, doesn't matter what is the virtual domain) other non-existent accout (f-ex. john auriasistemas net) in /etc/aliases, I get similar messages, ending with: relay=local, delay=0, status=bounced (unknown user: "john") If I put any other external address (for example a yahoo! account), all mail is forwarded OK If I send mail directly to any virtual domain account, from external server, or locally with "mailx", all mail is delivered correctly doesn't postfix understand virtual domains in /etc/aliases? Is there any problem with my configuration? Thanks in advance
I forgot... Relevant conf files (they seem OK): ################################### # # ISPConfig local-host-names Configuration File # Version 1.0 # ################################### localhost eneri.auriasistemas.net localhost.eneri.auriasistemas.net localhost.auriasistemas.net www.auriasistemas.net www.enredo.net www.garabana.com auriasistemas.net enredo.net garabana.com #### MAKE MANUAL ENTRIES BELOW THIS LINE! #### ********************************************************************* # See /usr/share/postfix/main.cf.dist for a commented, more complete version smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU) biff = no # appending .domain is the MUA's job. append_dot_mydomain = no # Uncomment the next line to generate "delayed mail" warnings #delay_warning_time = 4h myhostname = eneri alias_maps = hash:/etc/aliases alias_database = hash:/etc/aliases myorigin = /etc/mailname #mydestination = eneri.auriasistemas.net, localhost.auriasistemas.net, localhost relayhost = mynetworks = 127.0.0.0/8 mailbox_command = mailbox_size_limit = 0 recipient_delimiter = + inet_interfaces = all smtpd_sasl_local_domain = smtpd_sasl_auth_enable = yes smtpd_sasl_security_options = noanonymous broken_sasl_auth_clients = yes smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination smtpd_tls_auth_only = no smtp_use_tls = yes smtpd_use_tls = yes smtp_tls_note_starttls_offer = yes smtpd_tls_key_file = /etc/postfix/ssl/smtpd.key smtpd_tls_cert_file = /etc/postfix/ssl/smtpd.crt smtpd_tls_CAfile = /etc/postfix/ssl/cacert.pem smtpd_tls_loglevel = 1 smtpd_tls_received_header = yes smtpd_tls_session_cache_timeout = 3600s tls_random_source = dev:/dev/urandom home_mailbox = Maildir/ virtual_maps = hash:/etc/postfix/virtusertable mydestination = /etc/postfix/local-host-names ********************************************************************* ################################### # # ISPConfig virtusertable Configuration File # Version 1.0 # ################################### [email protected] web4_daniel [email protected] web4_daniel [email protected] web3_david [email protected] web3_david [email protected] web3_david [email protected] web3_david david@ web3_david web3_david@ web3_david [email protected] web4_david [email protected] web4_david [email protected] web5_david [email protected] web5_david [email protected] web5_david [email protected] web5_david [email protected] web3_shakazulu [email protected] web3_shakazulu [email protected] web3_shakazulu [email protected] web3_shakazulu shakazulu@ web3_shakazulu web3_shakazulu@ web3_shakazulu #### MAKE MANUAL ENTRIES BELOW THIS LINE! #### Intentionally added "sp" before domains This problem is getting me mad!
Hi, i can not see david auriasistemas net email address in your virtusertable file, are you sure it is exist?
It is there. I suppose I accidentaly deleted it obfuscating e-mails I post it again ################################### # # ISPConfig virtusertable Configuration File # Version 1.0 # ################################### [email protected] web4_daniel [email protected] web4_daniel [email protected] web4_daniel [email protected] web4_daniel [email protected] web3_david [email protected] web3_david [email protected] web3_david [email protected] web3_david david@ web3_david web3_david@ web3_david [email protected] web4_david [email protected] web4_david [email protected] web4_david [email protected] web4_david [email protected] web5_david [email protected] web5_david [email protected] web5_david [email protected] web5_david [email protected] web3_shakazulu [email protected] web3_shakazulu [email protected] web3_shakazulu [email protected] web3_shakazulu shakazulu@ web3_shakazulu web3_shakazulu@ web3_shakazulu #### MAKE MANUAL ENTRIES BELOW THIS LINE! #### BTW, it doesn't matter which virtual user I put in /etc/aliases. Postfix allways tries to deliver locally. If there isn't local user matching virtual user, mail is lost. The postfix log after sending a message directly from root console to virtualuser: Jul 24 14:34:27 eneri postfix/pickup[3118]: BC086A11: uid=0 from=<root> Jul 24 14:34:27 eneri postfix/cleanup[3357]: BC086A11: message-id=<20060724123427.BC086A11@eneri> Jul 24 14:34:27 eneri postfix/qmgr[3119]: BC086A11: from=<root eneri spauriasistemas net>, size=287, nrcpt=1 (queue active) Jul 24 14:34:27 eneri postfix/pickup[3118]: D2B08B42: uid=10018 from=<web4_david> Jul 24 14:34:27 eneri postfix/cleanup[3357]: D2B08B42: message-id=<20060724123427.D2B08B42@eneri> Jul 24 14:34:27 eneri postfix/qmgr[3119]: D2B08B42: from=<web4_david eneri spauriasistemas net>, size=359, nrcpt=1 (queue active) Jul 24 14:34:27 eneri postfix/local[3359]: BC086A11: to=<web4_david eneri spauriasistemas net>, orig_to=<david spauriasistemas net>, relay=local, delay=0, status=sent (delivered to command: /usr/bin/procmail -f-) Jul 24 14:34:27 eneri postfix/qmgr[3119]: BC086A11: removed Jul 24 14:34:27 eneri postfix/local[3377]: D2B08B42: to=<admispconfig@localhost>, relay=local, delay=0, status=sent (delivered to command: /usr/bin/procmail -f-) Jul 24 14:34:27 eneri postfix/qmgr[3119]: D2B08B42: removed ************************************************************************* And postfix log after changing /etc/aliases to redirect mail to "shakazulu spenredo net" Jul 24 14:42:54 eneri postfix/pickup[3607]: 506F1A11: uid=0 from=<root> Jul 24 14:42:54 eneri postfix/cleanup[3614]: 506F1A11: message-id=<20060724124254.506F1A11@eneri> Jul 24 14:42:54 eneri postfix/qmgr[3608]: 506F1A11: from=<root eneri spauriasistemas net>, size=292, nrcpt=1 (queue active) Jul 24 14:42:54 eneri postfix/local[3616]: 506F1A11: to=<shakazulu spenredo net>, orig_to=<postmaster spauriasistemas net>, relay=local, delay=0, status=bounced (unknown user: "shakazulu") Jul 24 14:42:54 eneri postfix/cleanup[3614]: 64BDDB42: message-id=<20060724124254.64BDDB42@eneri> Jul 24 14:42:54 eneri postfix/qmgr[3608]: 64BDDB42: from=<>, size=1959, nrcpt=1 (queue active) Jul 24 14:42:54 eneri postfix/qmgr[3608]: 506F1A11: removed Jul 24 14:42:54 eneri postfix/local[3616]: 64BDDB42: to=<shakazulu spenredo net>, orig_to=<root eneri spauriasistemas net>, relay=local, delay=0, status=bounced (unknown user: "shakazulu") Jul 24 14:42:54 eneri postfix/qmgr[3608]: 64BDDB42: removed Thank you
Try to add this to main.cf: virtual_maps = hash:/etc/postfix/virtusertable,hash:/etc/aliases then reload postfix and let's see whats gonna happen.
It solved my problem, thank you very much! It was my fault or is an ISPconfig bug? Should I open a bug?
FYI, this setting (in bold) solved almost the same problem. I have this in /etc/aliases but mail for root mysteriously end up in account web1_spam, which is configured with CatchAll rule. Without CatchAll rule then mail was delivered to right account web1_bruma. So conclusion could be that with CatchAll turned on, postfix ignores /etc/aliases!? Is this a bug?
$mydomain shall not be empty, plese set $mydomain to a technical domain that is not used for receiving emails in ISPConfig. e.g. server1.yourdomain.com and make sure that server1.yourdomain.com resolves to your server IP in DNS.
So, this technical domain should not be hosted as ispconfig domain? Could this be intranet domain used in LAN?
Hmm, now I'm confused. For example, I'm hosting 3 domains, one of them should be used as so called technical domain and on this technical domain I should not have mail accounts? Email account are allowed only on other two domains. Is this technical domain first domain that is used in perfect setup HowTo's (server1.example.com)?
Yes, that would be optimal. Yes. On my servers I also use a domain that I don't use for web sites and emails.