Sponsored Content
Top Forums UNIX for Advanced & Expert Users Need help with sendmail email filtering on FreeBSD Post 302929945 by simplemind on Monday 29th of December 2014 05:38:35 AM
Old 12-29-2014
Need help with sendmail email filtering on FreeBSD

Hi All,
Sorry, for the double posting. Don't know how to move to a different forum.

I am very new to Unix. I have a test server running FreeBSD 10.1 and SendMail 8.14.9.

I need to filter incoming emails based on the sender's email address or domain and forward them to another address on a different domain as well as to the original recipient. Can I achieve this with SendMail and ProcMail?

The server's domain is domain.com. I need to be able to forward emails coming from auser@domain.a or any emails coming from *@domain.b and forward them to auser@domain.c and as well as to the intended recipient @domain.com

Your help will be greatly appreciated.

Regards
 

10 More Discussions You Might Find Interesting

1. BSD

sendmail on FreeBSD

Dear all, I have been using freebsd 5.4 for 2 months using fetchmail to retrieve mails and using sendmail to send mails. I have no problem with fetchmail to retrieve mails from pop3 server. And most of the time I have no problem with sendmail. But recently I found that I could not send... (0 Replies)
Discussion started by: jaguar
0 Replies

2. HP-UX

Sendmail not submitting Email on '.'

I have several HP/UX nodes running Sendmail 8.13 ...some work fine, some don't. When an Email is coming in, the 'DATA' command never ends. The other side of the connection gets to the point where it enters the '.' on a line by itself, but sendmail doesn't accept it...if fact it keeps on holding... (8 Replies)
Discussion started by: john_exonets
8 Replies

3. UNIX and Linux Applications

Sendmail outgoing email rate

Does anyone know what's Sendmail outgoing email rate? e.g. 1000 outgoing email per minutes. If so, can we modify it? Thanks. :) (1 Reply)
Discussion started by: sunmagic2003
1 Replies

4. Shell Programming and Scripting

filtering and sending sar output via email

We have a program which create sar output files which has a weeks data... To read file we use sar -f sa15 command which has multiple days data( a weeks data)....we need to only get last 48 hours data and email it to different users.... I guess we can use combination of sar -o or even awk.... (3 Replies)
Discussion started by: noorm
3 Replies

5. Solaris

Outbound email re-direct using Sendmail

I need to reconfigure Sendmail to strip the SMTP email addresses from all email and replace them with a single address used for testing purposes. I have a vended application hosted on Solaris 10 servers. I have access to support the application framework (IBM WebShere Application Server 6.1),... (1 Reply)
Discussion started by: dunkar70
1 Replies

6. Debian

sendmail taking too much time to send a email

Hi , I'm using sendmail command to send a email. To send a email sendmail taking 3minutes to complete the process. Is there any configuration needs to be done in server or another solution is there to resolve this issue. Thanks in Advance. Regards Latika (1 Reply)
Discussion started by: latika
1 Replies

7. Red Hat

Delay in sending email to-from localhost in Sendmail

Hi Friends, I am very much new to sendmail or any other mta. I just installed sendmail 8.14 on my rhel6 machine. I was trying to send email to local user but after entering the message when i press CTRL-D it simply hangs. I also tried sending email via mutt but again mutt also hangs. It sends... (0 Replies)
Discussion started by: Rohit Bhanot
0 Replies

8. AIX

Set email Priority using sendmail

Hi everyone, I'm trying to send an email on unix using sendmail command. For setting the priority to high I use: X-Priority: 1 And it works on HP but when I tried it on AIX the email is sent but no priority!! Anyone can help me Thanks in advance, Hiposh (3 Replies)
Discussion started by: hiposh
3 Replies

9. UNIX for Dummies Questions & Answers

Help with SendMail Procmail filtering

Hi All, I am very new to Unix. I have a test server running FreeBSD 10.1 and SendMail 8.14.9. I need to filter incoming emails based on the sender's email address or domain and forward them to another address on a different domain as well as to the original recipient. Can I achieve this with... (1 Reply)
Discussion started by: simplemind
1 Replies

10. Shell Programming and Scripting

Unable to recieve email using sendmail

Hi, Here is my script to send out emails. #!/bin/ksh { print "From: Prod@`hostname`.mycomp.com" print "To: me@mycomp.com" print "MIME-Version: 1.0" print "Content-Type: text/html" print "Subject: Usage Report" print "" print... (2 Replies)
Discussion started by: mohtashims
2 Replies
MH-TAILOR(5)							     [nmh-1.5]							      MH-TAILOR(5)

NAME
mh-tailor, mts.conf - mail transport customization for nmh message handler SYNOPSIS
/etc/nmh/mts.conf DESCRIPTION
The file /etc/nmh/mts.conf defines run-time options for those nmh programs which interact (in some form) with the message transport system. At present, these (user) programs are: ap, conflict, inc, msgchk, msh, post, rcvdist, and rcvpack. Each option should be given on a single line. Blank lines and lines which begin with `#' are ignored. The options available along with default values and a description of their meanings are listed below: mts: The mail transport method to use. The two acceptable options are smtp (which is the default), and sendmail. If you use smtp, this will enable a direct SMTP (simple mail transport protocol) interface in nmh. When sending mail, instead of passing the message to the mail transport agent, post will open a socket connection to the mail port on the machine specified in the servers entry. If you use sendmail, then post will send messages by forking a local copy of sendmail. Currently it will still speak SMTP with this local copy of sendmail. localname: The hostname nmh considers local. It should typically be a fully qualified hostname. If this is not set, depending on the version of UNIX you're running, nmh will query the system for this value (e.g. uname, gethostname, etc.), and attempt to fully qualify this value. If you are using POP to retrieve new messages, you may want to set this value to the name of the POP server, so that outgoing message appear to have originated on the POP server. localdomain: If this is set, a `.' followed by this string will be appended to your hostname. This should only be needed, if for some reason nmh is not able to fully qualify the hostname returned by the system (e.g. uname, geth- ostname, etc.). clientname: This option specifies the host name that nmh will give in the SMTP HELO (and EHLO) command, when posting mail. If not set, the default is to use the host name that nmh considers local (see localname above). If this option is set, but empty, no HELO command will be given. Although the HELO command is required by RFC-821, many SMTP servers do not require it. Early versions of SendMail will fail if the hostname given in the HELO command is the local host. Later versions of SendMail will complain if you omit the HELO command. If you run SendMail, find out what your system expects and set this field if needed. systemname: This option is only used for UUCP mail. It specifies the name of the local host in the UUCP "domain". If not set, depending on the version of UNIX you're running, nmh will query the system for this value. This has no equivalent in the nmh configuration file. mmdfldir: /var/mail The directory where maildrops are kept. If this option is set, but empty, the user's home directory is used. This overrides the default value chosen at the time of compilation. mmdflfil: The name of the maildrop file in the directory where maildrops are kept. If this is empty, the user's login name is used. This over- rides the default value (which is empty). mmdelim1: 01010101 The beginning-of-message delimiter for maildrops. mmdelim2: 01010101 The end-of-message delimiter for maildrops. maildelivery: /usr/lib/mh/maildelivery The name of the system-wide default maildelivery file. See slocal(1) for the details. everyone: 200 The highest user-id which should NOT receive mail addressed to "everyone". noshell: If set, then each user-id greater than "everyone" that has a login shell equivalent to the given value (e.g., "/bin/csh") indicates that mail for "everyone" should not be sent to them. This is useful for handling admin, dummy, and guest logins. SMTP support This option is only available if you set mts to smtp. servers: localhost A lists of hosts and networks which to look for SMTP servers when posting local mail. It turns out this is a major win for hosts which don't run an message transport system. The value of servers should be one or more items. Each item is the name of a host which is (hopefully) running a SMTP server. SendMail This option is only available if you set mts to sendmail. sendmail: /usr/sbin/sendmail The pathname to the sendmail program. Post Office Protocol This option is only available if you have compiled nmh with POP support enabled (i.e., "--enable-pop"). pophost: The name of the default POP service host. If this is not set, then nmh looks in the standard maildrop areas for waiting mail, other- wise the named POP service host is consulted. File Locking A few words on locking: nmh has several methods for creating locks on files. When configuring nmh, you will need to decide on the locking style and locking directory (if any). The first controls the method of locking, the second says where lock files should be created. To configure nmh for kernel locking, use the "--with-locking=flock" configure option if you want to use the flock system call; use "--with- locking=lockf" if you want to use the lockf system call; or use "--with-locking=fcntl" if you want to use the fcntl system call for kernel- level locking. Instead of kernel locking, you can configure nmh to use dot locking by using "--with-locking=dot". Dot locking specifies that a file should be created whose existence means "locked" and whose non-existence means "unlocked". The name of this file is constructed by append- ing ".lock" to the name of the file being locked. If "--enable-lockdir=directory" is not specified at build time, lock files will be cre- ated in the directory where the file being locked resides. Otherwise, lock files will be created in the directory specified by "--enable- lockdir". Prior to installing nmh, you should see how locking is done at your site, and set the appropriate values. FILES
/etc/nmh/mts.conf nmh mts configuration file PROFILE COMPONENTS
None SEE ALSO
mh-mts(8), post(8) DEFAULTS
As listed above MH.6.8 11 June 2012 MH-TAILOR(5)
All times are GMT -4. The time now is 03:24 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy