FG1-WAN1 - SW1-1/0/1 FG1-WAN2 - SW1-2/0/1
FG1-DMZ - SW1-1/0/2 FG1-Port1 - SW1-2/0/2
FG1-DMZ - SW1-1/0/3 FG1-Port1 - SW1-2/0/3
FG1-Port2 - SW1-1/0/4 FG1-Port3 - SW1-2/0/4
FG1-Port4 - SW1-1/0/5 FG1-Port5 - SW1-2/0/5
FG1-HA1 - SW1-1/0/6 FG1-HA2 - SW1-2/0/6
SW1-1/0/22 - Office_LAN 1 SW1-2/0/22 - Office_LAN 2 SW1-1/0/23 - 1 SW1-2/0/23 - 2 SW1-1/0/24 - - 1 SW1-2/0/24 - - 2
SW1-1/0/22 - DC_LAN 1 SW1-2/0/22 - DC_LAN 2 SW2-1/0/23 - 1 SW2-2/0/23 - 2 SW2-1/0/24 - - 1 SW2-2/0/24 - - 2
vlan 10 name DC_Internet vlan 20 name Office_Internet vlan 30 name Office_Lan vlan 40 name DC_LAN vlan 50 name Interconnect vlan 60 name HA
Interface port-channel1 switchport access vlan 10 # VLAN 10 = DC_Internet switchport mode access Interface GigabitEthernet1/0/1 switchport access vlan 10 switchport mode access channel-group 1 mode passive Interface GigabitEthernet2/0/1 switchport access vlan 10 switchport mode access channel-group 1 mode passive
Interface port-channel5 switchport access vlan 50 switchport mode access Interface GigabitEthernet1/0/5 switchport access vlan 50 switchport mode access channel-group 5 mode passive Interface GigabitEthernet2/0/5 switchport access vlan 50 switchport mode access channel-group 5 mode passive
Interface GigabitEthernet1/0/6 switchport access vlan 60 # Vlan 60 = HA switchport mode access
Interface GigabitEthernet2/0/6 switchport access vlan 60 # Vlan 60 = HA switchport mode access
Interface port-channel6 switchport mode trunk # !!! Trunk Interface GigabitEthernet1/0/24 switchport mode trunk channel-group 6 mode passive Interface GigabitEthernet2/0/24 switchport mode trunk channel-group 6 mode passive
Interface port-channel7 switchport access vlan 30 # VLAN 30 = Office_Lan switchport mode access Interface GigabitEthernet1/0/22 switchport access vlan 30 switchport mode access channel-group 7 mode passive Interface GigabitEthernet2/0/22 switchport access vlan 30 switchport mode access channel-group 7 mode passive Interface port-channel8 switchport access vlan 20 # VLAN 20 = Office_Internet switchport mode access Interface GigabitEthernet1/0/23 switchport access vlan 20 switchport mode access channel-group 8 mode passive Interface GigabitEthernet2/0/23 switchport access vlan 20 switchport mode access channel-group 8 mode passive
Interface port-channel7 switchport access vlan 40 # VLAN 40 = DC_Lan switchport mode access Interface GigabitEthernet1/0/22 switchport access vlan 40 switchport mode access channel-group 7 mode passive Interface GigabitEthernet2/0/22 switchport access vlan 40 switchport mode access channel-group 7 mode passive Interface port-channel8 switchport access vlan 10 # VLAN 10 = DC_Internet switchport mode access Interface GigabitEthernet1/0/23 switchport access vlan 10 switchport mode access channel-group 8 mode passive Interface GigabitEthernet2/0/23 switchport access vlan 10 switchport mode access channel-group 8 mode passive
config system interface edit "wan1" set vdom "DataCenter" set type physical set snmp-index 1 next edit "dmz" set vdom "Office" set type physical set snmp-index 2 next edit "wan2" set vdom "DataCenter" set type physical set snmp-index 7 next edit "ha1" set vdom "root" set type physical set snmp-index 9 next edit "ha2" set vdom "root" set status down set type physical set snmp-index 10 next edit "port1" set vdom "Office" set type physical set snmp-index 12 next edit "port2" set vdom "DataCenter" set type physical set snmp-index 13 next edit "port3" set vdom "Office" set type physical set snmp-index 17 next edit "port4" set vdom "DataCenter" set type physical set snmp-index 18 next edit "port5" set vdom "Office" set type physical set snmp-index 15 next edit "port6" set vdom "Office" set type physical set snmp-index 16 next edit "port7" set vdom "DataCenter" set type physical set snmp-index 19 next edit "port8" set vdom "Office" set status down set type physical set snmp-index 20 next edit "port9" set vdom "DataCenter" set status down set type physical set snmp-index 21 next edit "port10" set vdom "root" set status down set type physical set snmp-index 22 next edit "lan" set vdom "root" set status down set type hard-switch set snmp-index 11 next edit "DC_Internet" set vdom "DataCenter" set ip 2.2.2.2 255.255.255.224 set allowaccess ping https ssh set type aggregate set member "wan1" "wan2" set snmp-index 14 next edit "Office_Internet" set vdom "Office" set ip 1.1.1.1 255.255.255.248 set allowaccess ping https set type aggregate set member "port5" "dmz" set snmp-index 23 next edit "Office-LAN" set vdom "Office" set dhcp-relay-service enable set ip 192.168.100.1 255.255.255.0 set allowaccess ping https ssh set type aggregate set member "port6" "port1" set snmp-index 24 next edit "DC-LAN" set vdom "DataCenter" set ip 192.168.200.1 255.255.255.0 set allowaccess ping https ssh set type aggregate set member "port7" "port2" set snmp-index 25 next edit "Intercon-Office" set vdom "Office" set ip 192.168.150.1 255.255.255.252 set allowaccess ping set type aggregate set member "port8" "port3" set snmp-index 26 next edit "Intercon-DC" set vdom "DataCenter" set ip 192.168.150.2 255.255.255.252 set allowaccess ping set type aggregate set member "port9" "port4" set snmp-index 27 next end config system ha set group-name "aaa.com" set mode ap set password ENC xxx set hbdev "ha1" 50 set arps 30 set arps-interval 1 set session-pickup enable set link-failed-signal enable set ha-mgmt-status enable set ha-mgmt-interface "mgmt" set vcluster2 enable set override enable set priority 100 set monitor "Office_internet" "Office_LAN" "Intercon_Office" config secondary-vcluster set override enable set priority 250 set monitor "DC_Internet" "DC_LAN" "Intercon_DC" set vdom "DataCenter" end end
config vdom edit DataCenter config router static edit 1 set gateway 2.2.2.3 set device "DC_Internet" next edit 2 set dst 192.168.100.0 255.255.255.0 set gateway 192.168.150.1 set device "Intercon-DC" next edit 3 set gateway 192.168.150.1 set distance 15 set device "Intercon-DC" next end config system link-monitor edit "DC-Internet" set srcintf "DC_Internet" set server "2.2.2.3" set gateway-ip 2.2.2.3 set update-cascade-interface disable next edit "Interconnect" set srcintf "Intercon-DC" set server "192.168.150.1" set gateway-ip 192.168.150.1 set update-cascade-interface disable next end end end config vdom edit Office config router static edit 1 set gateway 1.1.1.2 set distance 9 set device "Office_Internet" next edit 2 set dst 192.168.200.0 255.255.255.0 set gateway 192.168.150.2 set device "Intercon-Office" next edit 3 set gateway 192.168.150.2 set distance 15 set device "Intercon-Office" next end config system link-monitor edit "Office-Internet-Check" set srcintf "Office_Internet" set server "1.1.1.2" set gateway-ip 1.1.1.2 set update-cascade-interface disable next edit "Interconnect" set srcintf "Intercon-Office" set server "192.168.150.2" set gateway-ip 192.168.150.2 set update-cascade-interface disable next end
config vdom edit DataCenter config vpn ipsec phase1 edit "site-to-site" set interface "DC_Internet" set nattraversal disable set proposal aes256-sha256 set dhgrp 5 set remote-gw 1.1.1.1 set psksecret ENC xxx next end config vpn ipsec phase2 edit "p2" set phase1name "site-to-site" set proposal aes256-sha256 set pfs disable set replay disable set auto-negotiate enable set src-addr-type name set dst-addr-type name set src-name "192.168.200.x" set dst-name "192.168.100.x" next end config vdom edit Office config vpn ipsec phase1 edit "site-to-site" set interface "Office_Internet" set nattraversal disable set proposal aes256-sha256 set dhgrp 5 set remote-gw 2.2.2.2 set psksecret ENC xxx next end config vpn ipsec phase2 edit "p2" set phase1name "site-to-site" set proposal aes256-sha256 set pfs disable set replay disable set keepalive enable set auto-negotiate enable set src-addr-type name set dst-addr-type name set src-name "192.168.100.x" set dst-name "192.168.200.x" next end
config vdom edit Office config firewall policy edit 20 set srcintf "Office-LAN" set dstintf "Office_Internet" set srcaddr "192.168.100.x" set dstaddr "192.168.200.x" set action ipsec set schedule "always" set service "ALL" set inbound enable set outbound enable set vpntunnel "site-to-site" next end config vdom edit DataCenter edit 9 set srcintf "DC-LAN" set dstintf "DC_Internet" set srcaddr "192.168.200.x" set dstaddr "192.168.100.x" set action ipsec set schedule "always" set service "ALL" set inbound enable set outbound enable set vpntunnel "site-to-site" next
Source: https://habr.com/ru/post/308460/
All Articles