How can I suppress error messages sent to a console?

On: Ubuntu? Fedora? Debian? CentOS? RedHat?

2 Answers 2


Edit the configuration of your syslog daemon: /etc/rsyslog.conf, /etc/syslog-ng.conf or similar. Look for "console".

command 2>/dev/null

for all distributions and even other unixes.

  • Thank you, but I'm searching for kernel.printk like solutions, so that "logging/warnings" will not occur to console
    – peter567
    Apr 22, 2011 at 8:40
  • 1
    then you should edit your question to make that clear
    – Kim
    Apr 22, 2011 at 14:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .