Skip to main content
WinterSnowYap
Staff
Staff
February 24, 2026

Technical Tip: How to update normalized interface information via a script

  • February 24, 2026
  • 0 replies
  • 272 views
Description This article describes how to update normalized interface information via a script.
Scope FortiManager.
Solution

Consider the following example scenario:

 

Currently, FortiManager has 2 normalized interfaces:

  • kentest_LAN.
  • kentest_WAN.

 

202602_FMG_Script_UpdateNormalizeInterface_001.png

 

In FortiManager, run CLI commands to view the CLI configuration:

 

execute fmpolicy print-adom-object <ADOM ID> <Category ID> <Dynamic Interface name>

 

  • ADOM ID = 181, ADOM_74
  • Category ID = 800, 'dynamic interface'
  • Dynamic Interface name = kentest_LAN & kentest_WAN


execute fmpolicy print-adom-object 181 800 kentest_LAN
execute fmpolicy print-adom-object 181 800 kentest_WAN

 

Example result below:

 

202602_FMG_Script_UpdateNormalizeInterface_002.png

 

After copying the CLI syntax from FortiManager, create a new script and add new information. 

 

202602_FMG_Script_UpdateNormalizeInterface_003a.png

 

202602_FMG_Script_UpdateNormalizeInterface_003b.png

 

In FortiManager, verify the normalized interface after running the script successfully.

 

202602_FMG_Script_UpdateNormalizeInterface_004a.png

 

202602_FMG_Script_UpdateNormalizeInterface_004b.png

 

Example FortiManager script information:

 

config dynamic interface
    edit "kentest_LAN"
        set description "123"
        set default-mapping enable
        set defmap-intf "kentest_LAN"
            config dynamic_mapping
                edit "rusa-kvm29"-"vdomA"
                    set local-intf "port7"
                next
                edit "rusa-kvm29"-"vdomB"
                    set local-intf "port9"
                next

                # Added new information <----- New information starts.
                edit "rusa-kvm29"-"root" 
                    set local-intf "port5" 
                next <----- New information ends.

            end

        next

    end

 

config dynamic interface
    edit "kentest_WAN"
        set default-mapping enable
        set defmap-intf "kentest_WAN"
            config dynamic_mapping
                edit "rusa-kvm29"-"vdomA"
                    set local-intf "port8"
                next
                edit "rusa-kvm29"-"vdomB"
                    set local-intf "port10"
                next

                # Added new information <----- New information starts.
                edit "rusa-kvm29"-"root" 
                    set local-intf "port6"
                next <----- New information ends.

            end

        next

    end

Thought Leadership. Security Summit. Thursday, November 12th, PGA National Resort, Palm Beach Gardens, FL.
Thought Leadership. Security Summit. Thursday, October 8th. Disney's Grand Californian Hotel & SPA, Anaheim, CA.