i have a machine(RHEL 5.2) which receives syslog message from remote machines. And now it keeps popping message from remote machine in a ssh shell, which is annoying when i want to do something on it.
messages are like this:
Message from syslogd@ at Thu Jul 17 18:05:45 2014 …
xxx.xxx.xxx.xxx (a number seems representing time): blahblah
i found this line in /etc/syslog.conf file:
kern.* /dev/console
the problem is that i don't want to disable it, i only want to disable this temporarily for my current ssh session
i have tried 'dmesg -n1' but it does not works
Best Answer
/dev/console is not your current session, it is the server console (the screen you see when attaching a monitor).
What you see in your terminal are the emergency messages. I am not sure if you can restrict these messages per terminal, but you can restrict them to be sent only to specific users. A quick Google search revealed this link to be useful and it shows how to do it.