Sunday 19 November 2017

RIB failure

အမေးများတဲ့ RIB failure အကြောင်းပြောကြတာပေါ့။ RIB failure ဆိုတာ နံရိုးကျိုးတဲ့ အကြောင်း ပြောတာ မဟုတ်ပါဘူး။ BGP မှာ မြင်တွေ့ရလေ့ရှိတဲ့ r ဆိုတဲ့ routing information base failure ဆိုတဲ့ အကြောင်းပါ။

အဓိက ကတော့ BGP table မှာ r အနေနဲ့ မြင်ရတဲ့ route တွေဟာ routing table ထဲကို မဝင်ရောက်နိုင်တာဖြစ်ပါတယ်။ ဘာကြောင့် မဝင်ရောက်နိုင်လဲဆိုရင်တော့ သူထက် AD သာတဲ့ IGP route တွေရှိနေလို့ပါပဲ။ ဒီနေရာမှာ ဖြစ်လေ့ရှိတာက iBGP routes တွေပါ။ သူရဲ့ AD က 200 ဆိုတော့ ဘယ် IGP နဲ့ ယှဉ်ယှဉ် အမြဲရှုံးနေမှာပါ။ IGP တွေဟာ AD အရမ်းမြင့်တဲ့ eBGP ကိုတော့ ကျော်နိုင်ဖို့ မလွယ်ပါဘူး။

Rib failure ဖြစ်ရတဲ့ အကြောင်းရင်းကို Cisco မှာ အကြောင်း ၃ ခု အနေနဲ့ ပြထားပါတယ်။ ဒါပေမဲ့ အပြင်မှာ အတွေ့များတာကတော့ iBGP vs IGP ကြောင့်ပါ။ ဒါကလည်း သဘာဝကျပါတယ်။ BGP အနေနဲ့ အောက်ခံ IGP ကို အားပြုရင်းသာ အလုပ်လုပ်ရတာဆိုတော့ IGP ထဲမှာ လိုအပ်တဲ့ route ရှိနေပီးသားဆိုရင် BGP route ကို သုံးစရာ မလိုတော့ဘူးဆိုတဲ့ သဘောပေါ့။

ဥပမာ ပြရရင် လက်ရွေးစင် ဘောလုံးအသင်း လူရွေးသလိုမျိုးပေါ့။ လက်ရွေးစင် အသင်းဟာ Routing table သာ ဖြစ်ခဲ့မယ်ဆိုရင် routing table တွေထဲကို ရောက်ဖို့အတွက် အကောင်းဆုံး route ဖြစ်ဖို့လိုပါတယ်။ ဒီလိုပဲ လက်ရွေးစင် ဖြစ်ဖို့အတွက် အကောင်းဆုံး ဖြစ်ဖို့လိုပါတယ်။ ဒီနေရာမှာ အနယ်နယ် အရပ်ရပ်က အကောင်းဆုံးလို့ ထင်ရတဲ့ ကစားသမားတွေကို လက်ရွေးစင် ရွေးမဲ့ အဖွဲ့ကို စေလွှတ်ကြပါတယ်။ Router ထဲမှာ OSPF EIGRP iBGP eBGP ဆိုတဲ့ route တွေ လာစု နေသလိုမျိုး။ အဲဒီကမှ နေရာတူ ကစားကြတဲ့ ကစားသမားတွေအကြား အကောင်းဆုံးကို ရွေးပီး ကျန်တဲ့ ကစားသမားတွေက ပြုတ်တဲ့သူပြုတ် အရံဖြစ်တဲ့သူဖြစ်ပေါ့။ Router မှာကျတော့ Same destination/network/prefix ကို သွားလို့ရတဲ့ route တွေအချင်းချင်း ယှဉ်ကြည့်ပီး အကောင်းဆုံးကို RIB ထဲထည့်လိုက်ပါတယ်။ ကျန်တဲ့ route တွေထဲကမှ ဒုတိယ တတိယ စသဖြင့် အကောင်းဆုံး route တွေကို အရံအဖြစ် သက်ဆိုင်ရာ Table/database အတွင်းမှာ အရံသင့် ချန်ထားပါတယ်။

BGP ရဲ့ r route ကတော့ အရံအဖြစ်သာ ရွေးခံရတဲ့ BGP route တစ်ခုပါပဲ။ Reserve ဆိုပါတော့။ ပထမ နေရာယူထားတဲ့ IGP route တွေသာ အကြောင်းတခုခုကြောင့် ပျောက်သွားခဲ့မယ်ဆိုရင် Reserve route က သူ့နေရာ ဝင်လာမှာ ဖြစ်ပါတယ်။ Routing table ထဲမှာ မရှိပေမဲ့ BGP route တွေ ဖလှယ်တဲ့အခါမှာ rib failure route တွေကိုလည်း ထည့်ပီး ဖလှယ်ကြပါတယ်။ အဲဒါကို မကြိုက်ရင်တော့ Suppress-inactive command အသုံးပြုပီး တားလို့ရပါတယ်။ ဘာကြောင့် RIB Failure ဖြစ်ရလည်း ဆိုတာကိုတော့
show ip bgp rib-failure ဆိုပြီး ကြည့်ရင်ရပါတယ်။ AD ကြောင့်ဆိုရင် Higher admin distance ဆိုပြီး မြင်ရမှာပါ။

အရှင်းဆုံးပြောရရင်တော့ ဘာကြောင့် အရွေးမခံရလဲဆိုရင် သူထက်သာတဲ့သူ ရှိလို့ပါ။ Route တွေကို ဘာနဲ့ယှဉ်လဲ ဆိုရင် AD နဲ့ပါ။ ဒီတော့ AD နိမ့်တဲ့သူက ရှုံးပါတယ်။ ဒါလောက်ဆို Rib failure အကြောင်း သဘောပေါက်လောက်ပီလို့ ထင်ပါတယ်။

Cisco Ref:

What does r RIB-Failure mean in the show ip bgp command output?

R1> show ip bgp
BGP table version is 5, local router ID is 200.200.200.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
              r RIB-failure
Origin codes: i - IGP, e - EGP, ? - incomplete

   Network          Next Hop            Metric LocPrf Weight Path
r> 6.6.6.0/24       10.10.13.3               0    130      0 30 i
*> 7.7.7.0/24       10.10.13.3               0    125      0 30 i

When BGP tries to install the bestpath prefix into Routing Information Base (RIB) (for example, the IP Routing table), RIB might reject the BGP route due to any of these reasons:

* Route with better administrative distance already present in IGP. For example, if a static route already exists in IP Routing table.
* Memory failure.
* The number of routes in VPN routing/forwarding (VRF) exceeds the route-limit configured under the VRF instance.
In such cases, the prefixes that are rejected for these reasons are identified by r RIB Failure in the show ip bgp command output and are advertised to the peers. This feature was first made available in Cisco IOS Software Release 12.2(08.05)T.

ကိုဖြိုး။