Sponsored Content
Top Forums Shell Programming and Scripting Redirect the output in a file and on screen Post 302524439 by jville on Monday 23rd of May 2011 10:21:52 AM
Old 05-23-2011
In shell script i would use tee command for this purpose. Sorry no PERL.... Smilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

redirect output to file?

Hi: I am currently working on a program which requires direct its ouput to a file here is an example ./proram arg_1 arg_2 when program ends all output will be arg_2 file Is that possible I am not a bad programmer, However I am stuck there. Can anyone give a hint? Thanks SW (1 Reply)
Discussion started by: slackware
1 Replies

2. UNIX for Dummies Questions & Answers

Redirect output to a file

Ahhhrrrggg I'm having a brain fart... I want to take the output of a command and redirect it to a file... This works.... $ man cp | cat >> copy_help but this doesn't keytool -help |cat >> keytool_help It just produces... these lines... more keytool_help ] ... ... (11 Replies)
Discussion started by: jimmyc
11 Replies

3. UNIX for Dummies Questions & Answers

redirect output to a file name

Hi all!! is possible to assign the output of some command to filename, i.e. grep_output.txt Otherwise, I want to open a new file which name is inside another, how can I do it? Thanks a lot! (7 Replies)
Discussion started by: csecnarf
7 Replies

4. Shell Programming and Scripting

How redirect standard output to a file

Hi guys, i have a script named purgeErrors.ksh, when i execute this script i need to redirect the output to a log file in the same directory, how can i do that ?? -- Aditya (5 Replies)
Discussion started by: chaditya
5 Replies

5. Shell Programming and Scripting

How to redirect output of ls to a file?

Hi All, I want to redirect only the file names to a new file from the ls -ltr directroy. how Can i do it. my ls -ltr output will be as below. -rwxr-xr-x 1 118 103 28295 Jul 26 2006 event.podl -rwxr-xr-x 1 118 103 28295 Jul 26 2006 xyz.podl I want my new file... (6 Replies)
Discussion started by: girish.raos
6 Replies

6. Shell Programming and Scripting

Redirect STDOUT & STDERR to file and then on screen

Dear all, redirecting STDOUT & STDERR to file is quite simple, I'm currently using: exec 1>>/tmp/tmp.log; exec 2>>/tmp/tmp.logBut during script execution I would like the output come back again to screen, how to do that? Thanks Lucas (4 Replies)
Discussion started by: Lord Spectre
4 Replies

7. Shell Programming and Scripting

script to mail monitoring output if required or redirect output to log file

Below script perfectly works, giving below mail output. BUT, I want to make the script mail only if there are any D-Defined/T-Transition/B-Broken State WPARs and also to copy the output generated during monitoring to a temporary log file, which gets cleaned up every week. Need suggestions. ... (4 Replies)
Discussion started by: aix_admin_007
4 Replies

8. Shell Programming and Scripting

Redirect script output to a file and mail the output

Hi Guys, I want to redirect the output of 3 scripts to a file and then mail the output of those three scripts. I used below but it is not working: OFILE=/home/home1/report1 echo "report1 details" > $OFILE =/home/home1/1.sh > $OFILE echo... (7 Replies)
Discussion started by: Vivekit82
7 Replies

9. Shell Programming and Scripting

Redirect STDOUT & STDERR to file and then on screen

Dear all, redirecting STDOUT & STDERR to file is quite simple, I'm currently using: Code: exec 1>>/tmp/tmp.log; exec 2>>/tmp/tmp.log But during script execution I would like the output come back again to screen, how to do that? Thanks Luc edit by bakunin: please use CODE-tags like the... (6 Replies)
Discussion started by: tmonk1
6 Replies

10. UNIX for Beginners Questions & Answers

Screen output to a file

Hi All, I am trying to out of shell script when i run it like sh /mypath/abc.sh ....a screen log should be generated whenever i input the values, when above the script prompt for values Regards Amarendra (3 Replies)
Discussion started by: amar1208
3 Replies
PERLUTS(1)						 Perl Programmers Reference Guide						PERLUTS(1)

NAME
perluts - Perl under UTS SYNOPSIS
This document can be read as is: as README.uts, or you can read it after you build your package using "man perluts". The purpose is to help you build Perl for UTS, which, if you follow these instructions, should be easy, and result in a solidly working installation. DESCRIPTION
Perl 5.7.2 (Developmental) or Perl 5.8.x (forthcoming) for UTS BUILDING PERL ON UTS
NOTE: Some sites have redefined the way uname works, and if yours does this, special steps must be taken so that Configure can recognize your system as a UTS system. To see if you are in this category, issue the command "uname -a". It should look something like: uts juno 4 4.4 9672 370 At any rate, the first field should be "uts". If this is not the case; supposing it is, say telcoUTS, create a script, uts/uname (i.e. uname, in the subdirectory "uts" of the main Perl source dir): # uname /usr/bin/uname "$@" | sed -e 's/^telcoUTS/uts/' and when you execute Configure, do it as below, except for adding PATH=uts:$PATH as a prefix. I.e. do: PATH=uts:$PATH ./Configure ... There is no need to do an interactive configure, just type ./Configure -de [-Dusedevel] [-Doptimize=-g ] 2>&1 | tee Conf.out "-Dusedevel" may be required to configure Perl 5.7.2 non-interactively. Use -Doptimize=-g if you want to run Perl under sdb or gdb, OR if you want to be able to use the -D command line flags to perl, which are occasionally useful in debugging perl scripts. In this and the following steps, the "2>&1 | tee XXX.out" records all output from the process, which will be useful if anything unexpected goes wrong. Then do the compilation with make 2>&1 | tee make.out Finally, test using make test 2>&1 | tee make-test.out In the output, the only failures you should see should look like: lib/Math/BigInt/t/bigfltpm.........Use of uninitialized value ... FAILED at test 57 lib/Math/BigInt/t/bigintc..........ok lib/Math/BigInt/t/bigintpm.........FAILED at test 204 lib/Math/BigInt/t/mbimbf...........Use of uninitialized value ... Illegal division by zero at ../lib/Math/BigInt/Calc.pm line 314. FAILED at test 71 lib/Math/Complex...................exp: OVERFLOW FAILED at test 250 lib/Math/Trig......................exp: OVERFLOW ok lib/Memoize/t/array................ok ... lib/Net/protoent...................ok lib/Net/servent....................FAILED at test 0 This means that everything passes except for some problems in the packages "Math::BigInt", "Math::Complex", and "Math::Trig". The lib/Net/servent failure seems to be a bug in the test program. To confirm this, from the main Perl source dir, do: LD_LIBRARY_PATH=`pwd` ./perl -Ilib lib/Net/servent.t and it should output 1..3 ok 1 ok 2 ok 3 Installing the built perl on UTS Run the command "make install" AUTHOR
Hal Morris UTS Global LLC email: hom00@utsglobal.com perl v5.12.1 2010-04-26 PERLUTS(1)
All times are GMT -4. The time now is 07:09 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy