Mail server problem

Discussion in 'Server Operation' started by ColdDoT, Jan 31, 2006.

  1. ColdDoT

    ColdDoT New Member

    Hello i have switched my OS from SuSe to debian
    now i have running every thing except mail server
    i have setted up a mail server with the virtual user tutorial from falko

    but i have followed the tut but my email cleant says:
    Login fout (Maildir: No such file or directory)
    In my /var/log/mail.log is notting changed

    so who can help me pleaz

    greets colddot
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Please send an email to this account. The maildir is created when you send the first email to the account.

    If you use ISPConfig, make sure you checked the Maildir checkbox in ISPConfig under management > server > Settings on the mail tab.
     
  3. ColdDoT

    ColdDoT New Member

    strange
    when i send a message to my server from a extern smtp server
    i dont't get my message back from te smtp server but my maildir fault stils remain

    is there any other solution for this problem
    (BTW i don't use ISPconfig)
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Did you see in the maillog of your server, that the message arrived at your server at all? Please try to send an email to the account using your server as smtp server.
     
  5. ColdDoT

    ColdDoT New Member

    Mmmm my mail server says:
    <[email protected]>: mail for 10.0.0.13 loops back to myself

    what does it means
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    I know this error only in the form "domainxy.com loops back to myself". This means that you have to add domainxy.com in your mydestination variable in postfix main.cf. Maybe you can add IP addresses there as well.
     
  7. falko

    falko Super Moderator ISPConfig Developer

    Please post /etc/postfix/main.cf here.
    Is 81.69.79.160 the IP address of your server?
    BTW, you should consider creating an MX record for colddot.nl.
     
  8. ColdDoT

    ColdDoT New Member

    How do you mean create mx record ? i have a externe name server for www.colddot.nl
    name server = ns1.nsnoc.com
    name server = ns2.nsnoc.com

    and the ip of my server is indeed 81.69.79.160
    so www.colddot.nl is the same as 81.69.79.160 :D
    or i don't get your point :S

    but here is my main.cf from my postfix
    # 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 = colddot.nl
    alias_maps = hash:/etc/aliases
    alias_database = hash:/etc/aliases
    myorigin = /etc/mailname
    mydestination = pop.colddot.nl, localhost, localhost.localdomain, colddot.nl
    relayhost =
    mynetworks = 127.0.0.0/8
    mailbox_command = procmail -a "$EXTENSION"
    mailbox_size_limit = 0
    recipient_delimiter = +
    inet_interfaces = all
    virtual_alias_domains =
    virtual_alias_maps = proxy:mysql:/etc/postfix/mysql-virtual_forwardings.cf, proxy:mysql:/etc/postfix/mysql-virtual_email2email.cf
    virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql-virtual_domains.cf
    virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailboxes.cf
    virtual_mailbox_base = /home/vmail
    virtual_uid_maps = static:5000
    virtual_gid_maps = static:5000
    smtpd_sasl_auth_enable = yes
    broken_sasl_auth_clients = yes
    smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
    smtpd_use_tls = yes
    smtpd_tls_cert_file = /etc/postfix/smtpd.cert
    smtpd_tls_key_file = /etc/postfix/smtpd.key
    transport_maps = proxy:mysql:/etc/postfix/mysql-virtual_transports.cf
    virtual_create_maildirsize = yes
    virtual_mailbox_extended = yes
    virtual_mailbox_limit_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailbox_limit_maps.cf
    virtual_mailbox_limit_override = yes
    virtual_maildir_limit_message = "The user you are trying to reach is over quota."
    virtual_overquota_bounce = yes
    proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks $virtual_mailbox_limit_maps
    content_filter = amavis:[127.0.0.1]:10024
    receive_override_options = no_address_mappings
    smtpd_sasl_local_domain =
    smtpd_sasl_security_options = noanonymous
    smtpd_tls_auth_only = no
    smtp_use_tls = yes
    smtp_tls_note_starttls_offer = yes
    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

    And a other thing why is it taken so long to send a mail from a webpage whit my local smtp server ( it takes about 2.5 min)

    Sorry for the late respons but i have a lot on my head :(
     
  9. falko

    falko Super Moderator ISPConfig Developer

    The A records are ok, but you didn't create an MX record for your domain (you can see that when you run
    Code:
    dig mx colddot.nl
    )
    For example, you could create an A record for mail.colddot.nl pointing to 81.69.79.160, and then you create an MX record for colddot.nl, like
    Code:
    colddot.nl MX 10 mail.colddot.nl
    Looks ok. What's in /etc/mailname?

    Can you see anything in the mail log?
     
  10. ColdDoT

    ColdDoT New Member

    sorry i maked a fault in my dns admin
    solved now

    in my mailname is
    server.colddot.nl

    in my mail log is:
    is a lot of info but i dont post it here( a lot of rules)
    here is the link where you can find the file
    http://www.colddot.nl/mail.log

    thx a lot for everything you have done for me (already)
    and BTW sorry that my english sucks :( i'm dutch
     
  11. ColdDoT

    ColdDoT New Member

    little of topic
    how do you auto start a sh file in /etc/init.d/(example->)ts
    in debian
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    In the directory /etc are several directorys rc0.d .... rc6.d. The numbers of these directorys correspond to the linux runlevels. If you create a symlink in one of these directorys pointing to your start script in /etc/init.d, your script will be executed when the linux system starts the selected runlevel.

    If you go to /etc/rc3.d for example and execute the command "ls", you can see which services are started in runlevel 3.

    There is also a script that can create the symlinks for you if you dont want to do it manually. To get more infos on how to use the update-rc.d script, run this command on the shell:

    man update-rc.d
     
  13. falko

    falko Super Moderator ISPConfig Developer

    In your specific example (/etc/init.d/ts) you can simply run
    Code:
    update-rc.d ts defaults
    Make sure /etc/init.d/ts is executable.
     
  14. falko

    falko Super Moderator ISPConfig Developer

    Does Postfix listen on all interfaces? Is inet_interfaces set to all in /etc/postfix/main.cf? What's the output of
    Code:
    netstat -tap
    ?
     
  15. ColdDoT

    ColdDoT New Member

    inet_interfaces set to all.
    server:~# netstat -tap
    Active Internet connections (servers and established)
    Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
    tcp 0 0 *:imaps *:* LISTEN 1404/couriertcpd
    tcp 0 0 *:pop3s *:* LISTEN 1427/couriertcpd
    tcp 0 0 localhost.localdo:10024 *:* LISTEN 1323/amavisd (maste
    tcp 0 0 localhost.localdo:10025 *:* LISTEN 1643/master
    tcp 0 0 localhost.localdo:mysql *:* LISTEN 1496/mysqld
    tcp 0 0 *:pop3 *:* LISTEN 1413/couriertcpd
    tcp 0 0 *:imap2 *:* LISTEN 1387/couriertcpd
    tcp 0 0 *:www *:* LISTEN 1791/httpd
    tcp 0 0 *:ftp *:* LISTEN 1656/pure-ftpd (SER
    tcp 0 0 10.0.0.13:domain *:* LISTEN 1311/named
    tcp 0 0 localhost.locald:domain *:* LISTEN 1311/named
    tcp 0 0 *:ssh *:* LISTEN 1676/sshd
    tcp 0 0 *:smtp *:* LISTEN 1643/master
    tcp 0 0 localhost.localdoma:953 *:* LISTEN 1311/named
    tcp 0 0 localhost.localdo:mysql localhost.localdo:32775 ESTABLISHED1496/mysqld
    tcp 0 300 10.0.0.13:ssh ip3e830323.speed.:14159 ESTABLISHED3305/0
    tcp 0 0 localhost.localdo:32775 localhost.localdo:mysql ESTABLISHED1705/amavisd (child
    tcp 0 0 10.0.0.13:pop3 ip3e830323.speed.:14163 TIME_WAIT -
     
  16. falko

    falko Super Moderator ISPConfig Developer

    Is 81.69.79.160 your public IP address? Is your server connected directly to the internet, or is it behind a router? If it is behind a router, did you forward port 25 from your router to your server?
     
  17. ColdDoT

    ColdDoT New Member

    Yes 81.69.79.160 is public ip no dynamic ip
    i've got a router but i have forwarded the ports
    80=web
    21=ftp
    22=ssh
    666=Teamspeak Server
    110=pop
    25=smtp
     
  18. till

    till Super Moderator Staff Member ISPConfig Developer

    I just tried to your external IP on port 25 and got a connection refused. Please ask your internet service provider if they block connections on port 25.
     
  19. ColdDoT

    ColdDoT New Member

    no they don't i know it for sure because i have runned a smtp server on poort 25 before only then on a windows box
     
  20. falko

    falko Super Moderator ISPConfig Developer

    Did you forward port 25 to the correct server? If so, is maybe your firewall blocking requests on port 25? Please post the output of
    Code:
    iptables -L
     

Share This Page