## Assemble your od command up here#my($output) = "";open(PIPE, "$od_cmd 2>&1 |");while(<PIPE>){ $output .= $_;}close(PIPE);
Try something like this: ## Assemble your od command up here#my($output) = "";open(PIPE, "$od_cmd 2>&1 |");while(<PIPE>){ $output .= $_;}close(PIPE); What you do with the contents of '$output' is up to you. . .throw it away or log it, as the business case demands.
I have the following scenario (Teamsite 671 on Win2k3)User triggered Workflow ---> Perl Script ---> external command to invoke Opendeploy. In the perl script, If I use system($cmd); It doesnot work... (atleast the OD logs dont record any activity)If I use qx($cmd 2>&1); nothing.... Butif I have a log file open with the file handle LOGFILE and I do the following.. it works.print LOGFILE qx($cmd 2>&1); How can I make it work without having to worry about a huge log file building up on the server? More importantly why would the last command work?abhijeet
Out of curiosity - what is the actual value of $cmd?