Aliases not added from ISPConfig

Discussion in 'Installation/Configuration' started by gregi, Dec 14, 2007.

  1. gregi

    gregi New Member

    Hi, I have ISPConfig (2.2.18) set up and running on opensuse 10.2. I have 2 domains set up, and I recently added mail.domain1.tld and mail.domain2.tld for user email. Everything seems to be working fine, mail gets sent and recieved, but when I added some aliases to the users, I noticed email to these mails doesn't arrive. I checked etc/aliases and it seems ispconfig doesn't write anything to this file.
    etc/aliases:
    Code:
    # This is the aliases file - it says who gets mail for whom.
    #
    # >>>>>>>>>>      The program "newaliases" will need to be run
    # >> NOTE >>      after this file is updated for any changes
    # >>>>>>>>>>      to show through to sendmail.
    #
    
    # It is probably best to not work as user root and redirect all
    # email to "root" to the address of a HUMAN who deals with this
    # system's problems. Then you don't have to check for important
    # email too often on the root account.
    # The "\root" will make sure that email is also delivered to the
    # root-account, but also forwared to the user "joe".
    #root:          joe, \root
    
    # Basic system aliases that MUST be present.
    postmaster:     root
    mailer-daemon:  postmaster
    
    # amavis
    virusalert:     root
    
    # General redirections for pseudo accounts in /etc/passwd.
    administrator:  root
    daemon:         root
    lp:             root
    news:           root
    uucp:           root
    games:          root
    man:            root
    at:             root
    postgres:       root
    mdom:           root
    amanda:         root
    ftp:            root
    wwwrun:         root
    squid:          root
    msql:           root
    gnats:          root
    nobody:         root
    # "bin" used to be in /etc/passwd
    bin:            root
    
    # Further well-known aliases for dns/news/ftp/mail/fax/web/gnats.
    newsadm:        news
    newsadmin:      news
    usenet:         news
    ftpadm:         ftp
    ftpadmin:       ftp
    ftp-adm:        ftp
    ftp-admin:      ftp
    hostmaster:     root
    mail:           postmaster
    postman:        postmaster
    post_office:    postmaster
    # "abuse" is often used to fight against spam email
    abuse:          postmaster
    spam:           postmaster
    faxadm:         root
    faxmaster:      root
    webmaster:      root
    gnats-admin:    root
    mailman:        root
    mailman-owner:  mailman
    
    # mlmmj needs only one alias to function; this is with a mailinglist in
    # /var/spool/mlmmj/myownlist (remember full path):
    # myownlist: "| /usr/bin/mlmmj-recieve -L /var/spool/mlmmj/myownlist"
    
    # Majordomo can be used to have mailinglists on your site.
    #majordomo:             "|/usr/lib/majordomo/wrapper majordomo"
    #owner-majordomo:       root,
    #majordomo-owner:       root,
    
    # sample entry for a majordomo mailing-list called "test"
    # read /usr/doc/packages/majordomo/README.linux for more information
    # replace "test" with a new name and put the administrator into
    # the "owner-test" alias instead of "root".
    #
    #test:                  "|/usr/lib/majordomo/wrapper resend -l test test-outgoing"
    #test-outgoing:         :include:/var/lib/majordomo/lists/test
    #test-request:          "|/usr/lib/majordomo/wrapper majordomo -l test"
    #test-approval:         owner-test,
    #owner-test-outgoing:   owner-test,
    #
    # if you have bulk_mailer installed, you can replace the above
    # "test-outgoing" line with the following:
    #test-outgoing:         "|/usr/bin/bulk_mailer owner-test@host.com /var/lib/majordomo/lists/test"
    #
    
    It seems etc/postfix/virtusertable is ok

    Code:
    ###################################
    #
    # ISPConfig virtusertable Configuration File
    #         Version 1.0
    #
    ###################################
    user1@mail.domain1.tld    user1
    alias1@mail.domain1.tld    user1
    alias2@mail.domain1.tld    user1
    user2@mail.domain2.tld    user2
    user3@www.domanin2.tld    user3
    user3@domain2.tld    user3
    user4@mail.domain2.tld    user4
    
    #### MAKE MANUAL ENTRIES BELOW THIS LINE! ####
    Has this happened to anyone? am I missing something? Please help :)
     
  2. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    ISPConfig doesn't modify /etc/aliases. It's using /etc/postfix/virtusertable onyl for email aliases.
     
  3. gregi

    gregi New Member

    ah, I see... so then I seem to be missing the entries
    alias1@domain1.tld user1
    alias2@domain1.tld user1

    Is it safe to just add them to the file or will they get overwritten by ISPConfig?
     
  4. till

    till Super Moderator Howtoforge Staff HowtoForge Supporter ISPConfig Developer

    It is not recommended to add them manually. Are the missing aliases listed in the aliases field of the user in the ispconfig interface?
     
  5. gregi

    gregi New Member

    yes, they are listed in ISPConfig
     
  6. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    Are there any warnings in /home/admispconfig/ispconfig/ispconfig.log? What's the output of
    Code:
    ls -la /root/ispconfig
    ?
     
  7. gregi

    gregi New Member

    When I add a new alias in ISPConfig, this gets added to ispcofig.log
    Code:
    22.12.2007 - 11:48:54 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_procmail.lib.php, Line 57: cp -f /root/ispconfig/isp/conf/forward.master /var/www/web6/.forward
    22.12.2007 - 11:48:54 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_procmail.lib.php, Line 113: symlink /var/www/web6/Maildir
    22.12.2007 - 11:48:54 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 137: cp -fr /etc/postfix/local-host-names /etc/postfix/local-host-names~
    22.12.2007 - 11:48:54 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 284: cp -fr /etc/postfix/virtusertable /etc/postfix/virtusertable~
    22.12.2007 - 11:48:54 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 289: postmap hash:/etc/postfix/virtusertable
    22.12.2007 - 11:48:54 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1259: cp -fr /etc/apache2/vhosts/Vhosts_ispconfig.conf /etc/apache2/vhosts/Vhosts_ispconfig.conf~
    22.12.2007 - 11:48:55 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_system.lib.php, Line 728: /etc/init.d/postfix stop &> /dev/null
    22.12.2007 - 11:48:55 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_system.lib.php, Line 728: /etc/init.d/postfix start &> /dev/null
    This is the output of ls -la /root/ispconfig:
    Code:
    total 100
    drwxr-xr-x  9 root root  4096 Dec 22 11:48 .
    drwx------  7 root root  4096 Dec 22 11:52 ..
    -rw-r--r--  1 root root     8 Dec 22 11:48 .old_path_httpd_root
    -rwxr-xr-x  1 root root 34432 Dec  4 12:16 cronolog
    -rwxr-xr-x  1 root root  9673 Dec  4 12:16 cronosplit
    drwxr-xr-x 12 root root  4096 Dec  4 12:06 httpd
    drwxr-xr-x 15 root root  4096 Dec  4 12:16 isp
    drwxr-xr-x  6 root root  4096 Dec  4 12:06 openssl
    drwxr-xr-x  6 root root  4096 Dec  4 12:13 php
    drwxr-xr-x  4 root root  4096 Dec  4 12:16 scripts
    drwxr-xr-x  4 root root  4096 Dec  4 12:16 standard_cgis
    drwxr-xr-x  2 root root  4096 Dec  4 12:16 sv
    -rwx------  1 root root  9389 Dec  4 12:16 uninstall
     
  8. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    The outputs look fine...
    Are you absolutely sure you added the aliases in ISPConfig?
     
  9. gregi

    gregi New Member

    Yes, I tried removing and adding the aliases again, and this seems to be working fine, the only problem I see is that only lines

    alias@mail.domain.tld user
    alias@webmail.domain.tld user

    get added to virtusertable. Am I correct to assume there should also be

    alias@domain.tld

    added to this file? (this does not happen on my server, therefore email sent to alias@domain.tld will not get delivered?)
     
  10. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    Please add a Co-Domain domain.tld (without a hostname) to your web site in ISPConfig.
     
  11. gregi

    gregi New Member

    The problem with that is that I already have a co-domain domain.tld for the site www.domain.tld, so webpages would load by typing either www.domain.tld or just domain.tld in the browser..
     
  12. till

    till Super Moderator Howtoforge Staff HowtoForge Supporter ISPConfig Developer

    Is your problem a email problem or a website problem? In the posts before you talked about email and not your website.
     
  13. gregi

    gregi New Member

    Sorry, I'll try to clear it up a bit.. I have a site in ISPConfig www.domain.tld, with a co-domain domain.tld, where my website is. I have a second site in ISPConfig mail.domain.tld, with a co-domain webmail.domain.tld, where I have my mail software (horde/imp) and to which I add mail users. Users added to this site have mail delivered without problems to user@domain.tld, but when I add an alias to a user, mail to alias@domain.tld doesn't get delivered. I am guessing this is because lines alias@webmail.domain.tld and alias@mail.domain.tld get added to virtusertable, but line alias@domain.tld doesn't.
     
  14. till

    till Super Moderator Howtoforge Staff HowtoForge Supporter ISPConfig Developer

    Ok, then you either have to remove the co-domain domain.tld from the site www.domain.tld and add it to the site webmail.domain.tld or you will have to create the mail users in the site www.domain.tld instead of the site webmail.domain.tld.
     
  15. gregi

    gregi New Member

    oh, okay.. thanks for the help! :)
     

Share This Page