Juniper policy-option policy-statement route-filter

Now everyone is shifting to juniper routers. Because the Juniper router can manage traffic very easily. For this, almost everyone is using Juniper routers as core routers mostly IIGs and ISPs.Today we will learn how to configure the policy-option policy-statement route filter of the Juniper router. We know that a route filter is required in a BGP connection. If you do BGP on the Juniper network you must use the filter. So let's get started.


Juniper policy options policy statement route filter example

In Juniper Router we will see 2 types of route-filter examples. First, let's learn how to create a default route (0.0.0.0/0) filter. Then learn to create Real IP prefixes route filter for client-in.



Juniper default route filter example in router

When we configure a client's IIG BGP, we send the Default Gateway to that BGP throw. A route-filter configuration is required to send the default gateway. So let's get started.

login: afnan
Password:

--- JUNOS 17.3R3.10 built 2018-09-06 23:15:56 UTC
afnan@NIS-Core> configure
Entering configuration mode
Users currently editing the configuration:
afnan terminal u0 (pid 31768) on since 2023-10-16 12:54:47 UTC, idle 9w2d 21:36
[edit]

[edit]
afnan@NIS-Core# set policy-options policy-statement DEFAULT-FOR-CLIENT term 1 from route-filter 0.0.0.0/0 exact

[edit] afnan@NIS-Core# set policy-options policy-statement DEFAULT-FOR-CLIENT term 1 then accept

[edit]
afnan@NIS-Core# set policy-options policy-statement DEFAULT-FOR-CLIENT term 2 then reject


Note: The work of this filter is that in the term 1 condition, it will accept all the requests, and in the term 2 condition it will reject all the requests. You can configure the filter with Term as you like.



Juniper route-filter example

Now we will do one more filter which is the client in filter. Now we will see the filter configuration through which the client end will get the internet service through the real IP between the filters. Let's begin.

[edit]
afnan@NIS-Core# set policy-options policy-statement IMPORT-FROM-Saiful-IIG term 1 from route-filter 114.130.28.12/30 exact

[edit]
afnan@NIS-Core# set policy-options policy-statement IMPORT-FROM-Saiful-IIG term 1 from route-filter 114.130.28.16/30 exact

[edit]
afnan@NIS-Core# set policy-options policy-statement IMPORT-FROM-Saiful-IIG term 1 then accept

[edit]
afnan@NIS-Core# set policy-options policy-statement IMPORT-FROM-Saiful-IIG term 2 then reject


Note: The work of this filter is that in the term 1 condition, it will accept all the requests, and in the term 2 condition it will reject all the requests. You can accept more prefixes by typing Term 1 if you want. You can configure the filter with Term as you like.

Post a Comment

Previous Post Next Post

Contact Form