Relative path to save filebeat logs

In filebeat config file, there is a section regarding logging to files, namely:

logging.to_files: true
logging.files:
  # Configure the path where the logs are written. The default is the logs directory
  # under the home path (the binary location).
  path: /var/log/filebeat

  # The name of the files where the logs are written to.
  name: osb-callback

  # Configure log file size limit. If limit is reached, log file will be
  # automatically rotated
  rotateeverybytes: 10485760 # = 10MB

  # Number of rotated log files to keep. Oldest files will be deleted first.
  keepfiles: 5

Is there anyway i am able to specify relative paths instead? Also, will the directory be created if it does not exist?

Relative paths should work, but I would have to check if it is relative to where you executed the binary or relative the binary itself. If the filebeat directory does not exist, it will created it in case the rights exist to do it.

Can you share the benefit of using relative paths?

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