Here's a little script you can add to your crontab, to
periodically email the administrators of each mailman mailing list both
the list of current members and the mailing-list's full configuration.
This gives you both an audit trail of membership and the ability to
restore mailing lists from the backup files in case your webhost goes
awry.
mailman-reminder
(Perl script)
Edit root's crontab with the command
# **
crontab -e**
and add something like this:
0 3 1 * * perl /root/mailman-reminder.pl
Which will run the script at 03:00 on the first day of each month.
Try the command-line utilities:
# /usr/local/psa/bin/mail -i user@example.com
Taken from http://www-personal.umich.edu/~malth/gaptuning/postfix/
however note that the "your_recipients" file in the postfix main.cf,
the "plusone_recipients" in the cron job, and the "example_recipients"
in the Perl file should probably all be the same. -- wl 200808
This method consists of a simple perl script
which uses Net::LDAP to retrieve Active Directory users'
"proxyAddresses" which are both primary and secondary SMTP addresses
(as opposed to using "mail" which would only retrieve a user's primary
SMTP address). Nothing needs to be run on the Active Directory domain
controllers; this script requires only TCP port 389 access to your
Active Directory domain controllers
The resulting output is in the format: "user@example.com OK" which then
must be postmap(ped).
Add the following to your Postfix 2.0+ main.cf to use the
relay_recipient_maps feature of Postfix, which will now reject unknown
users:
relay_recipient_maps = hash:/etc/postfix/your_recipients
Note: the Exchange domains in question MUST be entered in
relay_domains, and NOT in mydestination.
Also note if you would like to prevent Postfix from rejecting with
"User unknown in relay recipient table" and would rather Postfix say
"User unknown" set show_user_unknown_table_name = no in main.cf.
I have the script cronned every hour with the following cron job:
#!/bin/sh
cd /etc/postfix ; ./getadsmtp.pl && postmap plusone_recipients
Conceivably this script can be easily modified to support other LDAP
servers by changing the M$-specific "proxyAddresses" search base and
output modification.