Fortinet
FortiOS SNMP configuration follows the standard FortiOS CLI pattern - config/edit/set/next/end - under system snmp.
General settings
config system snmp sysinfo
set status enable
set description "Edge firewall"
set contact-info "admin@example.com"
set location "Rack 4, DC1"
end
SNMPv1/v2c (communities)
config system snmp community
edit 1
set name "public"
set query-v2c-status enable
set trap-v2c-status enable
config hosts
edit 1
set ip 192.168.1.100 255.255.255.255
next
end
next
end
Each community is its own numbered entry, with query and trap enabled/disabled independently per SNMP version - and a nested hosts table naming exactly which managers this community is valid for, rather than a single global allow-list.
SNMPv3
config system snmp user
edit "MYUSER"
set security-level auth-priv
set auth-proto sha
set auth-pwd MYAUTHPASS
set priv-proto aes
set priv-pwd MYPRIVPASS
set notify-hosts 192.168.1.100
set queries enable
set trap-status enable
next
end
Choosing which events send traps
Rather than a blanket "enable all traps" switch, FortiOS lets you pick specific event categories per community or per v3 user:
config system snmp community
edit 1
set events cpu-high mem-low ha-switch fan-failure power-supply-failure
next
end
The full event list is extensive - CPU/memory thresholds, HA state changes, IPS/AV signature updates, hardware sensor failures, and many more - set events ? at the CLI on the actual device shows the complete, version-specific list.
Model/platform differences
The CLI syntax above is consistent across FortiGate hardware models and VM instances - FortiOS's configuration model doesn't fork by platform the way some vendors' does. What varies by model is which hardware-sensor events are actually meaningful: a VM instance obviously has no fan or power-supply sensors to report on, so those event options exist in the config but have nothing to trigger them. FortiGate's own hardware sensor table (fgHwSensorTable) is likewise sparse or empty on virtual appliances.