Mattermost, Inc.

Mattermost logs cli command not working -- Ubuntu 18.04.3

Summary

When I am logged into my server running Mattermost and I attempt to run sudo -u mattermost ./bin/mattermost logs I get the following error message:

Error: open mattermost.log: no such file or directory

Steps to reproduce

Have followed the steps for installation from the latest version of the install docs. Here is my mattermost version:

Version: 5.15.0
Build Number: 5.15.1
Build Date: Fri Oct 11 20:40:13 UTC 2019
Build Hash: 4d802131407033b1e7dfdb003f8d2b28f66be711
Build Enterprise Ready: true
DB Version: 5.15.0

Expected behavior

I would assume the cli command would have the logic already-written for determining the location of the binary itself, and if the logs directory exists in the parent dir /opt/mattermost/

Observed behavior

l33th4x0r@<REDACTED>: /opt/mattermost $ sudo -u mattermost ./bin/mattermost logs
Error: open mattermost.log: no such file or directory
Usage:
  mattermost logs [flags]

Flags:
  -h, --help     help for logs
      --logrus   Use logrus for formatting.

Global Flags:
  -c, --config string        Configuration file to use. (default "config.json")
      --disableconfigwatch   When set config.json will not be loaded from disk when the file is changed.

I am now actually getting these errors in console when checking version:

{"level":"error","ts":1571113600.1656625,"caller":"app/plugin.go:141","msg":"Failed to start up plugins","error":"mkdir ./client/plugins: no such file or directory"}
{"level":"error","ts":1571113600.266776,"caller":"app/plugin.go:141","msg":"Failed to start up plugins","error":"mkdir ./client/plugins: no such file or directory"}
{"level":"error","ts":1571113600.3055904,"caller":"app/server.go:745","msg":"Elasticsearch.start: Elasticsearch is already stopped, "}
{"level":"error","ts":1571113600.3080678,"caller":"app/plugin.go:141","msg":"Failed to start up plugins","error":"mkdir ./client/plugins: no such file or directory"}