---
schema_version: "1"
id: 30c41520dc8c7a9413732ae6fc5fd1a4df95badaa3eabef9f8c96e9c355d40cb
title: Troubleshooting Self-Managed Gateway Logging Issues
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/gateway/1.12/flex-troubleshoot-logging.md
canonical_url: https://docs.mulesoft.com/gateway/1.12/flex-troubleshoot-logging
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 197030daf652d02a65037255dac7731082e21ccc6ebc4efb40ced50c73f7fb2f
description: MuleSoft Documentation Site
release: "1.12"
latest: false
---
---
product: Omni Gateway
version: 1.12
---

# Troubleshooting Self-Managed Gateway Logging Issues

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

When configuring logging for Anypoint Flex Gateway, you might encounter logging issues caused by
incorrect directory permissions, and so on. The following topics provide possible causes for logging
issues and describe how to troubleshoot:

- [Logs Do Not Appear in a Third-Party Logging Service](#third-party-service)

- [Logs Do Not Appear when Running in a VM](#incorrect-permissions)

## Logs Do Not Appear in a Third-Party Logging Service

After applying a logging configuration YAML file, logs should begin appearing within a few minutes.
If your logs do not appear in your third party logging service:

1.  Ensure that your third-party service is running.

2.  If the service is running, check the runtime logs for potential configuration errors.

    You can view the runtime logs for both Flex Gateways running in Connected Mode and Local Mode by
    following the steps in [Viewing Standard Output Logs](https://docs.mulesoft.com/gateway/1.12/flex-local-view-logs). Additionally, for
    Flex Gateways running in Connected Mode, you can
    [view runtime logs in Runtime Manager](https://docs.mulesoft.com/gateway/1.12/flex-view-logs-in-runtime-manager).

    Potential configuration errors appear similar to the following:

    \[flex-gateway-fluent\] \[2023/09/07 20:17:49\] \[error\] \[output:http:http.1\]
    hzk83039.live.dynatrace.com:443, HTTP status=401 \[flex-gateway-fluent\]
    {"error":{"code":401,"message":"Missing authorization parameter."}} \[flex-gateway-fluent\]
    \[2023/09/07 20:17:49\] \[ warn\] \[engine\] failed to flush chunk
    '20-1694117863.683606251.flb', retry in 7 seconds: task\_id=2,
    input=emitter\_for\_rewrite\_tag.11 > output=http.1 (out\_id=1)

3.  Whether or not configuration errors appear in the runtime logs, view the
    /var/tmp/mulesoft/flex-gateway/fluent-bit.conf file to ensure your configuration values are
    correct.

## Logs Do Not Appear when Running in a VM

Log files do not appear after specifying a target log directory in an access log policy. An example
log directory might be `/var/log`.

### Cause

Your log output directory might not have `write` permission.

### Solution

To resolve this issue, grant `write` permission to the output directory.

## See Also

- [Known Issues](https://help.salesforce.com/s/issues)
