Indramin Darmadi wrote:
> Case :
> I rent a hosting to host all mail to companyname.com.
> There are 2 locations that will download the emails to local mail
> server @ each location (using fetchmail) (because @ my location, we
> don't have dedicated connections and internet is still expensive here).
> Sending out email is using smtp relay to ISP's mail server.
>
> To save bandwidth, I want to sort the outgoing mail so that email for
> local users will be deliver directly, while user with the same domain
> that is not local will go out thru smtp.
>
> For example.
> Office 1 : john@companyname.com, jane@companyname.com
> Office 2 : smith@companyname.com
>
> when john email to jane@companyname.com, I want it to be delivered
> directly to jane local mail box.
> If john email smith, then it will goes out thru internet.
>
> I've trying to set the virtuser but it doesn't seem to work. If I use
> mailertable, I don't think I can specify each user, but the whole
> domain (cmiww). I tried to use procmail, but it seems that it only
> filter the incoming mail.
>
> I'm quite new with sendmail, and 0 knowledge on procmail. I've been
> searcing the net for a few days, but I haven't found what I want.
>
> Please spare me some tips. I'll really appreciate them.
>
> TIA
>
> regards,
> Indramin
>
You may want to think about ldap routing. It's a little bit of a
learning curve, but you can try following the directions here:
http://www.shocknetwork.com/forum/topic28.html
good luck.
Alton