キャンセル
次の結果を表示 
次の代わりに検索 
もしかして: 

ACE: backup-rserver の基本動作

    ACE は、primary rserver down を検知すると、traffic backup rserver に切り替えることが可能です。 backup rserver は、primary rserver と同程度の性能の代替 rserver を用意しておくという用途以外に、primary rserver access できないことを知らせる sorry server を設置することも可能です。

    backup-rserver_01.png

    backup-rserver は、下記のように serverfarm 上で設定します。 backup-rserver [rserver] の設定を行うと、自動的に rserver が登録され、inservice standby の設定が入ります。

    ACE20/Admin# conf t

    Enter    configuration commands, one per line.  End with CNTL/Z.

    ACE20/Admin(config)#    serverfarm host sf

    ACE20/Admin(config-sfarm-host)#    rserver sv1

    ACE20/Admin(config-sfarm-host-rs)#    backup-rserver sv2

    ACE20/Admin(config-sfarm-host-rs)#    in

    ACE20/Admin(config-sfarm-host-rs)#    end

    ACE20/Admin# sh run serverfarm

    Generating    configuration....

    serverfarm    host sf

      rserver sv1

        backup-rserver sv2

        inservice

    rserver sv2

        inservice standby

    ACE20/Admin#

    設定を行うと、backup  rserver STANDBY 状態になり、primary rserver down した場合に、OPERATIONAL に切り替わります。

    ACE20/Admin# sh rserver

    rserver              : sv1, type: HOST

    state                : OPERATIONAL (verified by    arp response)

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.11:0       8      OPERATIONAL  0          0

    rserver              : sv2, type: HOST

    state                : OPERATIONAL (verified by    arp response)

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.12:0       8      STANDBY      0          0

    ACE20/Admin#

    !___ rserver sv1 interface down

    ACE20/Admin# sh rserver

    rserver              : sv1, type: HOST

    state                : ARP_FAILED

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.11:0       8      ARP_FAILED   0          0

    rserver              : sv2, type: HOST

    state                : OPERATIONAL (verified by    arp response)

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.12:0       8      OPERATIONAL  0          0

    ACE20/Admin#

    Configuring Real Servers and Server  Farms に記載されているように、STANDBY 状態の rserver Up と同様の動作をします。 つまり、STANDBY 状態の rserver packet を転送すると、この rserver OPERATIONAL の場合と同様に traffic を処理します。 そのため、primary rserver OPERATIONAL に戻ったとしても、既存 connection backkup rserver を使用し続けます。

    State

    Current state    of the real server:

    INACTIVE --- Real server is not associated with a server farm

    OPERATIONAL --- Real server is in primary mode and is Up

    STANDBY --- Real server is in backup mode and is Up

    OUTOFSERVICE --- Real server is no longer in service (for both the    primary and the backup real server)

    # 切り戻し時の ACE 出力


    ACE20/Admin# sh rserver

    rserver              : sv1, type: HOST

    state                : ARP_FAILED

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.11:0       8      ARP_FAILED   0          0

    rserver              : sv2, type: HOST

    state                : OPERATIONAL (verified by    arp response)

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.12:0       8     OPERATIONAL     1          1

    ACE20/Admin#

    ACE20/Admin# ping 192.168.72.11

    Pinging 192.168.72.11 with timeout = 2,    count = 5, size = 100 ....

    No response    received from 192.168.72.11 within last 2 sec

    Response from 192.168.72.11 :  seq 2 time 0.371 ms

    Response from 192.168.72.11 :  seq 3 time 0.130 ms

    Response from 192.168.72.11 :  seq 4 time 0.143 ms

    Response from 192.168.72.11 :  seq 5 time 0.160 ms

    5 packet    sent, 4 responses received, 20% packet loss

    ACE20/Admin#

    ACE20/Admin# sh rserver

    rserver              : sv1, type: HOST

    state                : OPERATIONAL (verified by    arp response)

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.11:0       8      OPERATIONAL  0          0

    rserver              : sv2, type: HOST

    state                : OPERATIONAL (verified by    arp response)

    ---------------------------------

                                                    ----------connections-----------

           real                  weight state        current    total

       ---+---------------------+------+------------+----------+--------------------

       serverfarm: sf

           192.168.72.12:0       8     STANDBY         1          1

    !___ STANDBY になっても、connection は維持したまま

    # client 出力

    client:/# telnet 192.168.71.100 80

    Trying    192.168.71.100...

    Connected to    192.168.71.100.

    Escape    character is '^]'.

    GET / HTTP/1.1

    Host:

    HTTP/1.1 200    OK

    Date: Sun, 29    Aug 2010 22:54:12 GMT

    Server:    Apache/1.3.34 (Debian)

    Last-Modified:    Sun, 11 Jul 2010 22:07:57 GMT

    ETag:    "2e4a13-4-4c3a40bd"

    Accept-Ranges:    bytes

    Content-Length:    4

    Content-Type:    text/html; charset=iso-8859-1

    sv2

    !___ sv1: ARP_FAILED, sv2 : OPERATIONAL

    !___ sv1 interface up にし、ACE から ping 実行

    GET / HTTP/1.1

    Host:

    HTTP/1.1 200    OK

    Date: Sun, 29    Aug 2010 22:54:32 GMT

    Server:    Apache/1.3.34 (Debian)

    Last-Modified:    Sun, 11 Jul 2010 22:07:57 GMT

    ETag:    "2e4a13-4-4c3a40bd"

    Accept-Ranges:    bytes

    Content-Length:    4

    Content-Type:    text/html; charset=iso-8859-1

    sv2

    !___ sv1 OPERATIONAL に戻っているが、sv2 との connection は維持したまま

    # ACE 設定


    ACE20/Admin# sh run

    Generating    configuration....

    hostname    ACE20

    boot system    image:c6ace-t1k9-mz.A2_3_1.bin

    access-list    all line 8 extended permit ip any any

    rserver host    sv1

      ip address 192.168.72.11

      inservice

    rserver host    sv2

      ip address 192.168.72.12

      inservice

    serverfarm    host sf

      rserver sv1

        backup-rserver sv2

        inservice

      rserver sv2

        inservice standby

    class-map    match-all vip-l3

      2 match virtual-address 192.168.71.100 any

    policy-map    type loadbalance first-match lb

      class class-default

        serverfarm sf

    policy-map    multi-match client-vips

      class vip-l3

        loadbalance vip inservice

        loadbalance policy lb

        loadbalance vip icmp-reply

    access-group    input all

    interface    vlan 771

      ip address 192.168.71.250 255.255.255.0

      service-policy input client-vips

      no shutdown

    interface    vlan 772

      ip address 192.168.72.250 255.255.255.0

      no shutdown

    どの rserver を使用するか (LB) は、XScale が判断を行うため、既に connection を張り、FastPath で折り返すような通信の場合、primary  rserver OPERATIONAL に戻ったとしても、影響を受けません。

    また、sticky LB 機能よりも先に動作するため、sticky table entry が存在する場合、STANDBY 状態の rserver traffic を転送し続けるという状態が発生することがあります。 もし、その状況を避けたい場合、backup-rserver ではなく、下記のように、sticky mode backup serverfarm (sticky option なし) を設定する必要があります。 sticky option に関しては、Configuring Stickiness をご参照ください。

    serverfarm host sf1

      rserver sv1

        inservice

    serverfarm host sf2

      rserver sv2

        inservice

    sticky    ip-netmask 255.255.255.255 address both sticky_ip

      serverfarm sf1 backup sf2

バージョン履歴
改訂番号
1/1
最終更新:
‎08-30-2010 04:31 PM
更新者: