How do I configure exim 3.36 for outgoing mail ? - Linux

This is a discussion on How do I configure exim 3.36 for outgoing mail ? - Linux ; I have a computer on my network that I wish to use for outgoing mail. I have installed the debian package exim 3.36. How do I configure it for outgoing mail ? Other computers on the lan are configured with ...

+ Reply to Thread
Results 1 to 5 of 5

Thread: How do I configure exim 3.36 for outgoing mail ?

  1. How do I configure exim 3.36 for outgoing mail ?

    I have a computer on my network that I wish to use for outgoing mail. I have
    installed the debian package exim 3.36.

    How do I configure it for outgoing mail ?

    Other computers on the lan are configured with a simple mail transport agent
    (ssmtp) which will forward mail to the exim machine (I believe via the smtp
    port).

    My required configuration is as follows:

    Thus lan has been configured with a domain name markhobley.yi.org, thus the
    mail server (charon) will have a fully qualified domain name
    charon.markhobley.yi.org on the lan

    The network address is only a lan address and I require incoming email to be
    addressed to my real email address which is sent to an ISP provided mailbox,
    which is under a different domain name.

    Incoming mail is working fine (I do not require any changes at this time).

    I need to configure exim on charon to send external mail via the smtp server
    provided by my internet service provider.

    The external smtp server has an internet address of smtp.blueyonder.co.uk

    (I am not sure whether or not authentication is required at this time).

    I want to be able to test the ougoing mail using a telnet session to charon.

    This is what happens at the moment:

    mark@venus:~$ telnet charon smtp
    Trying 10.0.0.10...
    Connected to charon.markhobley.yi.org.
    Escape character is '^]'.
    220 charon.markhobley.yi.org ESMTP Exim 3.36 #1 Wed, 05 Jan 2005 00:43:21 +0000
    helo venus.markhobley.yi.org
    250 charon.markhobley.yi.org Hello venus.markhobley.yi.org [10.0.0.2]
    mail from: testout@hotpop.com
    250 is syntactically correct
    rcpt to: mbongo@hotpop.com
    550 relaying to prohibited by administrator

    I have not entered any configuration details to make exim aware of my isp
    outgoing smtp server.

    The file /etc/exim/exim.conf contains the following entries:

    # MAIN CONFIGURATION SETTINGS
    # I've guessed that the local machine name goes here. I have no idea what
    # effect this setting has

    qualify_domain = charon.markhobley.yi.org

    # I don't understand this bit either. I have left it commented, as this was
    # its default setting

    # qualify_recipient =

    # This was filled in by the installer program. I'm not sure whether this is
    # correct.

    # Mail is not forwarded to any other machines. All mail should go to
    # charon and read via imap.

    # maybe this should read
    # local_domains = localhost:markhobley.yi.org

    local_domains = localhost:charon.markhobley.yi.org

    # Allow mail addressed to our hostname, or to our IP address.
    # Ok, I don't understand what these settings do.
    # Cryptic instruction manuals are not much help to me.
    # I have left these settings as default

    local_domains_include_host = true
    local_domains_include_host_literals = true

    # Domains we relay for; that is domains that aren't considered local but we
    # accept mail for them.
    # What you talking about Willis ?

    #relay_domains =

    # No local deliveries will ever be run under the uids of these users
    # Ok, I don't understand this either. What about system messages being sent by
    # daemons (or is it demons ?)
    never_users = root

    # The setting below causes Exim to do a reverse DNS lookup on all incoming
    # IP calls
    # I presume that this adds information to mail headers on incoming mail
    host_lookup = *

    # The setting below would, if uncommented, cause Exim to check the syntax of
    # all the headers that are supposed to contain email addresses (To:, From:,
    # etc). This reduces the level of bounced bounces considerably.
    # I have left this commented as default.

    # headers_check_syntax

    # Exim contains support for the Realtime Blocking List (RBL)
    #rbl_domains = rbl.mail-abuse.org/reject : dialups.mail-abuse.org/warn

    # The setting below allows your host to be used as a mail relay by only
    # the hosts in the specified networks.
    # my lan is 10.0.0.0 with a subnet mask 255.255.255.0
    # It's not working Sydney !!

    host_accept_relay = 127.0.0.1 : ::::1 : 10.0.0.0

    # This setting allows anyone who has authenticated to use your host as a
    # mail relay.
    # I'm not sure whether I need this. I have left the settings as default

    host_auth_accept_relay = *

    # I don't use mangled email addresses
    # percent_hack_domains=*

    # If this option is set, then any process that is running as one of the
    # listed users may pass a message to Exim and specify the sender's
    # address using the "-f" command line option, without Exim's adding a
    # "Sender" header.
    # I don't know the full implications of this
    # I want messages composed by me to have a sender address of mbongo@hotpop.com
    # I want messages from daemons to come from root@machinename or something like
    # that so that I can recognise them as system messages from the various
    # machines on the lan.

    trusted_users = mail:uucp

    # If this option is true, the SMTP command VRFY is supported on incoming
    # SMTP connections; otherwise it is not.
    # I dont know what this does. I will read up on this.
    # I have left this as default.

    smtp_verify = true

    # Some operating systems use the "gecos" field in the system password file
    # to hold other information in addition to users' real names. Exim looks up
    # this field when it is creating "sender" and "from" headers.
    # It would be nice to put email addresses against user names.
    # The machines composing the mail are on the lan, not the local machine, so
    # I don't know whether this will work.
    # I have left this as default. I am still trying to crack the enigma code.

    gecos_pattern = ^([^,:]*)
    gecos_name = $1

    # This sets the maximum number of messages that will be accepted in one
    # connection and immediately delivered. Further ones are accepted and queued
    # but not delivered.
    # I don't know what that means. What happens to queued messages ? When are they
    # sent ? I presume that this does not have any effect on the mail client on
    # the sending machine.

    smtp_accept_queue_per_connection = 100

    # Send a mail to the postmaster when a message is frozen.
    freeze_tell_mailmaster = true

    # This string defines the contents of the \`Received' message header.
    # Ok, I'll look at this later.

    received_header_text = "Received: \
    ${if def:sender_rcvhost {from ${sender_rcvhost}\n\t}\
    {${if def:sender_ident {from ${sender_ident} }}\
    ${if def:sender_helo_name {(helo=${sender_helo_name})\n\t}}}}\
    by ${primary_hostname} \
    ${if def:received_protocol {with ${received_protocol}}} \
    (Exim ${version_number} #${compile_number} (Debian))\n\t\
    id ${message_id}\
    ${if def:received_for {\n\tfor <$received_for>}}"

    # Attempt to verify recipient address before receiving mail, so that mails
    # to invalid addresses are rejected rather than accepted and then bounced.

    receiver_try_verify = true

    # Ok
    #accept_8bitmime = true

    # This will cause it to accept mail only from the local interface
    # Should I uncomment this and set it to 10.0.0.0 ?
    #local_interfaces = 127.0.0.1

    # If this next line is uncommented, any user can see the mail queue
    # by using the mailq command or exim -bp.

    #queue_list_requires_admin = false

    # The errors_copy line will cause the specified address to receive a copy
    # of bounces generated on the system.

    #errors_copy = *@* postmaster@yourdomain

    #
    end

    # TRANSPORTS CONFIGURATION
    # I have configured local delivery. Incoming mail from my ISP mailbox works.

    local_delivery:
    driver = appendfile
    group = mail
    mode = 0660
    mode_fail_narrower = false
    envelope_to_add = true
    return_path_add = true
    # file = /var/mail/${local_part}
    directory=${home}/Maildir
    maildir_format = true
    prefix = ""

    # This transport is used for handling pipe addresses generated by
    # alias or .forward files. If the pipe generates any standard output,
    # it is returned to the sender of the message as a delivery error.
    # Ok, stick that in your pipe and smoke it. You need to smoke some
    # whacky baccy to understand this.

    address_pipe:
    driver = pipe
    path = /usr/bin:/bin:/usr/local/bin
    return_fail_output

    # This transport is used for handling file addresses generated by alias
    # or .forward files.

    address_file:
    driver = appendfile
    envelope_to_add = true
    return_path_add = true

    address_directory:
    driver = appendfile
    no_from_hack
    prefix = ""
    suffix = ""
    # maildir_format

    # This transport is used for handling autoreplies generated by the filtering
    # option of the forwardfile director.

    address_reply:
    driver = autoreply

    # This transport is used for procmail
    # Huh ? I'm not using procmail.

    procmail_pipe:
    driver = pipe
    command = "/usr/bin/procmail"
    return_path_add
    delivery_date_add
    envelope_to_add
    # check_string = "From "
    # escape_string = ">From "
    suffix = ""

    # This transport is used for delivering messages over SMTP connections.
    # Does my ISPs server go here ?

    remote_smtp:
    driver = smtp
    # authenticate_hosts = smarthost.isp.com

    end

    # DIRECTORS CONFIGURATION

    # This allows local delivery to be forced, avoiding alias files and
    # forwarding. Ok, my head is hurting. This has been left as default.

    real_local:
    prefix = real-
    driver = localuser
    transport = local_delivery

    # This director handles aliasing using a traditional /etc/aliases file.
    # It gets worse

    system_aliases:
    driver = aliasfile
    file_transport = address_file
    pipe_transport = address_pipe
    file = /etc/aliases
    search_type = lsearch
    # user = list
    # Uncomment the above line if you are running smartlist

    # This director handles forwarding using traditional .forward files.
    # What is a .forward file ? I need to read about these. Do I need one ?

    userforward:
    driver = forwardfile
    file_transport = address_file
    pipe_transport = address_pipe
    reply_transport = address_reply
    no_verify
    check_ancestor
    check_local_user
    file = .forward
    modemask = 002
    filter

    # This director runs procmail for users who have a .procmailrc file
    # I don't have procmail as far as I know. My mail clients access the mail on
    # this machine via imap.

    procmail:
    driver = localuser
    transport = procmail_pipe
    require_files =
    ${local_part}:+${home}:+${home}/.procmailrc:+/usr/bin/procmail
    no_verify

    # This director matches local user mailboxes.

    localuser:
    driver = localuser
    transport = local_delivery

    end

    # ROUTERS CONFIGURATION

    # This router routes to remote hosts over SMTP using a DNS lookup with
    # default options.

    lookuphost:
    driver = lookuphost
    transport = remote_smtp

    # This router routes to remote hosts over SMTP by explicit IP address,
    # given as a "domain literal" in the form [nnn.nnn.nnn.nnn].
    # I'm really tired now. What is this ?

    literal:
    driver = ipliteral
    transport = remote_smtp

    end

    # RETRY CONFIGURATION
    # I will look at this later

    # Domain Error Retries
    # ------ ----- -------

    * * F,2h,15m; G,16h,2h,1.5; F,10d,8h

    end

    # REWRITE CONFIGURATION

    *@charon.markhobley.yi.org ${lookup{$1}lsearch{/etc/email-addresses}\
    {$value}fail} frFs


    end

    # AUTHENTICATION CONFIGURATION

    # This was all commented out

    # End of File
    # Thank god for that.

    Thanks in advance to anyone who can help with this or who can help me to
    understand any of this lot.

    Regards,

    Mark.

    --

    Mark Hobley
    393 Quinton Road West
    QUINTON
    Birmingham
    B32 1QE

    Reply to: markhobley at hotpop dot do_not_type_this_bit com

    http://markhobley.yi.org/

  2. Re: How do I configure exim 3.36 for outgoing mail ?

    On Wed, 05 Jan 2005 01:58:22 GMT,
    markhobley@hotpop.deletethisbit.co.uk (Mark Hobley) wrote:

    >I have a computer on my network that I wish to use for outgoing mail. I have
    >installed the debian package exim 3.36.
    >
    >How do I configure it for outgoing mail ?
    >
    >250 charon.markhobley.yi.org Hello venus.markhobley.yi.org [10.0.0.2]
    >mail from: testout@hotpop.com
    >250 is syntactically correct
    >rcpt to: mbongo@hotpop.com
    >550 relaying to prohibited by administrator
    >

    You need to configure the relay_domains to include hotpop.com.

    But you also really should update to Exim4. Exim3 is not supported by
    the software author.

    Cheers,

    Cliff
    --

    The National Party manifesto can be viewed here:

    http://www.labour.org.nz/policy/index.html

  3. Re: How do I configure exim 3.36 for outgoing mail ?

    In alt.comp.os.linux Enkidu wrote:
    > On Wed, 05 Jan 2005 01:58:22 GMT,
    > markhobley@hotpop.deletethisbit.co.uk (Mark Hobley) wrote:
    >
    >>I have a computer on my network that I wish to use for outgoing mail. I have
    >>installed the debian package exim 3.36.
    >>
    >>How do I configure it for outgoing mail ?


    > You need to configure the relay_domains to include hotpop.com.


    Is that because my return address is mbongo@hotpop.com ?

    Does that mean if I edit the sender address from within the mail client that I
    have to also edit the relay_domains entry on the mail server?

    >
    > But you also really should update to Exim4.


    I don't like Exim4. It is an unweildy monster with millions of configuration
    files.

    It looks a lot more complicated than Exim3.
    I believe in small and simple solutions.

    Thanks for your help so far. I'll try that relay domain stuff.

    Regards,

    Mark.

    --

    Mark Hobley
    393 Quinton Road West
    QUINTON
    Birmingham
    B32 1QE

    Reply to: markhobley at hotpop dot do_not_type_this_bit com

    http://markhobley.yi.org/

  4. Re: How do I configure exim 3.36 for outgoing mail ?

    On Wed, 05 Jan 2005 13:58:10 GMT,
    markhobley@hotpop.deletethisbit.co.uk (Mark Hobley) wrote:
    >
    >> But you also really should update to Exim4.

    >
    >I don't like Exim4. It is an unweildy monster with millions of configuration
    > files.
    >
    >It looks a lot more complicated than Exim3.
    >I believe in small and simple solutions.
    >

    In fact, it isn't.

    There is *one* conf file that is used by the system, and you can
    maintain it by hand. However, there are, as you say, a number of small
    files that are used to generate the main file.

    This "lot of small files" approach is becoming more common these days.

    Cheers,

    Cliff
    --

    The National Party manifesto can be viewed here:

    http://www.labour.org.nz/policy/index.html

  5. Re: How do I configure exim 3.36 for outgoing mail ?

    In alt.comp.os.linux Enkidu wrote:

    > You need to configure the relay_domains to include hotpop.com.


    Ok, I did this.

    I don't get the 550 error any more, and I did compose a message and get a
    message ID.

    It didn't appear in my inbox though, so I don't know where it has gone yet. I
    am currently investigating this.

    The problem that I have now is that if I compose a message to someone at an
    address that isn't at hotpop.com, I get the 550 error again.

    I want to be able to sent email to anyone with a valid email address in the
    format recipient@mailprovider.com

    Can I use something like "relay_domains = *" to allow me to send email to
    anyone ?

    Thanks in advance to anyone who can answer this.

    Regards,

    Mark.

    --

    Mark Hobley
    393 Quinton Road West
    QUINTON
    Birmingham
    B32 1QE

    Reply to: markhobley at hotpop dot do_not_type_this_bit com

    http://markhobley.yi.org/

+ Reply to Thread