[j-nsp] BGP Outbound Policy

Shixiong Shang sshang2 at yahoo.com
Mon Feb 16 16:09:17 EST 2004


Hi, folks:

I would like to compress BGP updates from Juniper M40s
to other BGP routers. What I want to achieve is, Don't
advertise the route learned from AS 65300 back to the
routers in AS65300. By doing this, I think we can
minimize the bandwith consumed by BGP and also improve
the convergence time.

So what I did on Juniper was adding a policy statement
as follow (the first a couple terms are to
redistribute local, static and OSPF rotues into BGP):

**************************************************
policy-statement export-rib-bgp {
    term 10 {
        from protocol direct;
        then {
            community set Local-Community;
            accept;
        }
    }
    term 20 {
        from protocol static;
        then {
            community set Local-Community;
            accept;
        }
    }
    term 30 {
        from {
            protocol ospf;
            prefix-list Illegal-Prefix;
        }
        then reject;
    }
    term 40 {
        from protocol ospf;
        then {
            community set Local-Community;
            accept;
        }
    }
    term 50 {
        from {
            protocol bgp;
            as-path AS65300;
        }
        to neighbor [ 192.168.223.104 192.168.223.105
];
        then reject;
    }               
    term 60 {
        from protocol bgp;
        then accept;
    }
}

community Local-Community members 65200:05;
as-path AS65300 "65300{1,}";
***************************************************

Neighbor routers 192.168.223.104 and 192.168.223.105
are in AS 65300. My question is, if I apply this
policy with term 50 and 60 to "protocol bgp export",
will Juniper stop advertising the routes originated
from 65300? By reading the Juniper document, I believe
the export policy only works between RIB and BGP
routing table, not between BGP neighbors. Am I right?
If so, is there any other way to achieve my goal?

Thanks!

Shixiong

__________________________________
Do you Yahoo!?
Yahoo! Finance: Get your refund fast by filing online.
http://taxes.yahoo.com/filing.html


More information about the juniper-nsp mailing list