[Omaha.pm] perl or system problem?

Terry td3201 at gmail.com
Thu Oct 21 09:14:23 CDT 2004


Hello,

I have a hunch this is something to do with my environment .....

I am running this program out of cron:

#!/usr/local/bin/perl

use Mail::Sendmail;

$hostname = `hostname`;
$message = `pprosvc -n -l`;
unshift @{$Mail::Sendmail::mailcfg{'smtp'}} , 'plasmtp';
%mail = ( To      => 'jo at hotmail.com',
        From    => "admin\@$hostname",
        Subject => 'available packages',
        Message => "$message"
);
sendmail(%mail) or die $Mail::Sendmail::error;


When I run it interactively on the command line, it works fine.  It
gives me a full output ($message).   When I run it out of cron,
$message is empty......why?   OS Is obviously Solaris.

Here is usage for that program:

usage: pprosvc [-d | -i [-n] | -l] [-h] where:
   d means download all patches.
   i means install required patches.
   l means list required patches.
   n means operate in non interactive mode.
   h display usage information.


Thanks!
Terry


More information about the Omaha-pm mailing list