Ano-Tech Computers
Enter keyword:

How to start a completely quiet background process using bash
Problem:
This article describes how to execute unix processes in the background using the default linux shell: /bin/bash
 
Solution:
"command"
Will start that command in the foreground. All output (standard/output) will be shown.

"command &"
Will start that command in the background. All output (standard/output) will be shown.

"command >/dev/null &"
Will start that command in the background. Only error messages will be shown.

"command 2&>/dev/null &"
Will start that command in the background. No output will be shown.

"command >myoutput 2>myerrors &"
Will start that command in the background. Standard output will be placed in a file "myoutput" and errors in a file "myerrors".
 
Discuss this solution
Did this article solve your problem? Yes No Did not apply

We welcome anyone who is willing to contribute to this public knowledge base, contact siteadmin@atc.no if you have information you would like to share. The idea is not to replace the commercial support sites, but to publish those hard-to-find solutions you've found yourself looking for over and over again.

Show all articles