[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: exim to sendmail help



> 1.  how do i tell sendmail to relay email for a group of IPs ?
>     something like this in exim :
>         sender_net_accept_relay = 192.168.1.0/24:192.168.2.0/24

make sure you have the access file feature enabled and add the ip addresses
to the /etc/mail/access file and then run makemap on it (eg. "makemap hash
access.db < access").  the access file doesn't accept cidr notation though
so you have to specify ip addresses using classful notation
(eg. 192.168.1.0/24 would be represented as 192.168.1)

if you don't have the access feature enabled you can enable it by adding the
below line to your /etc/mail/sendmail.mc.

FEATURE(`access_db')

and the run:

# sendmailconfig

and tell it to build a new config based on your sendmail.mc, and then
restart sendmail.

> 2.  in exim, i make a small destribution list (like staff@domain.com)
> by making a user called staff and then putting the ff. in staff's

> may i know how do i do this under sendmail ?  i mean, what should i put
> in the users .forward file ?

typically i would do it like this (don't bother adding the user) and instead
add a line to the /etc/mail/aliases (it might be /etc/aliases i can't
remember) like this:

staff: user1, user2, user3, remoteuser@domain.com

if you want to control it from another file, or a user controllable file you
can do it like this:

owner-staff: root 	(person to get bounces)
staff: :include:/home/larry/etc/stafflist.txt

and stafflist.txt contains email addresses, one per line.

if you really want to do it with a ~/.forward you can.  just list the email
addresses your want to forward, comma seperated and it should work just
fine.

you can test delivery of adresses to see whether the forwarding is working
or not like this:

# sendmail -bv staff (user doesn't exist)
staff... User unknown

# sendmail -bv staff (not being forwarded)
staff... deliverable: mailer local, user staff

# sendmail -bv staff (is being forwarded)
user1... deliverable: mailer local, user user1
user2... deliverable: mailer local, user user2
remoteuser@domain.com... deliverable: mailer esmtp, host mail.domain.com, user remoteuser@domain.com

hope that helps,
adam.


Reply to: