ネットワーク機器トップ > 製品ラインナップ > FITELnet-Fシリーズ > FITELnet-F100・1000 > 設定例 > IPsec負荷分散設定(4) |
4.センタF1000(2台各1回線)・拠点F100(1台1回線)でIPsec負荷分散を行う |
センタ側F1000-1 PPPoE1 | 200.200.200.200 |
センタ側F1000-2 PPPoE1 | 100.100.100.100 |
拠点側 PPPoE1 | アドレス不定 |
<設定条件>
IPsecの対象とする中継パケット | any ⇔
172.16.0.0/16 ※センタ側L3SWの背後の別セグメントからもVPN可能 |
IPsec Phase1ポリシー | モード ・・・ Aggressiveモード 認証方式 ・・・ 事前共有鍵方式 暗号化方式 ・・・ 3DES ハッシュ方式 ・・・ MD5 |
IPsec Phase2ポリシー | 暗号化方式 ・・・ 3DES ハッシュ方式 ・・・ MD5 |
IPsec負荷分散の比率(VPN1:VPN2) | 2:1 ※1 (拠点側F100) |
L3SW (192.168.3.254) | RIP(Ver.2)を受信 ※F100、F1000のRIPはVer.2を使用(初期値) |
|
この設定を適用したい方は |
Router> enable Enter password: super ←パスワードを入力します。(実際は表示されない) ! ! ! LAN側IPアドレスを設定します。 ! Router(config)# interface lan 1 Router(config-if lan 1)# ip address 172.16.0.1 255.255.0.0 Router(config-if lan 1)# exit ! ! ! PPPoE1 の各種設定をします。 ! Router(config)# interface pppoe 1 Router(config-if pppoe 1)# pppoe server A-Provider Router(config-if pppoe 1)# pppoe account user@xxxx.ne.jp secret Router(config-if pppoe 1)# pppoe type host Router(config-if pppoe 1)# crypto map VPN1 Router(config-if pppoe 1)# crypto map VPN2 ! 1つのインタフェース上で2つのVPNを張ります Router(config-if pppoe 1)# exit ! ! ! センタ側のピアへのルートを設定します。 ! Router(config)# ip route 200.200.200.200 255.255.255.255 pppoe 1 Router(config)# ip route 100.100.100.100 255.255.255.255 pppoe 1 ! ! ! DHCPサーバ機能を設定します。 ! Router(config)# service dhcp-server Router(config)# ip dhcp pool lan1 Router(config-dhcp-pool)# default-router 0.0.0.0 Router(config-dhcp-pool)# exit Router(config)# ! ! ! IPsec負荷分散の設定をします。 ! Router(config)# vpn enable Router(config)# vpnlog enable ! Router(config)# ipsec access-list 10 ipsec ip 172.16.0.0 0.0.255.255 any Router(config)# ipsec access-list 64 bypass ip any any Router(config)# ipsec transform-set P2-3DES-MD5 esp-3des esp-md5-hmac ! Router(config)# crypto isakmp policy 1 Router(config-isakmp)# authentication prekey Router(config-isakmp)# encryption 3des Router(config-isakmp)# hash md5 Router(config-isakmp)# keepalive icmp always-send ! icmpにより常時keep aliveを行います Router(config-isakmp)# keepalive-icmp peer-address 192.168.3.1 ! 監視先のアドレスを設定します Router(config-isakmp)# keepalive-icmp source-interface lan 1 ! 送信元IPアドレスをLAN側IPアドレスとすることにより、 ! VPNトンネルを通してkeep aliveをおこないます Router(config-isakmp)# keepalive-icmp multi-path interface pppoe 1 *1 ! keep aliveの送受信インタフェースを固定します Router(config-isakmp)# key ascii furukawa Router(config-isakmp)# my-identity kyoten1-1 Router(config-isakmp)# negotiation-mode aggressive Router(config-isakmp)# peer-identity address 200.200.200.200 Router(config-isakmp)# exit ! Router(config)# crypto isakmp policy 2 Router(config-isakmp)# authentication prekey Router(config-isakmp)# encryption 3des Router(config-isakmp)# hash md5 Router(config-isakmp)# keepalive icmp always-send Router(config-isakmp)# keepalive-icmp peer-address 192.168.3.20 Router(config-isakmp)# keepalive-icmp source-interface lan 1 Router(config-isakmp)# keepalive-icmp multi-path interface pppoe 1 *1 Router(config-isakmp)# key ascii furukawa Router(config-isakmp)# my-identity kyoten1-2 Router(config-isakmp)# negotiation-mode aggressive Router(config-isakmp)# peer-identity address 100.100.100.100 Router(config-isakmp)# exit ! Router(config)# crypto map VPN1 1 Router(config-crypto-map)# match address 10 multi-path balance 2 *2 ! VPN1側の比率を2として負荷分散します Router(config-crypto-map)# set peer address 200.200.200.200 Router(config-crypto-map)# set security-association always-up ! SAを常時確立しておくようにします Router(config-crypto-map)# set transform-set P2-3DES-MD5 Router(config-crypto-map)# sa-up route interface pppoe 1 local-prot1 *3 ! SAの確立を契機としてセンタ側LAN(any)へのルート情報を ! nexthopをpppoe1として登録します Router(config-crypto-map)# exit ! Router(config)# crypto map VPN2 2 Router(config-crypto-map)# match address 10 multi-path balance 1 *2 ! VPN2側の比率を1として負荷分散します Router(config-crypto-map)# set peer address 100.100.100.100 Router(config-crypto-map)# set security-association always-up Router(config-crypto-map)# sa-up route interface pppoe 1 local-prot2 *3 ! VPN1とVPN2で全く同じルート情報が登録されることになるので、 ! この2つをlocal-protオプションを付けて区別できるようにします。 Router(config-crypto-map)# set transform-set P2-3DES-MD5 Router(config-crypto-map)# exit ! Router(config)# end Router# save SIDE-A.cfg % saving working-config % finished saving |
*1: pppoe 1 ではなく、ewan 1 でアドレスを マニュアル設定している場合は、次のように設定します。 keepalive-icmp multi-path address <nexthop のアドレス>*2:F100ではV01.10以降、F1000ではV01.03以降のファームウェアから、 どちらかの比率を0に設定できるようになりました。 負荷分散の比率は送信方向のパケットに対してのみ機能します。 *3: pppoe 1 ではなく、ewan 1 でアドレスを マニュアル設定している場合は、次のように設定します。 sa-up route address <nexthop のアドレス> local-prot1 sa-up route address <nexthop のアドレス> local-prot2 |
! ip route 0.0.0.0 0.0.0.0 192.168.3.254 ! vpn enable vpnlog enable ! ipsec access-list 10 ipsec ip any 172.16.0.0 0.0.255.255 ipsec access-list 64 bypass ip any any ipsec transform-set P2-3DES-MD5 esp-3des esp-md5-hmac ! hostname F1000-1 ! interface pppoe 1 crypto map map1 pppoe server test pppoe account zyx@furukawa.co.jp zyx pppoe type host ip address 200.200.200.200 exit ! interface lan 1 ip address 192.168.3.1 255.255.255.0 exit ! crypto isakmp policy 1 authentication prekey encryption 3des hash md5 keepalive icmp always-send keepalive-icmp peer-address 172.16.0.1 keepalive-icmp source-interface lan 1 keepalive-icmp multi-path interface pppoe 1 key ascii furukawa negotiation-mode aggressive peer-identity host kyoten1-1 tunnel-route interface pppoe 1 ! 対向のVPNピアへのルートを、nexthopをPPPoE1として登録します exit crypto map map1 1 match address 10 set peer host kyoten1-1 set transform-set P2-3DES-MD5 sa-up route interface pppoe 1 ! local-protオプションがない場合、redistributeで指定しなくても、このルート情報をRIPで ! 広告します。local-protオプションがある場合、RIPで広告するには、明示的にredistributeで ! 指定する必要があります。 exit ! router rip network lan 1 exit ! end |
! ip route 0.0.0.0 0.0.0.0 192.168.3.254 ! vpn enable vpnlog enable ! ipsec access-list 10 ipsec ip any 172.16.0.0 0.0.255.255 ipsec access-list 64 bypass ip any any ipsec transform-set P2-3DES-MD5 esp-3des esp-md5-hmac ! hostname F1000-2 ! interface lan 1 ip address 192.168.3.20 255.255.255.0 exit interface pppoe 1 crypto map map1 ip address 100.100.100.100 pppoe server test pppoe account xyz@furukawa.co.jp xyz pppoe type host exit ! crypto isakmp policy 1 authentication prekey encryption 3des hash md5 keepalive icmp always-send keepalive-icmp peer-address 172.16.0.1 keepalive-icmp source-interface lan 1 keepalive-icmp multi-path interface pppoe 1 key ascii furukawa negotiation-mode aggressive peer-identity host kyoten1-2 tunnel-route interface pppoe 1 exit crypto map map1 1 match address 10 set peer host kyoten1-2 set transform-set P2-3DES-MD5 sa-up route interface pppoe 1 exit ! access-list 10 permit 172.16.0.0 0.0.255.255 ! router rip network lan 1 offset-list 10 out 5 lan 1 ! sa-upルートで登録した情報をRIPで広告する際に、metric値を+5して出すようにします。 exit ! end |