Thursday, May 23, 2019

Systemd disable STD I/O from service


sudo systemctl edit service@.service

[Service]
StandardOutput=null
StandardError=null

or

sudo systemctl edit service.service

[Service]
StandardOutput=null 
StandardError=null

Clear journalctl

sudo journalctl --rotate
sudo journalctl --vacuum-time=1s

or

sudo journalctl --rotate
sudo journalctl --vacuum-size=50M