S1 @ 2 – BGP-LU in Datacenter

## Last commit: 2015-07-21 14:00:22 UTC by juniper
version 15.1-20150327_ib_15_1_psd.1;
system {
    host-name 00-P1;
    root-authentication {
        encrypted-password “$5$UtCgvITo$qB7eJZA5VvexJa8ADdmn.avTjkJQ47SC.Q/i.lzWhc9”; ## SECRET-DATA
    }
    login {
        user juniper {
            uid 2000;
            class super-user;
            authentication {
                encrypted-password “$5$L9yJNREr$Gz.PM4rZ5.KrxWUmBhTUHv9lnglXHirebGrBCyN0tO6”; ## SECRET-DATA
            }
        }
    }
    services {
        ftp;
        ssh;
        telnet;
    }
    syslog {
        user * {
            any emergency;
        }
        file messages {
            any notice;
            authorization info;
        }
        file interactive-commands {
            interactive-commands any;
        }
    }
}
interfaces {
    ge-2/0/0 {
        mac 00:50:56:8b:c1:1a;
        unit 0 {
            family inet {
                address 10.255.0.31/16;
            }
        }
    }
    ge-2/0/1 {
        mac 00:50:56:8b:47:b1;
        unit 0 {
            family inet {
                address 10.0.0.5/31;
            }
            family mpls;
        }
    }
    ge-2/0/2 {
        mac 00:50:56:8b:c8:fd;
        unit 0 {
            family inet {
                address 10.0.0.9/31;
            }
            family mpls;
        }
    }
    ge-2/0/3 {
        mac 00:50:56:8b:50:47;
        unit 0 {
            family inet {
                address 10.0.0.14/31;
            }
            family mpls;
        }
    }
    ge-2/0/4 {
        mac 00:50:56:8b:7b:fe;
        unit 0 {
            family inet {
                address 10.0.0.12/31;
            }
            family mpls;
        }
    }
    ge-2/0/5 {
        mac 00:50:56:8b:46:5a;
    }
    ge-2/0/6 {
        mac 00:50:56:8b:23:e1;
    }
    lo0 {
        unit 0 {
            family inet {
                address 172.16.1.1/32;
            }
        }
    }
}
routing-options {
    interface-routes {
        rib-group inet RG-LOCAL-INTERFACES;
    }
    static {
        route 0.0.0.0/0 discard;
    }
    rib-groups {
        RG-LOCAL-INTERFACES {
            import-rib [ inet.0 inet.3 ];
            import-policy PL-LOCAL-LOOPBACK;
        }
        RG-SERVERS {
            import-rib [ inet.3 inet.0 ];
            import-policy PL-SERVERS;
        }
    }
    router-id 172.16.1.1;
    autonomous-system 65101;
    forwarding-table {
        export PL-LB;
    }
}
protocols {
    mpls {
        icmp-tunneling;
    }
    bgp {
        group eBGP-LU-65201 {
            family inet {
                labeled-unicast {
                    rib-group RG-SERVERS;
                    rib {
                        inet.3;
                    }
                }
            }
            export PL-LOCAL-LOOPBACK;
            peer-as 65201;
            neighbor 10.0.0.4;
        }
        group eBGP-LU-65202 {
            family inet {
                labeled-unicast {
                    rib-group RG-SERVERS;
                    rib {
                        inet.3;
                    }
                }
            }
            export PL-LOCAL-LOOPBACK;
            peer-as 65202;
            neighbor 10.0.0.8;
        }
        group eBGP-INET-65301 {
            multihop {
                no-nexthop-change;
            }
            local-address 172.16.1.1;
            export PL-VM;
            peer-as 65301;
            neighbor 172.16.3.11;
        }
        group eBGP-INET-65302 {
            multihop {
                no-nexthop-change;
            }
            local-address 172.16.1.1;
            export PL-VM;
            peer-as 65302;
            neighbor 172.16.3.22;
        }
    }
}
policy-options {
    policy-statement PL-LB {
        then {
            load-balance per-packet;
        }
    }
    policy-statement PL-LOCAL-LOOPBACK {
        term LOCAL-LOOPBACK {
            from interface lo0.0;
            then {
                community add RR;
                accept;
            }
        }
    }
    policy-statement PL-SERVERS {
        term SERVERS {
            from community SERVER;
            then accept;
        }
        then reject;
    }
    policy-statement PL-VM {
        term VM {
            from community VM;
            then accept;
        }
        then reject;
    }
    community RR members 65000:1;
    community SERVER members 65000:3;
    community VM members 65000:100;
}

Advertisements