Solved

Can I resend emails to original recipient that were returned to sender for policy reasons (using Sendmail)?

Posted on 2012-04-12
4
469 Views
Last Modified: 2012-07-29
I have a sendmail server that sent emails to another server (not sendmail)  in our infrastructure.  The emails were rejected for policy reasons and therefore returned to original sender not put in the queue for retry.  
The sender is a service and not an actual user so they are sitting in an unused mail file.  

Is there a command to resend all these messages that are in the users mailfile  /var/spool/mail/usersfile    to the originally intended recipients?


Thanks
0
Comment
Question by:DanRaposo
  • 3
4 Comments
 
LVL 17

Expert Comment

by:fgrushevsky
ID: 37837786
There is no command for this, but there are some scriprs available here and there

please check the one referenced here
http://www.jules.fm/Logbook/files/resend_mbox.html
0
 

Author Comment

by:DanRaposo
ID: 37838043
This seems to parse out the messages but does not parse out the intended recipient in the For line.

So all messages are being sent to one recipient.  As far as I can tell ... but I need it to determine who that proper recipient is.

Example from file is below ... I want it to send the email to tdoe

Return-Path: <asterisk@phone.mydomain.com>
Received: from phone.ritesolutions.com (phone.mydomain.com [127.0.0.1])
        by phone.mydomain.com (8.13.8/8.13.8) with ESMTP id p2IHCjlg009120
        for <tdoe@mydomain.com>; Fri, 18 Mar 2011 13:12:45 -0400
Received: (from asterisk@localhost)
        by phone.mydomain.com (8.13.8/8.13.8/Submit) id p2IHCjal009119;
        Fri, 18 Mar 2011 13:12:45 -0400
Date: Fri, 18 Mar 2011 13:12:45 -0400
From: "Rite Voicemail System" <vm@asterisk>
To: "Tom Doe" <tdoe@mydomain.com>
Subject: New message 1 in mailbox 195
Message-ID: <Asterisk-1-2060776519-195-3454@phone.mydomain.com>
X-Asterisk-CallerID: 918604332358
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="----voicemail_11953454315958324"
0
 

Accepted Solution

by:
DanRaposo earned 0 total points
ID: 38218503
Wrote a perl script to help with this issue.
0
 

Author Closing Comment

by:DanRaposo
ID: 38235315
No other answer was able to help me.
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

MS outlook is a premier email client that enable you to send and receive the e-mails with various file formats of attachments such as document files, media file, and many others formats. There is some scenario occurs when a receiver of an e-mail mes…
Granting full access permission allows users to access mailboxes present in their database. By giving full access permission one can open and read the content of any mailbox but cannot send emails from that mailbox.
In this video we show how to create an Address List in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Organization >> Ad…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now