07-16-2013
cant u redirect the output of that script to log file?
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
If I wanted to redirect output to multiple log files, what would be the best way to do that?
echo "Unix is awesome" >>unixgod.log >>unixgod.log (3 Replies)
Discussion started by: darthur
3 Replies
2. Shell Programming and Scripting
Hi,
I am trying to do the following using AWK program.
1. Read the input data file
2. Parse the record and see if it contains errors
3. If the record contains errors, then write it into Reject file, else, write into usual output file or display it on the screen
Here is what I have done -... (6 Replies)
Discussion started by: vidyak
6 Replies
3. Shell Programming and Scripting
Hi
I have developed bash script to connect to database and execute .sql files. I am logging some statements in to log file using echo. While logging I am adding the date in front of the log statements which makes sense. I am unable to add date in front of output from the sqlplus and sqlldr,... (8 Replies)
Discussion started by: murtymvvs
8 Replies
4. Shell Programming and Scripting
Hi All,
I am completely stuck here.
I have a set of files (with names A.txt, B.txt until L.txt) which contain words like these:
computer
random access memory
computer networking
mouse
terminal
windows
All the files from A.txt to L.txt have the same format i.e. complete words in... (2 Replies)
Discussion started by: shoaibjameel123
2 Replies
5. UNIX for Dummies Questions & Answers
I have a script where the the 9th line looks like this:
$filename=sprintf("250.1chr%d.ped", $N);
I want to modify this script 1000 times, changing 250.1chr%d.ped to 250.2chr%d.ped, 250.3chr%.ped.......and so on all the way to 250.1000chr%d.ped and store each output in files called
... (4 Replies)
Discussion started by: evelibertine
4 Replies
6. Shell Programming and Scripting
Hi,
I am looking for a shell script which serves the below purpose.
Please find below the algorithm for the same and any help on this would be highly appreciated.
1)set of strings need to be replaced among set of files(directory may contain different types of files)
2)It should search for... (10 Replies)
Discussion started by: Amulya
10 Replies
7. UNIX for Dummies Questions & Answers
Hi Guys,
I like to output every command executed in the script to a file.
I have tried set -x which does the same.
But it is not giving the logs of the child script which is being called from my script.
Is there any parameters in the Set command or someother way where i can see the log... (2 Replies)
Discussion started by: mac4rfree
2 Replies
8. Shell Programming and Scripting
In the attached bash in the convert function the out_position.txt in not being writing to the annovar directory and I can not figure out why. Thank you :). (2 Replies)
Discussion started by: cmccabe
2 Replies
9. Shell Programming and Scripting
Redirecting log files to null writing junk into log files.
i have log files which created from below command
exec <processname> >$logfile
but when it reaches some size i am redirecting to null while process is running like
>$logfile
manually but after that it writes some junk into... (7 Replies)
Discussion started by: greenworld123
7 Replies
script(1) General Commands Manual script(1)
NAME
script - make typescript of terminal session
SYNOPSIS
[file]
DESCRIPTION
makes a typescript of everything printed on your terminal. It starts a shell named by the environment variable, or by default and silently
records a copy of output to your terminal from that shell or its descendents, using a pseudo-terminal device (see pty(7)).
All output is written to file, or appended to file if the option is given. If no file name is given, the output is saved in a file named
The recording can be sent to a line printer later with lp(1), or reviewed safely with the option of cat(1).
The recording ends when the forked shell exits (or the user ends the session by typing "exit") or the shell and all its descendents close
the pseudo-terminal device.
This program is useful when operating a CRT display and a hard-copy record of the dialog is desired. It can also be used for a simple form
of session auditing.
respects the convention for login shells as described in su(1), sh(1), and ksh(1). Thus, if it is invoked with a command name beginning
with a hyphen (that is, passes a basename to the shell that is also preceded by a hyphen.
The input flow control can be enabled by setting environmental variable before running Please see section for details on using this envi-
ronment variable.
EXAMPLES
Save everything printed on the user's screen into file
Append a copy of everything printed to the user's screen to file
WARNINGS
A command such as which displays the contents of the destination file, should not be issued while executing because it would cause to log
the output of the command to itself until all available disk space is filled. Other commands, such as more(1), can cause the same problem
but to a lesser degree.
records all received output in the file, including typing errors, backspaces, and cursor motions. Note that it does not record typed char-
acters; only echoed characters. Thus passwords are not recorded in the file. Responses other than simple echoes (such as output from
screen-oriented editors and command editing) are recorded as they appeared in the original session.
When there is no input flow control is not set), there can be some data loss while using However, script(1) can behave unexpectedly, if is
set and is not set.
AUTHOR
was developed by the University of California, Berkeley and HP.
script(1)