postfix doesn't work correctly

Discussion in 'Installation/Configuration' started by LeoLinux, Aug 25, 2006.

  1. LeoLinux

    LeoLinux New Member

    Hi there,

    My email workst just the half way as it should ;-) I didi anything wrong or forget something but I couldn't find it by myself.
    I can connect to the mailserver with outlook and thunderbird etc.. even the webinterface (roudcube and squirrelMail works fine. recieving mails works correctly, but sending mails doesen't work.... in outlook express it says ... mail server not found ... in thunderbird the same .. that sounds as if I forgot something .... ;-/ but what ?


    here my postfix main.cf:

    Code:
    # See /usr/share/postfix/main.cf.dist for a commented, more complete version
    
    smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
    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 = server1.pc1service.gotdns.com
    alias_maps = hash:/etc/aliases
    alias_database = hash:/etc/aliases
    myorigin = /etc/mailname
    #mydestination = server1.pc1service.gotdns.com, localhost.pc1service.gotdns.com, localhost
    relayhost =
    mynetworks = 127.0.0.0/8
    mailbox_size_limit = 0
    recipient_delimiter = +
    inet_interfaces = all
    mailbox_command =
    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
    
    I'm using POP...


    thanks for helping ;-)

    best regards Leander
     
  2. falko

    falko Super Moderator Howtoforge Staff

    Do you use an FQDN or an IP address in your email client as SMTP/POP server? If you use an FQDN, I guess it's a DNS problem.
    What's the output of
    Code:
    netstat -tap
    and
    Code:
    iptables -L
    ?
     
  3. falko

    falko Super Moderator Howtoforge Staff

    Please open a new thread for this.
     
  4. dedibox

    dedibox New Member

  5. LeoLinux

    LeoLinux New Member

    Hi,

    ok,

    Code:
    root@server1:~# netstat -tap
    Active Internet connections (servers and established)
    Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
    tcp        0      0 *:mysql                 *:*                     LISTEN     2230/mysqld
    tcp        0      0 *:81                    *:*                     LISTEN     2446/ispconfig_http
    tcp        0      0 *:ftp                   *:*                     LISTEN     1371/proftpd: (acce
    tcp        0      0 server1.pc1servi:domain *:*                     LISTEN     2674/named
    tcp        0      0 localhost.locald:domain *:*                     LISTEN     2674/named
    tcp        0      0 *:smtp                  *:*                     LISTEN     1455/master
    tcp        0      0 localhost.localdoma:953 *:*                     LISTEN     2674/named
    tcp6       0      0 *:imaps                 *:*                     LISTEN     2134/couriertcpd
    tcp6       0      0 *:pop3s                 *:*                     LISTEN     2173/couriertcpd
    tcp6       0      0 *:pop3                  *:*                     LISTEN     2151/couriertcpd
    tcp6       0      0 *:imap2                 *:*                     LISTEN     2107/couriertcpd
    tcp6       0      0 *:www                   *:*                     LISTEN     2482/apache2
    tcp6       0      0 *:ssh                   *:*                     LISTEN     2370/sshd
    tcp6       0      0 ip6-localhost:953       *:*                     LISTEN     2674/named
    tcp6       0      0 *:https                 *:*                     LISTEN     2482/apache2
    tcp6       0      0 server1.pc1service.:ssh ::ffff:192.168.1.:57121 ESTABLISHED2371/0
    root@server1:~#
    

    and:

    Code:
    root@server1:~# iptables -L
    Chain INPUT (policy ACCEPT)
    target     prot opt source               destination
    
    Chain FORWARD (policy ACCEPT)
    target     prot opt source               destination
    
    Chain OUTPUT (policy ACCEPT)
    target     prot opt source               destination
    root@server1:~#
    
    I have a dynamic IP - so I use DynDNS...what do I have to change?

    Thanks!

    Leander ;-)
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    This looks fine so far. Is your workstation inside your private network? What did you use as SMTP server in outlook? Your dyndns domain or your internal IP address?
     
  7. LeoLinux

    LeoLinux New Member

    The Server is inside a Privat Network (192.168.1.101) The Ports are successfully forwarded.

    Code:
     WAN  	 TCP  	 25 (SMTP)  	 192.168.1.101  	 25 (SMTP)  	 SMTP-Server1
     WAN  	 TCP  	 110 (POP3)  	 192.168.1.101  	 110 (POP3)  	 POP3-Server1
     WAN  	 TCP  	 143 (IMAP)  	 192.168.1.101  	 143 (IMAP)  	 IMAP-Server1
     WAN  	 TCP  	 993  	 192.168.1.101  	 993  	 IMAPs-Server1
     WAN  	 TCP  	 995  	 192.168.1.101  	 995  	 POP3s-Server1
    
    
    my Outlook entries:

    POP-Server: pc1service.gotdns.com and as SMTP-Server the same. POP works, SMTP not ;-/

    for what is the optipn Backup MX in DynDNS.org? Is it necessarry to tick this option?

    Code:
    Your modifications have been completed. Details of the new settings are below.
    Hostname: 	pc1service.gotdns.com
    IP Address: 	84.164.159.69
    Wildcard: 	Y
    Mail Exchanger: 	none
    Backup MX: 	N
    Code:
    root@server1:~# hostname
    server1.pc1service.gotdns.com
    root@server1:~# hostname -f
    server1.pc1service.gotdns.com
    
     
    Last edited: Aug 27, 2006
  8. falko

    falko Super Moderator Howtoforge Staff

    You don't need the Backup MX.

    Is your client PC in the same network than your mail server? If so, please try your mail server's internal IP address in your email client.

    I guess your ISP is blocking port 25. I'd contact them and ask.
     
  9. LeoLinux

    LeoLinux New Member

    Hi Till,

    you guessed right ;-) - now it's able to communicate with the server. But if I try to send an email it says that the mail is to big to send but there is only the word test in it no attachments and stuff like that. The mailbox should be big enough - so what's the matter?
    and how to fix that the server is able to communticate without beeing in the localnetwork?

    Thank you and Falko very much ;-)

    Leo

    [edit]
    SquirrelMail suddenly shows me this error when I'm trying to send an email via the webinterface .. ?!

    Requested action not taken: insufficient system storage
    Server replied: 452 Insufficient system storage

    [edit again]

    ^^ I think my harddrive is full - only 13MB left ... have to check (& renew) this out first ...

    Leo
     
    Last edited: Aug 30, 2006
  10. till

    till Super Moderator Staff Member ISPConfig Developer

    You can try to remove some of the old logfiles in /var/log
     
  11. LeoLinux

    LeoLinux New Member

    Ok I did. So now it's working if I enter the IP adress instead of the domain. but only in the local network ant not from outside ;-)

    any idea? ports in the router are forwarded and tested with nmap ... :-?


    thx! Leander
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    Does it work when you use your external IP?
     
  13. LeoLinux

    LeoLinux New Member

Share This Page