I would like to change the PMM agent default log to custom log like below. But its not working and I followed the PMM documentation.
[root@rndsan404 maxctrl_exporter]# cat /usr/lib/systemd/system/pmm-agent.service
[Unit]
Description=pmm-agent
After=time-sync.target network.target
[Service]
Type=simple
ExecStart=/usr/sbin/pmm-agent --config-file=/usr/local/percona/pmm2/config/pmm-agent.yaml StandardError=file:/var/log/pmm-agent.log
Restart=always
RestartSec=2s
StandardError=file:/var/log/pmm-agent.log
[Install]
WantedBy=multi-user.target
[root@rndsan404 maxctrl_exporter]#