Postfix

Discussion in 'General' started by alexillsley, Mar 22, 2007.

  1. alexillsley

    alexillsley New Member

    Hi,
    I removed postfix from my computer the reinstalled it again and followed all the instructions from the perfect setup to do with it, however it will not let me send mail to my server. When i try and send an email to it from hotmail i get the following error sent from the postmaster:
    Code:
    Reporting-MTA: dns;bay0-omc2-s36.bay0.hotmail.com
    Received-From-MTA: dns;BAY101-W21
    Arrival-Date: Wed, 21 Mar 2007 15:51:08 -0700
    
    Final-Recipient: rfc822;support@****.co.uk
    Action: failed
    Status: 5.7.1
    Diagnostic-Code: smtp;554 5.7.1 <support@****.co.uk>: Recipient address rejected: Relay access denied
    All my users + domains are in /etc/postfix/local-host-names and /etc/postfix/virtusertable

    Is there anyway i can get this to work:confused: It doesnt let me send mail to any address on my server even if it exists!

    Thanks,
    alex
     
  2. edge

    edge Active Member Moderator

    Did you enable "My outgoing server SMTP requires authentication" in your email client?


    *** EDIT *** after reading your problem again, I see that it's FROM a hotmail to your server...
    So.. what I'm asking you above does not work for you.. My error..
     
  3. alexillsley

    alexillsley New Member

    Any ideas? Anyone? I really need to get my mail server to work
     
  4. falko

    falko Super Moderator Howtoforge Staff

  5. alexillsley

    alexillsley New Member

    It appears to be on a few, as its a dynamic ip.

    I know i shouldnt use a dynamic ip for a server but it only resets everytime i reconnect to the internet which doesnt happen much at all really usally just a permenent connection. However tommorow my ISP will finally give me static ip:)

    I will just reconnect to my isp to get a new ip for now, then try sending an email to it
     
  6. alexillsley

    alexillsley New Member

    Ok, I have changed my ip.

    Its very strange, i cant even seem to be able to send email to myself. I tried using the webmail program to send myself an email however it never recevies this:confused: I send an email to my hotmail account and recives that. Any ideas?

    by the way: i checked the postqueue and thats empty
     
  7. Hans

    Hans Moderator Moderator

    What is in your Postfix configuration file main.cf ?
     
  8. alexillsley

    alexillsley New Member

    Here is the contents of main.cf
    Code:
    #soft_bounce = no
    
    
    queue_directory = /var/spool/postfix
    
    
    command_directory = /usr/sbin
    
    
    daemon_directory = /usr/lib/postfix
    
    mail_owner = postfix
    
    
    unknown_local_recipient_reject_code = 550
    debug_peer_level = 2
    
    
    debugger_command =
    	 PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
    	 xxgdb $daemon_directory/$process_name $process_id & sleep 5
    
    # If you can't use X, use this to capture the call stack when a
    # daemon crashes. The result is in a file in the configuration
    # directory, and is named after the process name and the process ID.
    #
    # debugger_command =
    #	PATH=/bin:/usr/bin:/usr/local/bin; export PATH; (echo cont;
    #	echo where) | gdb $daemon_directory/$process_name $process_id 2>&1
    #	>$config_directory/$process_name.$process_id.log & sleep 5
    #
    # Another possibility is to run gdb under a detached screen session.
    # To attach to the screen sesssion, su root and run "screen -r
    # <id_string>" where <id_string> uniquely matches one of the detached
    # sessions (from "screen -list").
    #
    # debugger_command =
    #	PATH=/bin:/usr/bin:/sbin:/usr/sbin; export PATH; screen
    #	-dmS $process_name gdb $daemon_directory/$process_name
    #	$process_id & sleep 1
    
    # INSTALL-TIME CONFIGURATION INFORMATION
    #
    # The following parameters are used when installing a new Postfix version.
    # 
    # sendmail_path: The full pathname of the Postfix sendmail command.
    # This is the Sendmail-compatible mail posting interface.
    # 
    sendmail_path = /usr/sbin/sendmail
    
    # newaliases_path: The full pathname of the Postfix newaliases command.
    # This is the Sendmail-compatible command to build alias databases.
    #
    newaliases_path = /usr/bin/newaliases
    
    # mailq_path: The full pathname of the Postfix mailq command.  This
    # is the Sendmail-compatible mail queue listing command.
    # 
    mailq_path = /usr/bin/mailq
    
    # setgid_group: The group for mail submission and queue management
    # commands.  This must be a group name with a numerical group ID that
    # is not shared with other accounts, not even with the Postfix account.
    #
    setgid_group = maildrop
    
    # html_directory: The location of the Postfix HTML documentation.
    #
    html_directory = /usr/share/doc/packages/postfix/html
    
    # manpage_directory: The location of the Postfix on-line manual pages.
    #
    manpage_directory = /usr/share/man
    
    # sample_directory: The location of the Postfix sample configuration files.
    # This parameter is obsolete as of Postfix 2.1.
    #
    sample_directory = /usr/share/doc/packages/postfix/samples
    
    # readme_directory: The location of the Postfix README files.
    #
    readme_directory = /usr/share/doc/packages/postfix/README_FILES
    inet_protocols = all
    biff = no
    mydomain = ******
    myhostname = server1.$mydomain
    mynetworks = 127.0.0.0/8
    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,check_relay_domains
    inet_interfaces = all
    alias_maps = hash:/etc/aliases
    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
     
    Last edited: Apr 2, 2007
  9. Hans

    Hans Moderator Moderator

    One more question: do you use ISPConfig and the Maildir format?
     
  10. alexillsley

    alexillsley New Member

    yes.......
     
  11. Hans

    Hans Moderator Moderator

    I would try to add these lines:

    mydestination = /etc/postfix/local-host-names
    relay_domains = $mydestination
    virtual_maps = hash:/etc/postfix/virtusertable
    home_mailbox = Maildir/

    And restart Postfix with:

    /etc/init.d/postfix restart
     
  12. alexillsley

    alexillsley New Member

    Thanks alot hans!!! It works perfectly now, hotmail will send to it, and locally i can send to it.

    Thanks again!:)
     
  13. Hans

    Hans Moderator Moderator

    You're welcome!


    PS.:
    As you use ISPConfig, the line:

    home_mailbox = Maildir/

    Is not really necessary, but it will not hurt!
     

Share This Page