Your right. This might not be a problem with path to email2sms.pl. But
it's definitely a problem with email2sms.pl. I got caught up with
the "command not found" and didn't see it was actually refering to
the "use" statement.

It sounds more like procmail is using /bin/sh to execute the
email2sms.pl instead of perl.

Try changing it to:

perl /full/path/to/email2sms.pl

instead of just:

./email2sms.pl

And make sure the version of perl you specify is really version 5.
Your system might have 2 version of perl (v4 and v5) and procmail
might be using the wrong version of perl to execute the email2sms.pl.

See ya...

d.c.

**>Subject: RE: Mail2SMS with Kannel
**>Date: Sun, 3 Dec 2006 11:55:08 +0400
**>In-Reply-To: <[EMAIL PROTECTED]>
**>From: "Divyesh Amipara" <[EMAIL PROTECTED]>
**>To: "Davy Chan" <[EMAIL PROTECTED]>
**>Cc: "David E. Meier" <[EMAIL PROTECTED]>, <users@kannel.org>
**>
**>Hi,
**>
**>I know it is not a Kannel problem but there are some users who use the
**>similar setup (Mail2SMS).
**>
**>Let me tell you. It is not the problem with PATH. 
**>
**>Thanks for suggestion to buy a book on UNIX.
**>
**>>> Divyesh A.
**>
**>-----Original Message-----
**>From: Davy Chan [mailto:[EMAIL PROTECTED] 
**>Sent: Sunday, December 03, 2006 11:41 AM
**>To: Divyesh Amipara
**>Cc: David E. Meier; users@kannel.org
**>Subject: Re: Mail2SMS with Kannel
**>
**>**>Subject: RE: Mail2SMS with Kannel
**>**>Date: Sun, 3 Dec 2006 09:09:12 +0400
**>**>In-Reply-To: <[EMAIL PROTECTED]>
**>**>Priority: Urgent
**>**>Importance: high
**>**>From: "Divyesh Amipara" <[EMAIL PROTECTED]>
**>**>To: "David E. Meier" <[EMAIL PROTECTED]>, <users@kannel.org>
**>**>
**>**>Hi,
**>**>
**>**>I am facing problem with procmail, it seems procmail is not working
**>properly. Below is my config and logs...
**>**>
**>**>I just want mailto be handled by email2sms.pl. strange thing is when
**>I run...
**>**>
**>**>./email2sms.pl < /home/admin/Maildir/new/mail1111 (it works fine but
**>not with procmail)
**>**>
**>**>1) .procmailrc
**>**>
**>**>:0
**>**>| ./email2sms.pl
**>**>
**>**>2) /etc/postfix/main.cf 
**>**>
**>**>home_mailbox = Maildir/
**>**>mailbox_command = /usr/bin/procmail
**>**>virtual_alias_maps = hash:/etc/postfix/virtual
**>**>
**>**>3) /etc/postfix/virtual
**>**>
**>**>@test.com         [EMAIL PROTECTED]
**>**>
**>**>4) /var/log/maillog
**>**>
**>**>Dec  2 22:01:10 tecexperts postfix/local[6410]: 1A4981F3EB1:
**>to=<[EMAIL PROTECTED]>, orig_to=<[EMAIL PROTECTED]>, relay=local,
**>delay=3832, status=SOFTBOUNCE (can't create user output file. Command
**>output: procmail: Couldn't create "/var/mail/admin" ./email2sms.pl: line
**>3: use: command not found ./email2sms.pl: line 4: use: command not found
**>./email2sms.pl: line 5: use: command not found ./email2sms.pl: line 7:
**>use: command not found ./email2sms.pl: line 8: use: command not found
**>./email2sms.pl: line 9: syntax error near unexpected token `('
**>./email2sms.pl: line 9: `use POSIX qw(strftime);' procmail: Program
**>failure (2) of "./email2sms.pl" )

Reply via email to