How to redirect standard error to a file?

Answers were Sorted based on User's Feedback



How to redirect standard error to a file?..

Answer / linuxdemon

2> filename

eg: dat 2> errfilename

Is This Answer Correct ?    12 Yes 1 No

How to redirect standard error to a file?..

Answer / kirus

cat 2 > filemane

if the filename is error.txt

cat 2 > error.txt
the statndard error is redirrected to error.txt file

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More Unix Commands Interview Questions

distinguish between multi-tasking,multi-user,multi- processing and time sharing?

4 Answers   Infosys, Nikhil Construction,


If JFS file system is 100% full how we can increase the file system ?

3 Answers  


Write a command to display a file’s contents in various formats?

0 Answers  


What is the difference between awk and grep?

0 Answers  


what does the job command do?

4 Answers  


what is the command to list files in a directory in UNIX?

8 Answers  


what is the meaning of this command rm -rf / what will it do ?

5 Answers   Altair,


What is awk used for?

0 Answers  


distinguish between interrupts and exceptions?

2 Answers   Infosys, Wipro,


how will u execute a file in unix

8 Answers   QA,


When the shell is reading the command line what is the difference between text enclosed between double quotes ( ” ) and text enclosed between signal quotes ( ’ )?

3 Answers  


Differentiate cat command from more command.

0 Answers  


Categories