What do the following commands characters do? - ProProfs Discuss
Advertisement

What do the following commands characters do?

# cmd > file.out 2>&1

Asked by Berry, Last updated: Apr 18, 2024

+ Answer
Request
Question menu
Vote up Vote down

1 Answer

John Smith

John Smith

John Smith
John Smith

Answered Sep 08, 2016

Sends the stdout and stderr of cmd to file.out-common redirection operators command >file : redirects standard output of command into the file command>>file : append the standard output of command into the file commandfile : redirects the standard error into the file and pipe (|) is used to combine the command, in piping outout of first command goes as input to the second command. when we executes the command it generates the standard output as well as standard error and displays in standard output (terminal window) is default. when we redirect the standard error as well as standard output into the file, it will not send any output into the terminal window.
upvote downvote
Reply 

Advertisement
Advertisement
Search for Google images Google Image Icon
Select a recommended image
Upload from your computer Loader
Image Preview
Search for Google images Google Image Icon
Select a recommended image
Upload from your computer Loader
Image Preview
Search for Google images Google Image Icon
Select a recommended image
Upload from your computer Loader

Email Sent
We have sent an email to your address "" with instructions to reset your password.