I just ran into this exact same problem myself--piping an alias to a perl
script through a version of sendmail running smrsh.  Assuming that you're
absolutely sure that the script really is being called, you might want to
check that smrsh has permission to write to that directory/file.  It's not
good enough that the script has permission if run from the command line,
smrsh has to see the directory (or at least the file that you want to
write to) as a valid path too.  At least that's what solved the problem
for me.  My solution was just to put a symbolic link to the file I was
trying to write in /etc/smrsh (or wherever your smrsh directory is).

HTH

-dave

On Tue, 14 Aug 2001 09:04:04 -0400, Robert Aspinall  wrote:
>The aliases entry is
>
>ca: "|caprocess.pl" (since smrsh calls it and ignores the path anyway)
>
>The script has nothing of any substance in it, just something like
>
>#!/usr/bin/perl
>open (OUTPUT, ">output.txt");
>print OUTPUT "testing!";
>print "testing!";
>print STDERR "testing!";
>
>
>Any ideas?
>
>
>Robert Aspinall
>Support Engineer
>V-ONE Corporation
>[EMAIL PROTECTED]
>
>----- Original Message -----
>From: "Gary Stainburn" <[EMAIL PROTECTED]>
>To: "Robert Aspinall" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
>Sent: Tuesday, August 14, 2001 8:54 AM
>Subject: Re: Sendmail w/perl
>
>
>> Hows about giving us some code to look at?
>> If it's a big un, just give us some snippets.
>> Also, give us the aliases file entry that calls it.
>>
>> Gary
>>
>> On Tuesday 14 August 2001  1:51 pm, Robert Aspinall wrote:
>> > I have an alias that runs a perl script whenever mail is recieved for
>>a
>> > certain account, but as far as I can tell, the perl script runs
>>without
>> > doing a single thing.  Is there a way to see the output of the
script?
>I
>> > have it write "hello" to a text file (which never gets created),
print
>> > hello to STDOUT, and even print hello to STDERR, and I don't see the
>> > slightest peep from it.
>> >
>> > Any suggestions?
>> >
>> > Robert Aspinall
>> > Support Engineer
>> > V-ONE Corporation
>> > [EMAIL PROTECTED]
>>
>> --
>> Gary Stainburn
>>
>> This email does not contain private or confidential material as it
>> may be snooped on by interested government parties for unknown
>> and undisclosed purposes - Regulation of Investigatory Powers Act, 2000
>>
>> --
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>--
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to