Monday, October 26, 2015

BGP interview Questions

Here is a list of questions that I could come across while i studied BGP topics. This is a very rough draft.

BGP Questions
- How do you inject a network into bgp ? the command
- what is r - rib failure in sh ip bgp? - it means it is best route in bgp but we lost from the routing table as it is learnt via another protocol
- what is command  no auto-summary in bgp config? it means that put the exact network and the exact mask and it will advertise( classless).so if you have lot of 10.0.0.0 network and you insert command "network 10.0.0.0" inside bgp these networks wont be advertise via bgp. this is because autosummary is off by default and we need to type exact network and mask. if we turn on autosummary and then do this classfull network command we will see all 10 networks inside bgp
- what is no synchronization command in bgp config? if sych is off it means that i will not use the bgp route unless it is learnt via an igp. Now it is no sync by default.
- In bgp what are origin code of "i" and "?" - i means this network is into bgp from the network command and is configured on this router. "?" means that this network is into bgp from the redistribute command under bgp config
- what is sourcing a default route in bgp - it means that r1---->r2.. suppose r1 wants to inform r2 that is r2 wants to send traffic anywhere and is not specified in r2 table then send it to me r1
- How to source a default route? on r1 put the command " neighbor r2ip default-originate" . you wont see a default route on r1 . but if you check sh ip bgp of r2 you will see 0.0.0.0 next hop r1
- what is aggregation(summary) routes in bgp? how to do it? - it is here we take many detailed networks and advertise them as block of single larger address.We do this to reduce the number of router in bgp on internet.
- what is split horizon rule of bgp? as89(R8) ----- as3(R6 --R5--R3)
R8 sends ebgp update to R6. R6 will send ibgp update to R5 . But R5 will not send ibgp updat to R3 or any other internal bgp neighbors.
- why peering with loopback interface is good instead of physical interface?
- What are the ways to overcome full mesh topology in ibgp network? - confederation and routereflectors
- what are the two benefits of route reflectors? - 1) eleminate need for full mesh - ie send one update to route reflector the route reflector sends update to all its clients
2) loop prevention through cluster id- ie if i am a route reflector and i receive a route with my own cluster id i discard it.
- Explain configuring rr. ?  as3(R6 --R5--R3) on R5 we want it to be rr. neighbor 3.3.3.3 remote-as 3, neighbor 3.3.3.3 route-reflector-client. -> this is the only command needed on R5 ie rr and it will start sending updates to R3
- On router how will you check if that router is advertising bgp routes down to its neighbor ? sh ip bgp neighbor <neighbor ip> advertised-route
- does bgp send all routes it knows via bgp to its neighbor? entire sh ip bgp table? - no bgp send to its neighbor only valid routes with > sign
- if a client sends and update to rr, do  clients and nonclients get it? answer yes
- if a nonclient send a update to rr , do  clients and nonclients get it? - clients get it. Non clients dont get it
-
- in confederations does the rule of ttl of 1 between two ebgp apply? how to overcome it?.- yes it applies. to overcome it neighbor <ip> ebgp-multihop <coutn
- How to configure peer groups? neighbor MYPEERS peer-group, neighbor MYPEERS remote-as 123, neighbor MYPEERS update-source lo, neighbpr 1.1.1.1 peer-group MYPEERS
- what is bgp update-group? bgp dynamically assigns neighbors to update groups
- what is commmand to enable password for forming bgp neighbor? we need to do neighbor 1.1.1.1 password xyz
- what is ttl security in bgp?  neighbor <ip> ttl-security hops <number of hops> put on both routers
- What is NHS ? explain with example
- what is default ttl for ibgp neighbors and ebgp neighbors?
- what modifications are needed to ttl if ebgp neighbors are not directly connected
- what is advantage of peering with neighbors loopback ip address instead of physical address
- If we want to neighbor up with peers loopback address what is the additional command and what is the implication if we do not use that commnad and still use loopback to peer up with neighbor
- There are two bgp neighbors. You want one neighbor to always be server and other to be client. How can you do that? hint - update loopback sourc on one neighbor.
other neighbor dont mention this commnad... R1 forms neighborship with 2.2.2.2 using loopback and R2 when trying to form neibhborship with R1 loopback dont use update loopback source and it wil form neighborship as already it will see that it has a neighbor statement

R1-----------------------------------------------------------------------R2
on R1 - neighbor 2.2.2.2 update source lo 0
Now R1 forms neighbor with 2.2.2.2 from 1.1.1.1
From R2 - neibhbor 1.1.1.1 (no update source)
R2 thinks I already have neibhborship with 1.1.1.1 so forms neibhbor.
In this case R2 will always be server , R1 always client


- how do you change the router id of bgp and does it have impact on existing bgp established sessions?
- How do you inject a network into bgp ? the command
- what is r - rib failure in sh ip bgp? - it means it is best route in bgp but we lost from the routing table as it is learnt via another protocol
- what is command  no auto-summary in bgp config? it means that put the exact network and the exact mask and it will advertise( classless).so if you have lot of 10.0.0.0 network and you insert command "network 10.0.0.0" inside bgp these networks wont be advertise via bgp. this is because autosummary is off by default and we need to type exact network and mask. if we turn on autosummary and then do this classfull network command we will see all 10 networks inside bgp
- what is no synchronization command in bgp config? if sych is off it means that i will not use the bgp route unless it is learnt via an igp. Now it is no sync by default.
- In bgp what are origin code of "i" and "?" - i means this network is into bgp from the network command and is configured on this router. "?" means that this network is into bgp from the redistribute command under bgp config
- what is sourcing a default route in bgp - it means that r1---->r2.. suppose r1 wants to inform r2 that is r2 wants to send traffic anywhere and is not specified in r2 table then send it to me r1
- How to source a default route? on r1 put the command " neighbor r2ip default-originate" . you wont see a default route on r1 . but if you check sh ip bgp of r2 you will see 0.0.0.0 next hop r1
- what is aggregation(summary) routes in bgp? how to do it? - it is here we take many detailed networks and advertise them as block of single larger address.We do this to reduce the number of router in bgp on internet.
- what is split horizon rule of bgp? as89(R8) ----- as3(R6 --R5--R3)
R8 sends ebgp update to R6. R6 will send ibgp update to R5 . But R5 will not send ibgp updat to R3 or any other internal bgp neighbors.
- why peering with loopback interface is good instead of physical interface?
- What are the ways to overcome full mesh topology in ibgp network? - confederation and routereflectors
- what are the two benefits of route reflectors? - 1) eleminate need for full mesh - ie send one update to route reflector the route reflector sends update to all its clients
2) loop prevention through cluster id- ie if i am a route reflector and i receive a route with my own cluster id i discard it.
- Explain configuring rr. ?  as3(R6 --R5--R3) on R5 we want it to be rr. neighbor 3.3.3.3 remote-as 3, neighbor 3.3.3.3 route-reflector-client. -> this is the only command needed on R5 ie rr and it will start sending updates to R3
- On router how will you check if that router is advertising bgp routes down to its neighbor ? sh ip bgp neighbor <neighbor ip> advertised-route
- does bgp send all routes it knows via bgp to its neighbor? entire sh ip bgp table? - no bgp send to its neighbor only valid routes with > sign
- if a client sends and update to rr, do  clients and nonclients get it? answer yes
- if a nonclient send a update to rr , do  clients and nonclients get it? - clients get it. Non clients dont get it
-
- in confederations does the rule of ttl of 1 between two ebgp apply? how to overcome it?.- yes it applies. to overcome it neighbor <ip> ebgp-multihop <coutn
- How to configure peer groups? neighbor MYPEERS peer-group, neighbor MYPEERS remote-as 123, neighbor MYPEERS update-source lo, neighbpr 1.1.1.1 peer-group MYPEERS
- what is bgp update-group? bgp dynamically assigns neighbors to update groups
- what is commmand to enable password for forming bgp neighbor? we need to do neighbor 1.1.1.1 password xyz
- what is ttl security in bgp?  neighbor <ip> ttl-security hops <number of hops> put on both routers
- explain origin code in bgp? - i put into bgp with network statement.
-what are well know mandatoryattributes? give examples - well know is recognized by every bgp speaker and must be present in update eg. nh, aspath.
-what are well know discretionary? give examples - well know is recognized by every bgp speaker and discretionary means may or may not be present in an update eg atomic path aggregator
- what are optional transitive? give examples - optional may or may not be recognized by other bgp neighbors, and transitive means passed betn ebgp and ibgp neighbors
- what are optional nontransitive? give examples - non transitive means passed only between ibgp neighbors
- what is the most important aspect of as path attribute? - loop prevention, if an as sees its own as path in the updates it will not accept it
- how will u influence r6 to be the egress for all traffic to 2,2,2,2 route - set the local pref to be highest for 2.2.2.2 route on r6 . this is propagated to all nodes in as3 and all take r6 as best path to egress out to 2.2.2.2 n- w
- how will you influence ingress traffic on one link when you are hultihomed to single service provider? advertise med for the particular neighbor with lower med value
- what is atomic aggregate and aggrigator?  atomic aggregate - here atomic means one.this means we advertise one summary inor out of the as.
 aggregator is the individual who did the aggregation.
- how do we maniputlate outbound taffic ? Local pref and weight
- what is aspath prepending?why use it? - this is used to influence others to take a particular path.
- why use med when we can do inbound traffic manipulation using aspath prepend? - aspath prepand we do not know what the policy of the other as is towards our as.
- what is a distribute list explain with eg
- what is a route map explain with eg
- what is a pefix list explain with eg
- difference between acl distribute list prefix list and route map explain?
- how to load balance across multiple bgp paths
- is it possible to connecect to two diff isp? how do we do that? does load balancing work? - we must have our own as herer to connect to two diff isps
- Range of pivate AS number? and range of public AS number? - 64512 to 65535

No comments:

Post a Comment