Description | The article describes the case when Syslog Server is connected to FortiGate via IPSec VPN Tunnel and stops sending logs periodically. |
Scope | FortiGate and Syslog. |
Solution |
As a workaround, disabling and enabling the Syslog Server fixes the issue however, this is not the feasible method.
Check if the traffic to the Syslog Server IP is leaving via the WAN interface instead of the IPSec tunnel:
diagnose sniffer packet any "host <Syslog Server IP>" 4 0 l
If yes, clear the existing session: diagnose sys session filter list diagnose sys session filter src <Fortigate_source_IP> diagnose sys session filter dst <Syslog_Server_IP> diagnose sys session filter list diagnose sys session clear
Reason for this Issue: When a FortiGate has an active route for a private subnet (RFC 1918), the traffic will be forwarded via that interface. When that interface (IPSec/LAN) goes down, the route will be removed from the routing-table and the traffic will be sent out via the default route.
Example:
Syslog config:
config log syslogd setting
In this example, the traffic is leaving out via wan1 instead of VPN:
FGT# diagnose sniffer packet any 'host 10.190.5.1' 4 0 l
It is possible to use the syslog server port number as well to sniff the traffic. In this example, port 514 was used:
FGT# diagnose sniffer packet any 'port 514' 4 0 l
Clearing the existing session:
diagnose sys session filter src 192.168.210.1 diagnose sys session filter dst 10.190.5.1 diagnose sys session clear
After clearing the session:
FGT# diagnose sniffer packet any 'host 10.190.5.1' 4 0 l 0.118188 VPN1 out 192.168.210.1.8778 -> 10.190.5.1.514: udp 934
To fix this effectively, do the following:
Note: The same behavior is observed even when multiple syslog servers are configured on the FortiGate if the route to all of the syslog servers uses the same IPsec tunnel.
Related articles: Technical Tip: Prevent RFC 1918 (LAN subnets) network traffic from exiting the WAN interface Technical Tip: Syslog server over IPSEC VPN and sending VPN logs |
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2025 Fortinet, Inc. All Rights Reserved.