I got a few Juniper boxes to test, 2 x EX-8216 and a few pizza boxes. This is the first time I am working on Junos boxes. These are configuration notes from my first days with Junos on EX-8216.
#1 BGPFollowing configuration is
1. Establish a BGP session between two EX-8216
2. Redistribute static route into BGP
Switch #1
interfaces {
xe-0/0/0 {
unit 0 {
family inet {
address 2.2.2.1/30;
}
}
}
}
routing-options {
static {
route 20.20.20.0/24 next-hop 192.168.14.1;
}
router-id 2.2.2.1;
autonomous-system 1;
}
protocols {
bgp {
group ToAS2 {
type external;
family inet {
unicast;
}
export Static;
peer-as 2;
neighbor 2.2.2.2;
}
}
|
policy-options {
policy-statement Static {
term static {
from protocol static;
}
then accept;
}
}
crusader@j-testms1-re0# run show bgp summary
Groups: 1 Peers: 1 Down peers: 0
Table Tot Paths Act Paths Suppressed History Damp State Pending
inet.0 0 0 0 0 0 0
Peer AS InPkt OutPkt OutQ Flaps Last Up/Dwn State|#Active/Received/Accepted/Damped...
2.2.2.2 2 26364 26345 0 0 1w1d5h 0/0/0/0 0/0/0/0
[edit]
crusader@j-testms1-re0#
Switch #2
interfaces {
xe-0/0/0 {
unit 0 {
family inet {
address 2.2.2.2/30;
}
}
}
}
routing-options {
router-id 2.2.2.2;
autonomous-system 2;
}
protocols {
bgp {
group ToAS1 {
type external;
family inet {
unicast;
}
peer-as 1;
neighbor 2.2.2.1;
}
}
}
crusader@j-testms2-re0# run show bgp summary
Groups: 1 Peers: 1 Down peers: 0
Table Tot Paths Act Paths Suppressed History Damp State Pending
inet.0 3 1 0 0 0 0
Peer AS InPkt OutPkt OutQ Flaps Last Up/Dwn State|#Active/Received/Accepted/Damped...
2.2.2.1 1 26346 26366 0 0 1w1d5h 1/3/3/0 0/0/0/0
[edit]
crusader@j-testms2-re0#
[edit]
crusader@j-testms2-re0# run show route protocol bgp
inet.0: 9 destinations, 11 routes (9 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
2.2.2.0/30 [BGP/170] 1w1d 05:38:45, localpref 100
AS path: 1 I
> to 2.2.2.1 via xe-0/0/0.0
20.20.20.0/24 *[BGP/170] 1w1d 05:38:45, localpref 100
AS path: 1 I
> to 2.2.2.1 via xe-0/0/0.0
192.168.14.0/24 [BGP/170] 1w1d 05:38:45, localpref 100
AS path: 1 I
> to 2.2.2.1 via xe-0/0/0.0
inet6.0: 2 destinations, 2 routes (2 active, 0 holddown, 0 hidden)