FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
yderek
Staff
Staff
Article Id 307206
Description This article describes when the HA Cluster has HA-Direct enabled and FortiGate acts as an NTP server for the Internal host, and how allows NTP traffic to communicate with the FortiGuard NTP server properly. 
Scope FortiGate.
Solution

When FortiGate is set in Active-Passive Cluster and has configured with management Interface Reservation, NTP traffic will initiate from the Management interface, this behavior has been described in this document: Out-of-band management with reserved management interfaces

 

This will override the source-ip setting hence even if explicitly set source IP is under the NTP setting, FortiGate will not use the source IP to communicate with the NTP server. 

The following example describes when HA direct NOT enabled and enabled traffic flow.

 

Case 1:  HA Direct is not enabled.

 

Settings for an HA cluster.

 

yderek_2-1711672598467.png

 

yderek_3-1711672598470.png

 

The NTP status on the FortiGate site, the output of the command 'diagnose system ntp status' shows HA synchronization: yes.

 

yderek_4-1711672598473.png

 

Port1 is my WAN port.

 

yderek_5-1711672598475.png

 

Windows Server as an NTP client before does not have NTP synced. See below, time is not synced to align the FortiGate.

 

yderek_6-1711672598500.png

 

Here is the FortiGate setting for NTP, port 4 will act as the NTP server from a Windows perspective.

 

yderek_7-1711672598501.png

 

Date and time on FortiGate.

 

yderek_8-1711672598502.png

 

Once the full NTP command is installed on Windows, it gets synced:

 

yderek_9-1711672598511.png

 

Windows is sending the traffic toward FortiGate port4 and can get time synced (10.68.1.45 is the Windows server).

 

yderek_10-1711672598513.png

 

Case 2: Enable HA Direct under the HA setting, this is only can be done in the command line.

 

yderek_11-1711672598514.png

 

That will give the warning that the source IP may not work.

Once HA-direct is enabled, FortiGate NTP out of sync based on the output below: synchronized: no.

 

yderek_12-1711672598517.png

 

The way to make it work will be to use the HA management Interface Gateway.

 

yderek_13-1711672598518.png

 

The gateway here will be the next hop to let MGMT traffic communicate with the FortiGuard NTP server. 10.68.1.60 is the MGMT port in this FortiGate.

There is 10.68.1.92 from another FortiGate interface port3 (subject to change depending on network setup however ensure the Gateway IP address has been set here will stay at the same subnet of 10.68.1.60 which is PORT4 MGMT interface).

The reason for gateway is required because once the Management Interface reservation has been configured under the HA cluster, the routing table will be moved from global, see below the generic routing table on FortiGate Cluster.

 

yderek_14-1711672598520.png

 

Port4 which is the Management Interface IP address is not showing under the generic routing table. This behavior is described here: Reference link for hidden vdom 

 

To verify the management routing table we need to enter the hidden VDOM below:

 

execute enter vsys_hamgmt

get router  info routing-table all <----- This will show the routing table for the management interface hence it is necessary to have the gateway stay at the same subnet with the management interface here to route out the NTP traffic.

 

yderek_15-1711672598521.png

 

Gateway 10.68.1.92 needs to be able to reach the Internet or FortiGuard NTP server.

 

yderek_16-1711672598524.png

 

NTP traffic will be HA Fortigate cluster  -----> MGMT interface (port 4) ----> port 3 another Fortigate -----> Internet/Fortiguard NTP server

 

Once the above change has been processed, the NTP can sync:

 

yderek_17-1711672598527.png

 

Setting the source IP for NTP might not work, only the packet coming is visible into this interface but not routing anymore.

 

yderek_18-1711672598529.png
Contributors