Fortigate DHCP server VIA CLI and adding DHCP Options

Fortinet does a great job with almost every aspect of the Fortigate device. There are a few hidden , but very important options that you cannot configure in the GUI of Fortinet. One being DHCP options, for Voice, Wireless, Etc. Below are the setups to setup a DHCP scope in CLI, and add options. Another option is to configure the scope through GUI, and then just modify the scope through CLI to add the options.

Within the Gui in FortiOS5 the DCHP config is in the network interface. This is a great place to have it. In CLI the option to configure it is

config sys dhcp server

Below image shows all commands needed in CLI

Image

Once you edit the dhcp scope (config sys dhcp server.. then edit the scope id. )

You can add the following commands:

Image

So, lets add option 46. This could be used with Ruckus wireless to push AP broadcasts to the Zonedirector.

To set the option for example here to an IP address, it  requires you to convert this to HEX.

I used this : http://www.kloth.net/services/iplocate.php

Image

after setting this command, my APs hooked up to my ZD.

So to recap, with DHCP and FortiOS5 you can create the DHCP scope totally in CLI, or it works great in the GUI. You can configure this under network – interface. If you need to add options such as WINS, NTP, or other options it might be best to configure these through CLI.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: