Filebeat systemd not writing logs to log directory

I have filebeat 7.12 and have the below systemd service

[Unit]
Description=Filebeat sends log files to Logstash or directly to Elasticsearch.
Documentation=https://www.elastic.co/products/beats/filebeat
Wants=network-online.target
After=network-online.target
[Service]
Environment="BEAT_LOG_OPTS="
Environment="BEAT_CONFIG_OPTS=-c /share/filebeat/filebeat.yml"
Environment="BEAT_PATH_OPTS=--path.home /share/filebeat --path.config 
/share/filebeat --path.data /share/filebeat/data --path.logs /share/filebeat/logs"
ExecStart=/share/filebeat/filebeat --environment systemd $BEAT_LOG_OPTS 
$BEAT_CONFIG_OPTS $BEAT_PATH_OPTS
Restart=always
User=filebeat
Group=filebeat
[Install] 
WantedBy=multi-user.target

I was hoping to get the log files under /share/filebeat/logs but they are going to /var/log/messages on my linux server.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.