Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Invoking Perl script from an email

by fsn (Friar)
on Aug 02, 2002 at 21:21 UTC ( #187223=note: print w/replies, xml ) Need Help??


in reply to Invoking Perl script from an email

In addition to what hacker wrote, I would just like to say that, at least with sendmail, scripts like this are run by smrsh which require the script, or at least a link, to reside in some special place. On my machine (RH72) it seems to be /etc/smrsh, and I think that is fairly standard. So in your aliasfile you should probably write:
udb: "|/etc/smrsh/file.pl"

You could also use the .forward file in the users home directory to do the same. The script still has to be in /etc/smrsh, but you don't have to mess with the aliases file. Read the vacation or procmail documentation.

I once did a simple, but neat, thing that measured roundtriptime and availability of our customers mailsystems. I mailed a message to the mailservers, which forwarded them back to me, and I piped it all into a perl script. Finally all data ended up on a webpage, with RTT high, low and mean, and dropped mails and so on. It also sent me an email *ahem* if a mail was lost somewhere.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://187223]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (2)
As of 2022-12-04 21:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?