Fortianalyzer: Device Registration and Communication
Fortianalyzer: Device Registration and Communication
FortiAnalyzer 6.4
© Copyright Fortinet Inc. All rights reserved.
Last Modified:
Wednesday, February 16, 2022
Lesson Overview
Registering Devices
Communication Troubleshooting
Disk Quota
4
Device Registration and ADOMs
• Each device can be registered with an administrative domain (ADOM)
• Devices can be registered only with their device-specific ADOMs
• For example: FortiMail device FortiMail ADOM type
• Administrator can register a device with the default ADOM for that device
• Administrator can register with a custom ADOM they create (the custom ADOM must still be associated
with the ADOM type for the specific device)
• Cannot add different device types to the same ADOM! Typical use case: multiple FortiGate
• By default, ADOMs aren’t enabled devices assigned to a custom ADOM
• FortiGate devices are automatically assigned to a root (FortiOS) ADOM
• Cannot add a non-FortiGate device without first enabling ADOMs
5
Method 1: Request from a Supported Device - I
1. FortiGate administrator enables Log & Report > Log Settings
remote logging to FortiAnalyzer
6
Method 1: Request from a Supported Device - II
1. FortiGate administrator enables Security Fabric > Fabric Connectors > Security Fabric Setup
Security Fabric and FortiAnalyzer
7
Method 2: Device Registration Wizard
1. Add a device using Device Manager
Device Manager
9
What Logs Are Collected?
10
Knowledge Check
11
Lesson Progress
Registration Methods
Communication Troubleshooting
Disk Quota
14
# get system status: Helpful Troubleshooting Data
16
# diagnose hardware info: Helpful Troubleshooting Data
17
Device and ADOM Status Check
• Use the following FortiAnalyzer CLI commands to check device and ADOM status
What devices or VDOMs are currently registered and # diagnose dvm device list
unregistered?
18
Troubleshooting Communication Issues
• Use the following CLI commands to troubleshoot communication issues
19
# diagnose debug application oftpd 8 <FortiGate_IP>
FortiAnalyzer # diagnose debug application oftpd 8 10.0.1.254 Local-FortiGate # diagnose log test
oftpd debug filter: ip==10.0.1.254 generating a system event message with level - warning
generating an infected virus message with level - warning
FortiAnalyzer # oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG generating a blocked virus message with level - warning
REQUEST' request type=23.
generating a URL block message with level - warning
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST'
request type=23. generating a DLP message with level - warning
generating an IPS log message
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST'
request type=23. generating an botnet log message
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST' generating an anomaly log message
request type=23. generating an application control IM message with level -
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST' information
request type=23. generating an IPv6 application control IM message with level -
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST' information
request type=23. generating deep application control logs with level -
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST' information
request type=23. generating an antispam message with level - notification
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST' generating an allowed traffic message with level - notice
request type=23.
generating a multicast traffic message with level - notice
oftpd_handle_session:3586: sock[24] ip[10.0.1.254] - Handle 'FGT RELIABLE LOG REQUEST'
generating a ipv6 traffic message with level - notice
request type=23.
generating a wanopt traffic log message with level -
notification
generating a HA event message with level - warning
generating a VOIP event message with level - information
generating authentication event messages
generating a Forticlient message with level - information
generating a URL block message with level - warning
generating a DNS message with level - warning
generating an ssh-command pass log with level - notification
generating an ssh-channel block with level - warning
generating an ssl-cert_blacklisted log with level - warning
20
FortiAnalyzer Temporarily Unavailable to FortiGate?
• The FortiGate miglogd process caches logs on FortiGate when FortiAnalyzer is not reachable
• When maximum cached value is reached, miglogd will drop cached logs (oldest first)
• When FortiAnalyzer connection is back, miglogd will send the cached logs
• FortiGate buffer will keep logs long enough to sustain a reboot of FortiAnalyzer, but not intended for lengthy outages
• FortiGate devices with an SSD have a configurable log buffer
FortiGate CLI Commands Current cache size and total cache
Local-FortiGate # diagnose test application miglogd 6 size
mem=0, disk=0, alert=0, alarm=0, sys=0, faz=171, faz-cloud=0, webt=0, fds=0
interface-missed=3726
Queues in all miglogds: cur:0 total-so-far:1023
global log dev statistics:
faz 0: sent=170, failed=0, cached=0, dropped=0 , relayed=0 If there are bursts or the link is
overloaded, failed increases
Local-FortiGate # diagnose log kernel-stats
fgtlog: 1
If the queue is full, failed-
fgtlog 0: total-log=2529, failed-log=0 log-in-queue=0
log value increases
21
Knowledge Check
1. Which CLI command can you use to find FortiAnalyzer's ADOM status?
A. # get system status
B. # show system performance
2. What can the CLI command # diagnose test application oftpd 3 help
you to determine?
A. What ADOMs are enabled and configured
B. What devices and IP addresses are connecting to FortiAnalyzer
22
Lesson Progress
Registration Methods
Communication Troubleshooting
Disk Quota
25
Disk Quota
• Disk quota includes:
• Raw logs
• Archive files
• SQL database tables
ADOM1
SQL
Local-FortiGate Remote-FortiGate
26
Understanding Disk Quota (example)
# diagnose log device 79.8GB (Total System Storage)
Total Quota Summary: - 15.0GB (Reserved Space)
Total Quota Allocated Available
Allocate% = 64.8 (Total Quota)
64.8GB 64.6GB 142.0MB 99.8%
64.6GB (Allocated) = Archive + Analytics Quota
System Storage Summary:
for all ADOMs
Total Used Available Use%
79.8GB 5.6GB 74.2GB 7.0 %
5.6GB (Used) = Logs + all system files on
Reserved space: 15.0GB (18.8% of total space) mounted drive (# diag system print df)
Archive Analytics
Adom name AdomOID Type Logs Database
[Retention Quota UsedSpace(logs / quarantine / content / IPS) Used%] [Retention Quota Used Used%]
ADOM1 147 FSF 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
ADOM2 162 FGT 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiAnalyzer 121 FAZ 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiAuthenticator 137 FAC 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiCache 125 FCH 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiCarrier 117 FGT 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiClient 127 FCT 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiDDoS 135 FDD 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiMail 119 FML 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiManager 131 FMG 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiNAC 141 FNA 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiProxy 139 FPX 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiSandbox 133 FSA 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
FortiWeb 123 FWB 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
Syslog 129 SYS 365days 300.0MB 0.0KB( 0.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 700.0MB 0.0KB 0.0%
root 3 FSF 365days 15.0GB 24.0KB( 24.0KB/ 0.0KB/ 0.0KB/ 0.0KB) 0.0% 60days 35.0GB 5.4MB 0.0%
Total usage: 16 ADOMs, logs=24.0KB database=930.3MB(ADOMs usage:5.4MB + Internal Usage:924.9MB) 27
Disk Quota on License Information Widget
• License Information widget shows values lower than disk quota
• Only reports on the number of logs pushed to FortiAnalyzer on that day
• Logs also limited to statistics gathered by fortilogd daemon (FortiGate/FortiAnalyzer real-time
forwarded logs)
• Doesn’t include log archive, FortiGate store and upload logs, FortiAnalyzer aggregated logs, or FortiClient
logs
• Doesn’t include SQL tables
28
Reserved Disk Quota
• The system reserves 5-20% disk space for system usage and unexpected quota
overflow
• Only 75-95% disk space is available for allocation to drives
29
Disk Quota Enforcement
• Processes used for disk quota enforcement:
• logfiled checks processes every two minutes (unless system resources are high) and
estimates space used by SQL database
• If estimated disk quota (raw + SQL) is above 95%, FortiAnalyzer removes the raw logs and the corresponding
logs in archives (with the SQL tables) up to 85%
System Settings > All ADOMs Log View > System Storage
31
Increasing Disk Space
• With FortiAnalyzer VMs, you can dynamically add more disk space:
# execute lvm info: provides a list of available disks
1. Stop the FortiAnalyzer VM and add a new disk to the VM
2. Reboot FortiAnalyzer and run execute lvm info to the added disk
3. Run execute lvm extend <disk number>
4. Reboot FortiAnalyzer (run get system status to see the new disk)
• With hardware FortiAnalyzer, you have to add another disk
• If you are using RAID, this requires you to rebuild your RAID array
• Be sure to account for future growth and size correctly from the outset!
32
Knowledge Check
1. By default, what happens when the allotted log disk space is full?
A. The oldest logs are overwritten
B. Logging stops
33
Lesson Progress
Registration Methods
Communication Troubleshooting
Disk Quota
36
Considerations Before Moving Devices
• What is the disk quota of the new ADOM? Ensure it has enough space for logs.
• Are the device’s analytics logs required for reports in the new ADOM? If so, rebuild
the new ADOM database:
# exe sql-local rebuild-adom <new-ADOM-name>
• Do you want to see the device’s analytics logs in the old ADOM? If not, rebuild the
old ADOM database (or they will be removed according to the data policy):
# exe sql-local rebuild-adom <old-ADOM-name>
• When you move a device, only the archive (compressed) logs are migrated to the
new ADOM. The analytics (indexed) logs stay in the old ADOM until you rebuild the
database.
37
High Availability Cluster
• FortiAnalyzer automatically discovers if a
FortiGate device is in a high availability
(HA) cluster
• If you register your device with FortiAnalyzer
before adding it to a cluster, you can manually
add the cluster within FortiAnalyzer
• With an HA cluster, each device generates
its own logs (separate serial number in
logs)
• Primary device responsible for sending all logs
from the other devices in the cluster to
FortiAnalyzer
• FortiAnalyzer distinguishes different
devices by their serial number (SN)
• SN in log headers Edit in Device Manager
38
Knowledge Check
1. When you move a FortiGate device from one ADOM to a new ADOM, what is the
purpose of rebuilding the new ADOM database?
A. To migrate the archived logs to the new ADOM
B. To run reports on the device's analytics logs in the new ADOM
39
Lesson Progress
Registration Methods
Communication Troubleshooting
Disk Quota