I ran dolphin like this:
dolphin . &
I see messages in the console like these:
QPixmap::scaled: Pixmap is a null pixmap
How can I keep the console clean or silent?
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.
Sign up to join this communityYou can redirect the output to a file or to nowhere.
Using output redirection >
you can redirect stdout and/or stderr away from the terminal.
To redirect stdout and stderr to a file use &> log.txt
.
If you just want output to go way use &> /dev/null
.
So you new command would be dolphin . &> /dev/null &
&>
redirects all output
use >
or 1>
to redirect stdout only
use 2>
to redirect stderr only
Note: if you want to append to a file rather than overwrite it use >>
in place of >
.
&
should come at the end of the entire command. Your examples with &>
are incorrect. The OP's new commands should be dolphin . >/dev/null &
which would get rid of just standard output. To ignore both stdout and stderr, the proper command is in Oli's reply.
Jun 5, 2014 at 15:09
>
only redirects stdout, but Oli added an extra 2>&1 to send stderr to stdout, so both get redirected by the redirect of stdout. @InsomniacSoftware the &>
example is correct but I was wrong about &1>
I edited to correct
Redirect all the output into a black hole:
dolphin . > /dev/null 2>&1 &
The 2
, 1
and 0
(not used here) stand for STDERR (where all the error messages are sent), STDOUT
(where normal output goes) and STDIN (where the input) comes from. In a normal terminal STDOUT and STDERR are both printed to screen.
The above example redirects STDOUT
with >
to /dev/null
and then redirects STDERR
into STDOUT
so both output streams end up at /dev/null
.