Skip to main content
mvlasak
Staff
Staff
Nov 29, 2024 9:59 AM UTC

Technical Tip: Delete FortiLink via CLI script on Device database

Description This article describes how to delete FortiLink via the CLI script in the Device database.
Scope FortiManager 7.x.
Solution

Create and execute the following CLI script on the device database in the FortiGate default config:

 

config system ntp

    unset interface

    set server-mode disable
end

 

config system dhcp server
    delete 2
end


config system interface
    edit "fortilink"
        set fortilink disable
        unset member
    next
    delete fortilink
end

 

If it is not possible to successfully delete the interface, check if FortiLink is being used by other entries by running the command below:

 

diagnose sys cmdb refcnt show system.interface.name fortilink

    Thought Leadership. Security Summit. Thursday, November 12th, PGA National Resort, Palm Beach Gardens, FL.
    Security Operations Summit: Modernize SecOps. Operate AI-Native.AMER: November 4 | 9:00 AM PST. India and SAARC: November 5 | 10:00 AM IST. EMEA: November 5 | 10:30 AM CET. APAC: November 5 | 11:00 AM SGT