All,
I’m trying to find a way to have sensu-go (specifically the sensu agent) to log to it’s own file and not log to syslog.
Has anyone been able to do something like this?
- Mike D.
All,
I’m trying to find a way to have sensu-go (specifically the sensu agent) to log to it’s own file and not log to syslog.
Has anyone been able to do something like this?
Hey,
what host OS are you running sensu-agent on?
If you are using something like Centos 6 as the host OS, you should already be using a sysvinit script that is configured to create logs in /var/log/sensu/
If you are running a systemd based linux distro (ex: CentOS 7), you can extend the systemd service definition and instruct systemd to redirect stdout and stderr into a log file of your cholce.
Here’s a recent discourse post that details how to reconfigure your systemd to redirect stdout/stderr to a log file: SensuGO Agent and Backend Logging