Xin chào ! Nếu đây là lần đầu tiên bạn đến với diễn đàn, xin vui lòng danh ra một phút bấm vào đây để đăng kí và tham gia thảo luận cùng VnPro.

Announcement

Collapse
No announcement yet.

cấu hình Peer với 2 ISP nhưng ưu tiên 01 ISP?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • cấu hình Peer với 2 ISP nhưng ưu tiên 01 ISP?

    Hi các bác

    Em có 1 mô hình config như bên dưới (peer với 2 ISP khác nhau). Nếu em muốn luôn ưu tiên đường của ISP1 thì cần sửa như thế nào? Bác nào biết xin chỉ giúp

    Thanks

    router bgp xxxxx
    no synchronization
    bgp log-neighbor-changes
    network x.x.x.x
    neighbor <peer router 1> remote-as xxxx
    neighbor <peer router 1> description "Transist via ISP1"
    neighbor <peer router 1> next-hop-self
    neighbor <peer router 1> version 4
    neighbor <peer router 1> route-map SETPATH-VDC out
    neighbor <peer router 1> filter-list 2 out
    neighbor <peer router 1> weight 10
    neighbor <peer router 2> remote-as xxxx
    neighbor <peer router 2> description "Transist via ISP2"
    neighbor <peer router 2> ebgp-multihop 10
    neighbor <peer router 2> next-hop-self
    neighbor <peer router 2> version 4
    neighbor <peer router 2> soft-reconfiguration inbound
    neighbor <peer router 2> filter-list 2 out
    no auto-summary


    ip as-path access-list 2 permit ^$
    ip as-path access-list 2 permit ^(<ASnumber>_)+$
    ip as-path access-list 2 deny .

  • #2
    bạn thử cấu hình này xem sao:
    route-map RM_SETWEIGHT_ISP1
    set weight 100
    route-map RM_SETWEIGHT_ISP2
    set weight 10
    router bgp xxxxx
    neighbor <peer router 1> route-map RM_SETWEIGHT_ISP1 in
    neighbor <peer router 2> route-map RM_SETWEIGHT_ISP2 in

    Comment


    • #3
      à bạn nhớ dùng lệnh:
      #clear ip bgp *
      sau apply cấu hình trên :)

      Comment


      • #4
        Thank you very much

        Comment


        • #5
          Minh nghi kg can apply gi` ca, cau hinh cua ban da uu tien nhung route cua ISP 1 vi command
          neighbor <peer router 1> weight 10
          CCIE Lab 1st ------> Aug 6th ----> Fail fail fail
          CCIE Lab 2nd------> Jan 29th

          Comment


          • #6
            đây là link giải thích lệnh "neighbor weight" từ cisco, có điều bạn nên dùng route-map để set weight thì hay hơn vì chỉ hầu hết mọi việc bạn có thể dùng route-map để làm.

            neighbor weight

            To assign a weight to a neighbor connection, use the neighbor weight command in address family or router configuration mode. To remove a weight assignment, use the no form of this command.

            neighbor ip-address | peer-group-name weight number

            no neighbor ip-address | peer-group-name weight number
            Syntax Description

            ip-address


            IP address of the neighbor.

            peer-group-name


            Name of a BGP peer group.

            number


            Weight to assign. Acceptable values are from 0 to 65535.

            Defaults

            Routes learned through another BGP peer have a default weight of 0 and routes sourced by the local router have a default weight of 32768.
            Command Modes

            Address family configuration
            Router configuration
            Command History
            Release

            Modification

            10.0


            This command was introduced.

            12.0(7)T


            Address family configuration mode was added.

            Usage Guidelines

            All routes learned from this neighbor will have the assigned weight initially. The route with the highest weight will be chosen as the preferred route when multiple routes are available to a particular network.

            The weights assigned with the set weight route-map command override the weights assigned using the neighbor weight command.

            Note For weight changes to take effect, use of the clear ip bgp peer-group * command may be necessary.

            If you specify a BGP peer group by using the peer-group-name argument, all the members of the peer group will inherit the characteristic configured with this command.
            Examples

            The following router configuration mode example sets the weight of all routes learned via 172.16.12.1 to 50:

            router bgp 109
            neighbor 172.16.12.1 weight 50


            The following address family configuration mode example sets the weight of all routes learned via 172.16.12.1 to 50:

            router bgp 109

            address-family ipv4 multicast
            neighbor 172.16.12.1 weight 50

            Comment


            • #7
              Co nhiu cach de giai quyet 1 van de, route-map co the lam duoc nhiu viec nhung van de quan trong la ban ca`ng don gian cau hinh cua minh thi` ban ca`ng de troubleshoot van de ! ( khong phai tu nhien Cisco lai them vao command weight )
              Do la suy nghi cua minh!
              CCIE Lab 1st ------> Aug 6th ----> Fail fail fail
              CCIE Lab 2nd------> Jan 29th

              Comment

              Working...
              X