I want to read all input to the command from file1 direct all output to file2 and error to file 3, how can I achieve this?

Answer Posted / shubham shivaji kale

You can use the following command:

# cat file1 > file2 2> file3

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What does $0 mean in shell script?

765


What is eval in shell script?

909


How to redirect both standard output and standard error to the same location?

917


What is shell application?

755


I have to write Shells (Linux + Unix)for publishing packages and reports. Is it possible ? What are the differents executable programs ineed to call ?

1894


How to pass an argument to a script?

794


How do I start a shell script?

808


Given a file find the count of lines containing the word "abc".

1281


What is the use of .sh file?

825


What is awk in shell scripting?

804


What are "c" and "b" permission fields of a file?

777


Explain about stdin, stdout and stderr?

833


What are the default permissions of a file when it is created?

709


What does path stand for?

834


Explain about debugging?

818