How to stop syslog message in console ?

Kan

Well-Known Member
Dec 21, 2016
84
4
48
54
I regulary have some errors in host console (about 10 a day)

[1679843.646789] [Hardware Error]: CPU:0 (10:8:1) MC4_STATUS[-|CE|MiscV|-|AddrV|CECC]: 0x9c5a400014080813
[1679843.651169] [Hardware Error]: MC4 Error (node 0): DRAM ECC error detected on the NB.


These errors appear in containers consoles too.

How can I make it 'silent' in containers console but keep them in host console (proxmox 4.4) ?
 
Besides the correct suggestion from @dietmar, ..

In general, you have to reconfigure your logging system (e.g. rsyslog) to not include kernel messages. I don't know if this is a emerg target or not and it needs some tinkering, but it should work to disable the kernel messages or better discard the messages in your container logging system.
 
This error is not critical because of ECC. And hard to identify the bad RAM module.

I tried to change kernel messaging using this command, but it returns an error.

[root@vm ~]# sysctl -w kernel.printk="4 4 3 7"
error: "Read-only file system" setting key "kernel.printk"


Any suggestion ?
 
Besides the correct suggestion from @dietmar, ..

In general, you have to reconfigure your logging system (e.g. rsyslog) to not include kernel messages. I don't know if this is a emerg target or not and it needs some tinkering, but it should work to disable the kernel messages or better discard the messages in your container logging system.

How can I disable kernel messages in container ?
 
By reconfiguring your logging service. Please refer to the container operating system manual for that. This is not a PVE subject.

That's what I did (maybe wrong). I use the sysctl command in container but it returns a "read-only FS" error (see my command in blue). That's why I suppose this is a pve subject. The container is working well except that message in console.
 
sysctl is not the logging system, but the kernel tweak setting. In LXC, there is only one kernel, the one from the host, so you cannot tweak stuff there. Depending on your guest/container OS, the logging service is e.g. syslog, rsyslog. syslog-ng, $whatever they use.

There is a ongoing discussion about that here: https://github.com/lxc/lxd/issues/1397
They set this:

echo 1 | sudo tee /proc/sys/kernel/dmesg_restrict
 
Thx but I've got the same error with this command : read-only file system

I'll try kernel.dmesg_restrict = 1 in /etc/sysctl.conf now.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!