1 2 3 4 5 6 7 8 9 10 11 12 13 14 ddns-update-style none; default-lease-time 6000; max-lease-time 72000; authoritative; option classless-static-routes code 121 = array of integer 8; subnet 192.168.116.0 netmask 255.255.255.0 { range 192.168.116.10 192.168.116.19; option routers 192.168.116.254; option domain-name-servers 172.24.1.2; option static-routes 33.1.1.1 192.168.116.33 option classless-static-routes 24, 172, 20, 3, 192, 168, 116, 3, 28, 172, 20, 4, 0, 192, 168, 116, 4; }
Option 33
Line 12,指定 static-routes,參數是兩個 IP,第一個是 DestIP,第二個是 Roter 的 IP,如範例所示是 33.1.1.1 要經由 192.168.116.33
Option 121
需要自定義此 Option,如 Line 6 名稱: classless-static-routes Option Code: 121 參數內容: 8 個 Integer 設定範例如 line 13, 指定兩個 subnet 的 static route 第一個是 172.20.3.0/24 走 192.168.116.3 第二個是 172.20.4.0/28 走 192.168.116.4