Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

as mentioned above, I want to to completely turn off the console output, but putting console= or console=null in the kernel command line doesn't change a thing. When I enque quiet to the kernel command line it approximates this job, but I want to completely turn off the output.

So why is console=null not working, there isn't even an error message?

share|improve this question
    
Do any of these work for you? superuser.com/questions/29666/silencing-linux-console-output –  slm Mar 3 at 14:11
    
unfortunately no –  user3085931 Mar 3 at 14:19
    
Related: unix.stackexchange.com/questions/17162/… –  slm Mar 3 at 14:37
    
how is this even possible, if this seems to be a working method on other systems but of mine ? –  user3085931 Mar 3 at 14:57

1 Answer 1

1. Using dmesg

One method would be to do so using dmesg:

   -n, --console-level level
          Set the level at which logging of messages is done to the console.  
          The level is a level number or abbreviation of the  level  name.
          For all supported levels see dmesg --help output.

For example:

$ sudo dmesg -n0

2. Using rsyslog

Another method would be through rsyslog. The config file /etc/rsyslog.conf:

#kern.*                                                 /dev/console

Changing this line to this:

kern.*                                                 /dev/null

NOTE: A restart of rsyslog is necessary, sudo service rsyslog restart.

3. Using sysctl

Lastly you can control this at the kernel level via sysctl.

I suggest you alter your /etc/sysctl.conf. Specifically, you want to tweak the kernel.printk line.

# Uncomment the following to stop low-level messages on console
kernel.printk = 3 4 1 3

You can see your current settings:

$ sudo sysctl -a|grep "kernel.printk\b"
kernel.printk = 4   4   1   7

4. Using silent

If you truly want to disable all logging, even during boot then change the string quiet to silent in the boot arguments to the kernel in GRUB, in /boot/grub2/grub.cfg.

linux   /vmlinuz-3.12.11-201.fc19.x86_64 ... rhgb silent ....
share|improve this answer
    
Thanks. Even when I put the log levels to 1 or 0 it doesn't lower the output. BTW I want to disable the output since startup, not only when the system is ready –  user3085931 Mar 3 at 14:20
    
the silent command didn't work either, I'll try the commenting of kernel.printk as you recommended tomorrow –  user3085931 Mar 3 at 14:53

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.