Not output when syslog configured

We’ve configured Tyk to log to syslog, but see no traffic on the configured connection.

In tyk.conf
“use_syslog”: true,
“syslog_network_address”: “our_syslog_host:our_syslog_port”

Is there anything else that needs to be done?

You need to set the transport, currently only udp is supported:

"use_syslog": true,
"syslog_transport": "udp",
"syslog_network_addr:  "172.17.0.2:9999"

We’ve tried that also. No joy.

Note that the documentation says:

syslog_transport: The Syslog transport to use, should be “udp” or empty.

I assumed that “empty” would be the same as not supplied so the default must be “udp”. If that is not correct, the docs should be updated.

Could have mentioned that in the original post.

It can also be empty, the docs are correct, but it was worth a try.

We will need more info to diagnose:

  • Is syslog configured correctly?
  • Is the endpoint correct?
  • Is there any log output from the actual gateway stderr?

To clarify the empty string usage (and we should specify this in docs): If they are empty, then Tyk will write to a local syslog (/var/log/syslog), whatever the default is. So the empty test may have resulted in a side-effect, as instead of the hostname the file name location needs to be set.