On Wed, 7 Jan 2004, Lista MORCOM wrote: > Hi! > > I have small problem. > In my old configuration with sendmail I have had > ".procmail" > file which sends to me a SMS message about my > mail. It's looks > like: > > ------- > > :0 c > | /bin/sh /home/some_folders/sms_info > > ------- > > How to configure a MAILPROC.TAB to do the same > with my mail?
Get these two sources: http://www.xmailserver.org/econv.c http://www.xmailserver.org/swrap.c and build them: $ gcc -o econv econv.c $ gcc -o swrap swrap.c Than create a shell script like: ----------------------------------------------------------------- #!/bin/sh DIRNAME=`dirname $0` FILENAME=$1 PUID=503 PGID=503 shift $DIRNAME/econv --mbox --unix --input $FILENAME > $FILENAME.lst cat $FILENAME.lst | $DIRNAME/swrap $PUID $PGID /home/some_folders/sms_info rm -f $FILENAME* ----------------------------------------------------------------- The shell script and the two binaries should be inside the same directory (if you do not want to change the shell script). Then set up the mailproc.tab with a line like: "external" "0" "0" "path-to-shell-script" "@@TMPFILE" The PUID and PGID are UID and GID of the user that will be used to run the sms_info program. You have likely to change them. > The second problem: local delivery of mail's. > > My cron deamon sends to me some reports - directly > to root > account (local). But this mail was never received > by me. I have > received information, that xmail is nota able to > send this mail. > What is wrong? All permissions and chmod are OK > (checked twice!). You have to set up correctly /etc/crontab by setting the variable MAILTO to a full email address. You have also to configure correctly XMail's sendmail. - Davide - To unsubscribe from this list: send the line "unsubscribe xmail" in the body of a message to [EMAIL PROTECTED] For general help: send the line "help" in the body of a message to [EMAIL PROTECTED]
