Nakropal script to search for the fate of the letter in the MTA log.
You can download from the
project page .
Wishes, additions, corrections - in GitHub. Short description - under the cut.
SYNOPSIS')
This script is designed to search the MTA logs for the entry of information on the processing of a letter specified by the MESSAGE-ID | ADDRESS parameters in the START / END time interval (any time or both options) by the MTA ID.
Called with arguments - [[START] / [END]] MESSAGE-ID | ADDRESS FILELOG
./mtalog [START]/[END] MESSAGE-ID|ADDRESS FILELOG
./mtalog 0426T/0427T101231 ya@ya.ru maillog.log
./mtalog /0824T ya@ya.ru maillog.log
./mtalog ya@ya.ru maillog.log
DESCRIPTIONThe script can track the processing of a specific letter within the MTA.
reportedly in the log file. Time interval is transferred to the script,
in which you need to search for messages, and, or message-id messages,
either the from or to address of the message. The script must determine
the unique ID of the first message assigned to it by the MTA and output ALL
records from the log file in a given time interval relating to
given id. In the case where the address is from or to the message, and
there are several messages with
specified addresses, you need to display entries from the log file, only for
first post.
The script can be called as:
mtalog [START]/[END] MESSAGE-ID|ADDRESS FILELOG
START and END - this is the appropriate start and end time, inside
which requires processing. The time is set in ISO
8601 restricted time format (see note 1).
MESSAGE-ID is the message ID.
ADDRESS is from or to email address
FILE.LOG - the name of the file in which we are searching
The sequence of enumeration of call arguments is any, time is optional, in this case the search is conducted from the beginning of the log until tomorrow night.